diff --git a/python/rocketmq/client_id_encoder.py b/python/rocketmq/client_id_encoder.py index cbab96684..138b05f02 100644 --- a/python/rocketmq/client_id_encoder.py +++ b/python/rocketmq/client_id_encoder.py @@ -13,10 +13,11 @@ # See the License for the specific language governing permissions and # limitations under the License. -import threading -import socket import os +import socket +import threading import time + import rocketmq.utils diff --git a/python/rocketmq/client_manager.py b/python/rocketmq/client_manager.py index d4a78bb6e..dd13b2f51 100644 --- a/python/rocketmq/client_manager.py +++ b/python/rocketmq/client_manager.py @@ -13,11 +13,12 @@ # See the License for the specific language governing permissions and # limitations under the License. -from rocketmq.rpc_client import Endpoints, RpcClient -from rocketmq.client import Client -from protocol import service_pb2 import threading +from protocol import service_pb2 +from rocketmq.client import Client +from rocketmq.rpc_client import Endpoints, RpcClient + class ClientManager: def __init__(self, client: Client): diff --git a/python/rocketmq/message.py b/python/rocketmq/message.py index 40ad9be3b..f20e86510 100644 --- a/python/rocketmq/message.py +++ b/python/rocketmq/message.py @@ -116,10 +116,6 @@ def properties(self): def tag(self): return self.__tag - @property - def keys(self): - return self.__keys - @property def message_group(self): return self.__message_group diff --git a/python/rocketmq/signature.py b/python/rocketmq/signature.py index e00cf543f..c77a355a2 100644 --- a/python/rocketmq/signature.py +++ b/python/rocketmq/signature.py @@ -13,10 +13,11 @@ # See the License for the specific language governing permissions and # limitations under the License. -from rocketmq.client_config import ClientConfig -import uuid import datetime import importlib.metadata +import uuid + +from rocketmq.client_config import ClientConfig from rocketmq.utils import sign diff --git a/python/rocketmq/utils.py b/python/rocketmq/utils.py index d021a8494..adec636be 100644 --- a/python/rocketmq/utils.py +++ b/python/rocketmq/utils.py @@ -13,16 +13,9 @@ # See the License for the specific language governing permissions and # limitations under the License. -import hmac import hashlib +import hmac -from apscheduler.executors.pool import ThreadPoolExecutor, ProcessPoolExecutor -from multiprocessing import cpu_count - -scheduler_executors = { - 'default': ThreadPoolExecutor(2 * cpu_count()), - # 'processpool': ProcessPoolExecutor(5) -} def number_to_base(number, base): alphabet = "0123456789ABCDEFGHIJKLMNOPQRSTUVWXYZ"