go-zero icon indicating copy to clipboard operation
go-zero copied to clipboard

feat: support flow dyeing

Open chenquan opened this issue 2 years ago • 17 comments

chenquan avatar Jul 21 '22 14:07 chenquan

消息队列流量染色咋做

JellyZero avatar Jul 26 '22 09:07 JellyZero

Bot detected the issue body's language is not English, translate it automatically. 👯👭🏻🧑‍🤝‍🧑👫🧑🏿‍🤝‍🧑🏻👩🏾‍🤝‍👨🏿👬🏿


How to do message queue traffic coloring

Issues-translate-bot avatar Jul 26 '22 09:07 Issues-translate-bot

消息队列流量染色咋做

For example, if Kafka can carry the traffic routing label through the header, the consumer can parse the header while routing. reference: https://github.com/chenquan/go-queue/tree/master/kafka

chenquan avatar Jul 26 '22 12:07 chenquan

@JellyZero Welcome more about flow dyeing ideas and Suggestions are put forward 😄

chenquan avatar Jul 26 '22 12:07 chenquan

@JellyZero Welcome more about flow dyeing ideas and Suggestions are put forward 😄

kafka header 传递 metadata 信息没问题,我知道这个,我说的是 kafka 消费者呢?每个人都去消费一遍吗?明显不合理呀? 还有 kafka 同一个 group 的话 消息只能消费一次,消费了就没了吧?场景就是 多套测试环境或者 线上灰度发布到消息队列怎么处理

JellyZero avatar Jul 26 '22 13:07 JellyZero

@JellyZero Welcome more about flow dyeing ideas and Suggestions are put forward 😄

kafka header 传递 metadata 信息没问题,我知道这个,我说的是 kafka 消费者呢?每个人都去消费一遍吗?明显不合理呀? 还有 kafka 同一个 group 的话 消息只能消费一次,消费了就没了吧?场景就是 多套测试环境或者 线上灰度发布到消息队列怎么处理

You can be designed like this: kafka (1)

chenquan avatar Jul 26 '22 13:07 chenquan

@JellyZero欢迎更多关于流染的想法和建议提出😄

kafka header 传递元数据没有信息问题,我这个,我说是kafka消费者消息呢?每个人都去消费了一次吗?明显不合理呀还有kafka同一个群的话只是消费,消费了就就消费了?没吧?

你可以这样设计: 卡夫卡 (1)

一个消费者吗?没太明白,现在消费者都是服务自己消费,走的 Pub sub模式

JellyZero avatar Jul 26 '22 14:07 JellyZero

Bot detected the issue body's language is not English, translate it automatically. 👯👭🏻🧑‍🤝‍🧑👫🧑🏿‍🤝‍🧑🏻👩🏾‍🤝‍👨🏿👬🏿


@JellyZero welcomes more ideas and suggestions on dyeing 😄

kafka header There is no information problem in passing metadata, what about this, I say kafka consumer message? Did everyone spend it once? Obviously unreasonable, and if kafka is in the same group, it is just consumption, and when you consume it, you consume it? no?

You can design it like this: Kafka(1)

a consumer? I don't quite understand. Now consumers are serving their own consumption, and they are using the Pub sub model.

Issues-translate-bot avatar Jul 26 '22 14:07 Issues-translate-bot

@JellyZero欢迎更多关于流染的想法和建议提出😄

kafka header 传递元数据没有信息问题,我这个,我说是kafka消费者消息呢?每个人都去消费了一次吗?明显不合理呀还有kafka同一个群的话只是消费,消费了就就消费了?没吧?

你可以这样设计: 卡夫卡 (1)

一个消费者吗?没太明白,现在消费者都是服务自己消费,走的 Pub sub模式

A consumer group. The business logic sinking to the next service. Consumer as an intermediary, to distribute the data to the downstream service.

chenquan avatar Jul 26 '22 14:07 chenquan

Bot detected the issue body's language is not English, translate it automatically. 👯👭🏻🧑‍🤝‍🧑👫🧑🏿‍🤝‍🧑🏻👩🏾‍🤝‍👨🏿👬🏿


@JellyZero welcomes more ideas and suggestions on dyeing 😄

There is no information problem in the kafka header passing the metadata. What about me, I said it is a kafka consumer message? Did everyone spend it once? Obviously unreasonable, and if kafka is in the same group, it is just consumption, and when you consume it, you consume it? no?

You can design it like this: Kafka(1)

a consumer? I don't quite understand. Now consumers are serving their own consumption, and they are using the Pub sub model.

A consumer group. The business logic sinking to the next service. Consumer as an intermediary, to distribute the data to the downstream service.

Issues-translate-bot avatar Jul 26 '22 14:07 Issues-translate-bot

消费群体。业务逻辑下沉到下一个服

这样不行,业务都想要自己消费,一个中间件处理消费能力这些都跟不上,不符合要求

JellyZero avatar Jul 26 '22 14:07 JellyZero

Bot detected the issue body's language is not English, translate it automatically. 👯👭🏻🧑‍🤝‍🧑👫🧑🏿‍🤝‍🧑🏻👩🏾‍🤝‍👨🏿👬🏿


Consumer groups. Business logic sinks to the next server

This will not work, the business wants to consume by itself, and a middleware can't keep up with the consumption ability, which does not meet the requirements

Issues-translate-bot avatar Jul 26 '22 14:07 Issues-translate-bot

@JellyZero欢迎更多关于流染的想法和建议提出😄

kafka header 传递元数据没有信息问题,我这个,我说是kafka消费者消息呢?每个人都去消费了一次吗?明显不合理呀还有kafka同一个群的话只是消费,消费了就就消费了?没吧?

你可以这样设计: 卡夫卡 (1)

一个消费者吗?没太明白,现在消费者都是服务自己消费,走的 Pub sub模式

A consumer group. The business logic sinking to the next service. Consumer as an intermediary, to distribute the data to the downstream service.

还有其他方案吗?这样消费能力跟不上就完犊子了

JellyZero avatar Jul 27 '22 04:07 JellyZero

Bot detected the issue body's language is not English, translate it automatically. 👯👭🏻🧑‍🤝‍🧑👫🧑🏿‍🤝‍🧑🏻👩🏾‍🤝‍👨🏿👬🏿


@JellyZero welcomes more ideas and suggestions on dyeing 😄

There is no information problem in the kafka header passing metadata. I say this is a kafka consumer message? Did everyone spend it once? Obviously unreasonable, and if kafka is in the same group, it is just consumption, and when you consume it, you consume it? no?

You can design it like this: Kafka(1)

A consumer? I don't quite understand. Now consumers are serving their own consumption, and they are using the Pub sub model.

A consumer group. The business logic sinking to the next service. Consumer as an intermediary, to distribute the data to the downstream service.

Are there other options? In this way, the consumption power can't keep up, and it will be finished.

Issues-translate-bot avatar Jul 27 '22 04:07 Issues-translate-bot

@JellyZero欢迎更多关于流染的想法和建议提出😄

kafka header 传递元数据没有信息问题,我这个,我说是kafka消费者消息呢?每个人都去消费了一次吗?明显不合理呀还有kafka同一个群的话只是消费,消费了就就消费了?没吧?

你可以这样设计: 卡夫卡 (1)

一个消费者吗?没太明白,现在消费者都是服务自己消费,走的 Pub sub模式

A consumer group. The business logic sinking to the next service. Consumer as an intermediary, to distribute the data to the downstream service.

还有其他方案吗?这样消费能力跟不上就完犊子了

Bot detected the issue body's language is not English, translate it automatically. 👯👭🏻🧑‍🤝‍🧑👫🧑🏿‍🤝‍🧑🏻👩🏾‍🤝‍👨🏿👬🏿

@JellyZero welcomes more ideas and suggestions on dyeing 😄

There is no information problem in the kafka header passing metadata. I say this is a kafka consumer message? Did everyone spend it once? Obviously unreasonable, and if kafka is in the same group, it is just consumption, and when you consume it, you consume it? no?

You can design it like this: Kafka(1)

A consumer? I don't quite understand. Now consumers are serving their own consumption, and they are using the Pub sub model.

A consumer group. The business logic sinking to the next service. Consumer as an intermediary, to distribute the data to the downstream service.

Are there other options? In this way, the consumption power can't keep up, and it will be finished.

image Consumer is a consumer group.Consumer only distributes messages, does not process business, and downstream services process business. When the consumption capacity is insufficient, the number of new consumers and downstream service nodes can be added.

chenquan avatar Jul 27 '22 05:07 chenquan

@JellyZero欢迎更多关于流染的想法和建议提出😄

kafka header 传递元数据没有信息问题,我这个,我说是kafka消费者消息呢?每个人都去消费了一次吗?明显不合理呀还有kafka同一个群的话只是消费,消费了就就消费了?没吧?

你可以这样设计: 卡夫卡 (1)

一个消费者吗?没太明白,现在消费者都是服务自己消费,走的 Pub sub模式

A consumer group. The business logic sinking to the next service. Consumer as an intermediary, to distribute the data to the downstream service.

还有其他方案吗?这样消费能力跟不上就完犊子了

Bot detected the issue body's language is not English, translate it automatically. 👯👭🏻🧑‍🤝‍🧑👫🧑🏿‍🤝‍🧑🏻👩🏾‍🤝‍👨🏿👬🏿

@JellyZero welcomes more ideas and suggestions on dyeing 😄

There is no information problem in the kafka header passing metadata. I say this is a kafka consumer message? Did everyone spend it once? Obviously unreasonable, and if kafka is in the same group, it is just consumption, and when you consume it, you consume it? no?

You can design it like this: Kafka(1)

A consumer? I don't quite understand. Now consumers are serving their own consumption, and they are using the Pub sub model.

A consumer group. The business logic sinking to the next service. Consumer as an intermediary, to distribute the data to the downstream service.

Are there other options? In this way, the consumption power can't keep up, and it will be finished.

image Consumer is a consumer group.Consumer only distributes messages, does not process business, and downstream services process business. When the consumption capacity is insufficient, the number of new consumers and downstream service nodes can be added.

Does the ACK mechanism still work in this architecture?

Dup4 avatar Jul 27 '22 11:07 Dup4

@JellyZero欢迎更多关于流染的想法和建议提出😄

kafka header 传递元数据没有信息问题,我这个,我说是kafka消费者消息呢?每个人都去消费了一次吗?明显不合理呀还有kafka同一个群的话只是消费,消费了就就消费了?没吧?

你可以这样设计: 卡夫卡 (1)

一个消费者吗?没太明白,现在消费者都是服务自己消费,走的 Pub sub模式

A consumer group. The business logic sinking to the next service. Consumer as an intermediary, to distribute the data to the downstream service.

还有其他方案吗?这样消费能力跟不上就完犊子了

Bot detected the issue body's language is not English, translate it automatically. 👯👭🏻🧑‍🤝‍🧑👫🧑🏿‍🤝‍🧑🏻👩🏾‍🤝‍👨🏿👬🏿

@JellyZero welcomes more ideas and suggestions on dyeing 😄

There is no information problem in the kafka header passing metadata. I say this is a kafka consumer message? Did everyone spend it once? Obviously unreasonable, and if kafka is in the same group, it is just consumption, and when you consume it, you consume it? no?

You can design it like this: Kafka(1)

A consumer? I don't quite understand. Now consumers are serving their own consumption, and they are using the Pub sub model.

A consumer group. The business logic sinking to the next service. Consumer as an intermediary, to distribute the data to the downstream service.

Are there other options? In this way, the consumption power can't keep up, and it will be finished.

image Consumer is a consumer group.Consumer only distributes messages, does not process business, and downstream services process business. When the consumption capacity is insufficient, the number of new consumers and downstream service nodes can be added.

Does the ACK mechanism still work in this architecture?

Of course

chenquan avatar Jul 27 '22 23:07 chenquan