Intel-bigdata / SSM

Smart Storage Management for Big Data, a comprehensive hot/cold data optimized solution
Apache License 2.0
134 stars 67 forks source link

SmartClient retry to connect standby server in HA mode #2228

Closed lipppppp closed 3 years ago

lipppppp commented 3 years ago

The SmartClient will retry to connnect standby server when the value of smart.server.rpc.address is "ssm1:7042, ssm2:7042" and active server is ssm2. Although this read action finally successed, it still should wait for a long time. SmartClient#reportFileAccessEvent will get first server to report access event, and the serverQue follow the order in the value. So, this problem could be solved if make active server to the first of this queue. But I don't know how to get active server hostname in client side. Look forward to your suggestions. image

PHILO-HE commented 3 years ago

I worked out a patch. See #2229. A local tmp file is used to record newly found active server and retry mechanism is still kept.

lipppppp commented 3 years ago

Thanks. I will test this patch later.

lipppppp commented 3 years ago

This problem solved by #2229. Thanks for @PHILO-HE's support.