Java Code Examples for org.apache.rocketmq.common.protocol.heartbeat.ConsumerData#setMessageModel()
The following examples show how to use
org.apache.rocketmq.common.protocol.heartbeat.ConsumerData#setMessageModel() .
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: PullMessageProcessorTest.java From DDMQ with Apache License 2.0 | 5 votes |
static ConsumerData createConsumerData(String group, String topic) { ConsumerData consumerData = new ConsumerData(); consumerData.setConsumeFromWhere(ConsumeFromWhere.CONSUME_FROM_FIRST_OFFSET); consumerData.setConsumeType(ConsumeType.CONSUME_PASSIVELY); consumerData.setGroupName(group); consumerData.setMessageModel(MessageModel.CLUSTERING); Set<SubscriptionData> subscriptionDataSet = new HashSet<>(); SubscriptionData subscriptionData = new SubscriptionData(); subscriptionData.setTopic(topic); subscriptionData.setSubString("*"); subscriptionData.setSubVersion(100L); subscriptionDataSet.add(subscriptionData); consumerData.setSubscriptionDataSet(subscriptionDataSet); return consumerData; }
Example 2
Source File: PullMessageProcessorTest.java From rocketmq-4.3.0 with Apache License 2.0 | 5 votes |
static ConsumerData createConsumerData(String group, String topic) { ConsumerData consumerData = new ConsumerData(); consumerData.setConsumeFromWhere(ConsumeFromWhere.CONSUME_FROM_FIRST_OFFSET); consumerData.setConsumeType(ConsumeType.CONSUME_PASSIVELY); consumerData.setGroupName(group); consumerData.setMessageModel(MessageModel.CLUSTERING); Set<SubscriptionData> subscriptionDataSet = new HashSet<>(); SubscriptionData subscriptionData = new SubscriptionData(); subscriptionData.setTopic(topic); subscriptionData.setSubString("*"); subscriptionData.setSubVersion(100L); subscriptionDataSet.add(subscriptionData); consumerData.setSubscriptionDataSet(subscriptionDataSet); return consumerData; }
Example 3
Source File: ConsumeQueueManagerTest.java From DeFiBus with Apache License 2.0 | 5 votes |
private static ConsumerData createConsumerData(String group, String topic) { ConsumerData consumerData = new ConsumerData(); consumerData.setConsumeFromWhere(ConsumeFromWhere.CONSUME_FROM_FIRST_OFFSET); consumerData.setConsumeType(ConsumeType.CONSUME_PASSIVELY); consumerData.setGroupName(group); consumerData.setMessageModel(MessageModel.CLUSTERING); Set<SubscriptionData> subscriptionDataSet = new HashSet<>(); SubscriptionData subscriptionData = new SubscriptionData(); subscriptionData.setTopic(topic); subscriptionData.setSubString("*"); subscriptionData.setSubVersion(100L); subscriptionDataSet.add(subscriptionData); consumerData.setSubscriptionDataSet(subscriptionDataSet); return consumerData; }
Example 4
Source File: DeFiPullMessageProcessorTest.java From DeFiBus with Apache License 2.0 | 5 votes |
static ConsumerData createConsumerData(String group, String topic) { ConsumerData consumerData = new ConsumerData(); consumerData.setConsumeFromWhere(ConsumeFromWhere.CONSUME_FROM_FIRST_OFFSET); consumerData.setConsumeType(ConsumeType.CONSUME_PASSIVELY); consumerData.setGroupName(group); consumerData.setMessageModel(MessageModel.CLUSTERING); Set<SubscriptionData> subscriptionDataSet = new HashSet<>(); SubscriptionData subscriptionData = new SubscriptionData(); subscriptionData.setTopic(topic); subscriptionData.setSubString("*"); subscriptionData.setSubVersion(100L); subscriptionDataSet.add(subscriptionData); consumerData.setSubscriptionDataSet(subscriptionDataSet); return consumerData; }
Example 5
Source File: DeFiClientManageProcessorTest.java From DeFiBus with Apache License 2.0 | 5 votes |
static ConsumerData createConsumerData(String group, String topic) { ConsumerData consumerData = new ConsumerData(); consumerData.setConsumeFromWhere(ConsumeFromWhere.CONSUME_FROM_FIRST_OFFSET); consumerData.setConsumeType(ConsumeType.CONSUME_PASSIVELY); consumerData.setGroupName(group); consumerData.setMessageModel(MessageModel.CLUSTERING); Set<SubscriptionData> subscriptionDataSet = new HashSet<>(); SubscriptionData subscriptionData = new SubscriptionData(); subscriptionData.setTopic(topic); subscriptionData.setSubString("*"); subscriptionData.setSubVersion(100L); subscriptionDataSet.add(subscriptionData); consumerData.setSubscriptionDataSet(subscriptionDataSet); return consumerData; }
Example 6
Source File: DeFiConsumerManagerTest.java From DeFiBus with Apache License 2.0 | 5 votes |
private ConsumerData createConsumerData(String group, String topic) { ConsumerData consumerData = new ConsumerData(); consumerData.setConsumeFromWhere(ConsumeFromWhere.CONSUME_FROM_FIRST_OFFSET); consumerData.setConsumeType(ConsumeType.CONSUME_PASSIVELY); consumerData.setGroupName(group); consumerData.setMessageModel(MessageModel.CLUSTERING); Set<SubscriptionData> subscriptionDataSet = new HashSet<>(); SubscriptionData subscriptionData = new SubscriptionData(); subscriptionData.setTopic(topic); subscriptionData.setSubString("*"); subscriptionData.setSubVersion(100L); subscriptionDataSet.add(subscriptionData); consumerData.setSubscriptionDataSet(subscriptionDataSet); return consumerData; }
Example 7
Source File: PullMessageProcessorTest.java From rocketmq-read with Apache License 2.0 | 5 votes |
static ConsumerData createConsumerData(String group, String topic) { ConsumerData consumerData = new ConsumerData(); consumerData.setConsumeFromWhere(ConsumeFromWhere.CONSUME_FROM_FIRST_OFFSET); consumerData.setConsumeType(ConsumeType.CONSUME_PASSIVELY); consumerData.setGroupName(group); consumerData.setMessageModel(MessageModel.CLUSTERING); Set<SubscriptionData> subscriptionDataSet = new HashSet<>(); SubscriptionData subscriptionData = new SubscriptionData(); subscriptionData.setTopic(topic); subscriptionData.setSubString("*"); subscriptionData.setSubVersion(100L); subscriptionDataSet.add(subscriptionData); consumerData.setSubscriptionDataSet(subscriptionDataSet); return consumerData; }
Example 8
Source File: PullMessageProcessorTest.java From rocketmq with Apache License 2.0 | 5 votes |
static ConsumerData createConsumerData(String group, String topic) { ConsumerData consumerData = new ConsumerData(); consumerData.setConsumeFromWhere(ConsumeFromWhere.CONSUME_FROM_FIRST_OFFSET); consumerData.setConsumeType(ConsumeType.CONSUME_PASSIVELY); consumerData.setGroupName(group); consumerData.setMessageModel(MessageModel.CLUSTERING); Set<SubscriptionData> subscriptionDataSet = new HashSet<>(); SubscriptionData subscriptionData = new SubscriptionData(); subscriptionData.setTopic(topic); subscriptionData.setSubString("*"); subscriptionData.setSubVersion(100L); subscriptionDataSet.add(subscriptionData); consumerData.setSubscriptionDataSet(subscriptionDataSet); return consumerData; }
Example 9
Source File: PullMessageProcessorTest.java From DDMQ with Apache License 2.0 | 5 votes |
static ConsumerData createConsumerData(String group, String topic) { ConsumerData consumerData = new ConsumerData(); consumerData.setConsumeFromWhere(ConsumeFromWhere.CONSUME_FROM_FIRST_OFFSET); consumerData.setConsumeType(ConsumeType.CONSUME_PASSIVELY); consumerData.setGroupName(group); consumerData.setMessageModel(MessageModel.CLUSTERING); Set<SubscriptionData> subscriptionDataSet = new HashSet<>(); SubscriptionData subscriptionData = new SubscriptionData(); subscriptionData.setTopic(topic); subscriptionData.setSubString("*"); subscriptionData.setSubVersion(100L); subscriptionDataSet.add(subscriptionData); consumerData.setSubscriptionDataSet(subscriptionDataSet); return consumerData; }
Example 10
Source File: PullMessageProcessorTest.java From rocketmq-all-4.1.0-incubating with Apache License 2.0 | 5 votes |
static ConsumerData createConsumerData(String group, String topic) { ConsumerData consumerData = new ConsumerData(); consumerData.setConsumeFromWhere(ConsumeFromWhere.CONSUME_FROM_FIRST_OFFSET); consumerData.setConsumeType(ConsumeType.CONSUME_PASSIVELY); consumerData.setGroupName(group); consumerData.setMessageModel(MessageModel.CLUSTERING); Set<SubscriptionData> subscriptionDataSet = new HashSet<>(); SubscriptionData subscriptionData = new SubscriptionData(); subscriptionData.setTopic(topic); subscriptionData.setSubString("*"); subscriptionData.setSubVersion(100L); subscriptionDataSet.add(subscriptionData); consumerData.setSubscriptionDataSet(subscriptionDataSet); return consumerData; }
Example 11
Source File: PullMessageProcessorTest.java From rocketmq_trans_message with Apache License 2.0 | 5 votes |
static ConsumerData createConsumerData(String group, String topic) { ConsumerData consumerData = new ConsumerData(); consumerData.setConsumeFromWhere(ConsumeFromWhere.CONSUME_FROM_FIRST_OFFSET); consumerData.setConsumeType(ConsumeType.CONSUME_PASSIVELY); consumerData.setGroupName(group); consumerData.setMessageModel(MessageModel.CLUSTERING); Set<SubscriptionData> subscriptionDataSet = new HashSet<>(); SubscriptionData subscriptionData = new SubscriptionData(); subscriptionData.setTopic(topic); subscriptionData.setSubString("*"); subscriptionData.setSubVersion(100L); subscriptionDataSet.add(subscriptionData); consumerData.setSubscriptionDataSet(subscriptionDataSet); return consumerData; }
Example 12
Source File: PullMessageProcessorTest.java From rocketmq with Apache License 2.0 | 5 votes |
static ConsumerData createConsumerData(String group, String topic) { ConsumerData consumerData = new ConsumerData(); consumerData.setConsumeFromWhere(ConsumeFromWhere.CONSUME_FROM_FIRST_OFFSET); consumerData.setConsumeType(ConsumeType.CONSUME_PASSIVELY); consumerData.setGroupName(group); consumerData.setMessageModel(MessageModel.CLUSTERING); Set<SubscriptionData> subscriptionDataSet = new HashSet<>(); SubscriptionData subscriptionData = new SubscriptionData(); subscriptionData.setTopic(topic); subscriptionData.setSubString("*"); subscriptionData.setSubVersion(100L); subscriptionDataSet.add(subscriptionData); consumerData.setSubscriptionDataSet(subscriptionDataSet); return consumerData; }