merlimat commented on issue #1943: Non serializable client builder
URL: 
https://github.com/apache/incubator-pulsar/issues/1943#issuecomment-395820413
 
 
   The problem has not an easy fix. The builders impl intrinsically hold 
references to non-serializable objects (eg: Client instance, or auth 
providers). 
   
   I think in contexts that needs to serialize the config and dispatch to 
multiple nodes, a better options is to pass the config arguments in serialized 
form and then construct the client with builder on the target machines.
   
   From Pulsar API perspective, we could ease that task by providing a way to 
load config from properties/yaml file. eg: 
   
   ```java
   PulsarClient.builder().loadConfigFromProperties("my-conf.properties").build()
   ```

----------------------------------------------------------------
This is an automated message from the Apache Git Service.
To respond to the message, please log on GitHub and use the
URL above to go to the specific comment.
 
For queries about this service, please contact Infrastructure at:
[email protected]


With regards,
Apache Git Services

Reply via email to