ctubbsii commented on issue #735: Move all static state into Client Context URL: https://github.com/apache/accumulo/issues/735#issuecomment-434422114 This is very close to my original intent with these contexts (except I did not anticipate the need for the compatibility behavior for Connector; I think what you've proposed to solve that is a good idea). However, to be clear, I think we should have a single ServerContext per service instance, not per JVM process (which is what I understood you to mean when you said "for the entire project" above). My original intent with these contexts was to provide full lifecycle management control over server components as well as clients, so server state should be self-contained in their own contexts, too. With that, we can do things like launch `Master.main()` and multiple `TServer.main()` in the same JVM with an in-process RPC implementation for an even faster "mock" or "mini" without sacrificing "real" Accumulo behavior. This intent also leaves a clear, logical path from user-provided configuration to functional object, regardless of whether it is a client or server, which would be good for cleaning up our server bootstrap code, which isn't very consistent across server processes: ``` Client(clientConfig) -> { clientState = new ClientContext(parse(clientConfig)) } OR Master(serverConfig) -> { serverState = new ServerContext(parse(serverConfig)) } TServer(serverConfig) -> { serverState = new ServerContext(parse(serverConfig)) } ```
---------------------------------------------------------------- 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
