apache / rocketmq-client-python

Apache RocketMQ python client
https://rocketmq.apache.org/
Apache License 2.0
271 stars 95 forks source link

ConsumeStatus.CONSUME_SUCCESS is deprecated? #112

Open zengzhengrong opened 3 years ago

zengzhengrong commented 3 years ago

I could not find the ConsumeStatus.CONSUME_SUCCESS follow in Readme.md

So , I find the below and use it callback return

from rocketmq.ffi import _CConsumeStatus

def callback(msg):
    ...
    return _CConsumeStatus.CONSUME_SUCCESS

python version 3.7

pip version

root@2340c37e8721:/workspace# pip list | grep rocket
rocketmq                   0.4.4
rocketmq-client-python     2.0.0

cpp version 2.0.0

francisoliverlee commented 3 years ago

replace by https://github.com/apache/rocketmq-client-python/blob/d074515b0104354d1b54ad53a110e49413f8d889/rocketmq/client.py#L60

demo code : https://github.com/apache/rocketmq-client-python/blob/master/tests/test_consumer.py

zengzhengrong commented 3 years ago

@francisoliverlee use pip install does not have this class,

root@2340c37e8721:/workspace# pip list | grep rocket
rocketmq                   0.4.4
rocketmq-client-python     2.0.0
baby1990 commented 2 years ago

@francisoliverlee use pip install does not have this class,

root@2340c37e8721:/workspace# pip list | grep rocket
rocketmq                   0.4.4
rocketmq-client-python     2.0.0

uninstall the rocketmq package, it's deprecated.Just use rocketmq-client-python.