Skip to content

Commit 79a345a

Browse files
authored
[ISSUE #1310]⚡️Refactor AllocateMessageQueueStrategy (#1311)
1 parent 6e8aaac commit 79a345a

File tree

2 files changed

+4
-4
lines changed

2 files changed

+4
-4
lines changed

rocketmq-client/src/consumer/allocate_message_queue_strategy.rs

+2-2
Original file line numberDiff line numberDiff line change
@@ -22,8 +22,8 @@ use crate::Result;
2222
pub trait AllocateMessageQueueStrategy: Send + Sync {
2323
fn allocate(
2424
&self,
25-
consumer_group: &str,
26-
current_cid: &str,
25+
consumer_group: &CheetahString,
26+
current_cid: &CheetahString,
2727
mq_all: &[MessageQueue],
2828
cid_all: &[CheetahString],
2929
) -> Result<Vec<MessageQueue>>;

rocketmq-client/src/consumer/rebalance_strategy/allocate_message_queue_averagely.rs

+2-2
Original file line numberDiff line numberDiff line change
@@ -26,8 +26,8 @@ pub struct AllocateMessageQueueAveragely;
2626
impl AllocateMessageQueueStrategy for AllocateMessageQueueAveragely {
2727
fn allocate(
2828
&self,
29-
consumer_group: &str,
30-
current_cid: &str,
29+
consumer_group: &CheetahString,
30+
current_cid: &CheetahString,
3131
mq_all: &[MessageQueue],
3232
cid_all: &[CheetahString],
3333
) -> Result<Vec<MessageQueue>> {

0 commit comments

Comments
 (0)