anoopsjohn commented on pull request #3671:
URL: https://github.com/apache/hbase/pull/3671#issuecomment-916625217


   > @anoopsjohn Looking at the code, we use ReadOnlyConfiguration in 
CoprocessorEnvironment to prevent CPs change the configuration.
   > 
   > But we do have a getConnection method in CoprceossorEnvironment and it 
also has a getConfiguration method, which will return the Configuration object 
directly, should we also make it read only for CP?
   > 
   > And another problem here is that, the sub classes for Region and Store are 
not only used in CPs right? So making the getConfiguration method returns only 
read only copy of the Configuration object is not suitable, maybe we should 
name it getReadOnlyConfiguration?
   
   +1 for making an explicit name.   BTW the config object what we get from 
Region and Store are a compound conf one?  I mean, we allow to make configs at 
table specific. For one table we can override a config value.  Now when we get 
the conf using this new method in Region, it will reflect this overridden 
value?  May be some thing we can check. I believe it might.  
   
   getConnection().getConf() exposing conf!  hmm.. May be we can see how to 
correct it. In another issue. I dont think within our code also, we do have any 
need to write/update anything to conf.  Whenever we need (like when we create 
connection for Replication etc), we will create new Conf object 


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


Reply via email to