ctubbsii opened a new pull request, #5420: URL: https://github.com/apache/accumulo/pull/5420
Static methods are removed in favor of non-static ones, since these methods are only ever called with the ServerContext, which already has an instance of the TableManager object. This allows removing an overloaded prepareNewTableState method, since the extra parameters on the overloaded method are always provided by methods on the ServerContext anyway. Additionally, this change removes the static set of registered ZooCache observers and table state cache, since the lifetime of ZooCache is already bound to the lifetime of the ServerContext, and these static objects should not exist longer than the TableManager instance attached to the same ServerContext. This fixes a potential bug with the ZooCache observers registered statically never firing again if the ServerContext is closed, even if an attempt is made to register them again with a new ServerContext. There is usually only one ServerContext for the lifetime of a server process, so this bug would probably not exist in practice, but this change avoids a potential bug if that assumption did not hold. -- This is an automated message from the Apache Git Service. To respond to the message, please log on to GitHub and use the URL above to go to the specific comment. To unsubscribe, e-mail: [email protected] For queries about this service, please contact Infrastructure at: [email protected]
