You are viewing a plain text version of this content. The canonical link for it is here.
Posted to notifications@shardingsphere.apache.org by GitBox <gi...@apache.org> on 2020/07/17 08:49:31 UTC

[GitHub] [shardingsphere] SirMin commented on pull request #6359: HintManager's getInstance returns the instance held by the current th…

SirMin commented on pull request #6359:
URL: https://github.com/apache/shardingsphere/pull/6359#issuecomment-659969854


   Hi @tristaZero HintManager's getInstance is thread safe beacuse the instance put to ThreadLocal,  in different threads  will not get the same instance.
   
   The connection will be managed by most frameworks. If it is too costly to manage the HintManager like a connection, and we must clear it after setting up the HintManager, otherwise the next call will report an exception, so I cannot see the modification to get The HintManager held by the current thread has any bad


----------------------------------------------------------------
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.

For queries about this service, please contact Infrastructure at:
users@infra.apache.org