Java Code Examples for org.apache.activemq.broker.region.policy.PolicyEntry#setEnableAudit()
The following examples show how to use
org.apache.activemq.broker.region.policy.PolicyEntry#setEnableAudit() .
You can vote up the ones you like or vote down the ones you don't like,
and go to the original project or source file by following the links above each example. You may check out the related API usage on the sidebar.
Example 1
Source File: TwoBrokerQueueClientsReconnectTest.java From activemq-artemis with Apache License 2.0 | 5 votes |
@Override protected void configureBroker(BrokerService broker) { PolicyMap policyMap = new PolicyMap(); PolicyEntry defaultEntry = new PolicyEntry(); defaultEntry.setEnableAudit(false); policyMap.setDefaultEntry(defaultEntry); broker.setDestinationPolicy(policyMap); }
Example 2
Source File: VirtualTopicNetworkClusterReactivationTest.java From activemq-artemis with Apache License 2.0 | 5 votes |
private PolicyMap buildPolicyMap() { PolicyMap policyMap = new PolicyMap(); PolicyEntry policyEntry = new PolicyEntry(); policyEntry.setOptimizedDispatch(true); ConditionalNetworkBridgeFilterFactory networkBridgeFilterFactory = new ConditionalNetworkBridgeFilterFactory(); networkBridgeFilterFactory.setReplayWhenNoConsumers(true); policyEntry.setNetworkBridgeFilterFactory(networkBridgeFilterFactory); policyEntry.setEnableAudit(false); policyMap.put(new ActiveMQQueue("Consumer.*.VirtualTopic.>"), policyEntry); return policyMap; }
Example 3
Source File: NoDuplicateOnTopicNetworkTest.java From activemq-artemis with Apache License 2.0 | 5 votes |
private BrokerService createAndStartBroker(String name, String addr) throws Exception { BrokerService broker = new BrokerService(); broker.setDeleteAllMessagesOnStartup(true); broker.setBrokerName(name); broker.addConnector(addr).setDiscoveryUri(new URI(MULTICAST_DEFAULT)); broker.setUseJmx(false); NetworkConnector networkConnector = broker.addNetworkConnector(MULTICAST_DEFAULT); networkConnector.setDecreaseNetworkConsumerPriority(true); networkConnector.setDynamicOnly(dynamicOnly); networkConnector.setNetworkTTL(ttl); networkConnector.setSuppressDuplicateTopicSubscriptions(suppressDuplicateTopicSubs); networkConnector.setConsumerPriorityBase(BASE_PRIORITY); networkConnector.addStaticallyIncludedDestination(new ActiveMQTopic("BeStaticallyIncluded")); PolicyMap policyMap = new PolicyMap(); PolicyEntry policy = new PolicyEntry(); policy.setDispatchPolicy(dispatchPolicy); // the audit will suppress the duplicates as it defaults to true so this test // checking for dups will fail. it is good to have it on in practice. policy.setEnableAudit(false); policyMap.put(new ActiveMQTopic(TOPIC_NAME), policy); broker.setDestinationPolicy(policyMap); broker.start(); return broker; }
Example 4
Source File: ConsumeFromAMQPTest.java From qpid-jms with Apache License 2.0 | 5 votes |
@Override protected void configureBrokerPolicies(BrokerService broker) { PolicyEntry policyEntry = new PolicyEntry(); policyEntry.setPendingQueuePolicy(new VMPendingQueueMessageStoragePolicy()); policyEntry.setPrioritizedMessages(false); policyEntry.setExpireMessagesPeriod(0); policyEntry.setEnableAudit(false); policyEntry.setOptimizedDispatch(false); policyEntry.setQueuePrefetch(1000); PolicyMap policyMap = new PolicyMap(); policyMap.setDefaultEntry(policyEntry); broker.setDestinationPolicy(policyMap); }
Example 5
Source File: ProducerAndConsumerBench.java From qpid-jms with Apache License 2.0 | 5 votes |
@Override protected void configureBrokerPolicies(BrokerService broker) { PolicyEntry policyEntry = new PolicyEntry(); policyEntry.setPendingQueuePolicy(new VMPendingQueueMessageStoragePolicy()); policyEntry.setPrioritizedMessages(false); policyEntry.setExpireMessagesPeriod(0); policyEntry.setEnableAudit(false); policyEntry.setOptimizedDispatch(true); policyEntry.setQueuePrefetch(1); // ensure no contention on add with // matched producer/consumer PolicyMap policyMap = new PolicyMap(); policyMap.setDefaultEntry(policyEntry); broker.setDestinationPolicy(policyMap); }
Example 6
Source File: ProduceToAMQPTest.java From qpid-jms with Apache License 2.0 | 5 votes |
@Override protected void configureBrokerPolicies(BrokerService broker) { PolicyEntry policyEntry = new PolicyEntry(); policyEntry.setPendingQueuePolicy(new VMPendingQueueMessageStoragePolicy()); policyEntry.setPrioritizedMessages(false); policyEntry.setExpireMessagesPeriod(0); policyEntry.setEnableAudit(false); policyEntry.setOptimizedDispatch(true); policyEntry.setQueuePrefetch(100); PolicyMap policyMap = new PolicyMap(); policyMap.setDefaultEntry(policyEntry); broker.setDestinationPolicy(policyMap); }