Hi all, I was working on a new feature in HIVE-12730 and I was suggested by Ashutosh to put a configuration in EnvironmentContext. Then I found that we have lots of cases where the configuration and EnvironmentContext both exist in separate functions in the API list. For example, we have
public void alter_table(String dbname, String tbl_name, Table new_tbl) throws InvalidOperationException, MetaException, org.apache.thrift.TException; public void alter_table_with_environment_context(String dbname, String tbl_name, Table new_tbl, EnvironmentContext environment_context) throws InvalidOperationException, MetaException, org.apache.thrift.TException; public void alter_table_with_cascade(String dbname, String tbl_name, Table new_tbl, boolean cascade) throws InvalidOperationException, MetaException, org.apache.thrift.TException; My plan is to keep only public void alter_table_with_environment_context(String dbname, String tbl_name, Table new_tbl, EnvironmentContext environment_context) throws InvalidOperationException, MetaException, org.apache.thrift.TException; And then merge the other two into this single one at both client and server side. For example, put cascade in the environment_context at client side and then read it from server side. If we do so, then it is easy to extend in the future, for example, my current work in HIVE-12730. The patch is already there but Sergey has some concerns about backward compatibility. Could you please leave your comments/suggestions? Thanks a lot. Best Pengcheng