I am searching for a mechanism to pass arbitrary context in RMI calls. My application needs to support multiple vendors.
The best solution for me is CORBA Portable Interceptors. That is supported by Sun JES, JBOSS and IBM WebSphere.
WebLogic has a proprietary feature called WorkContext, which is a hash map that can be looked up from the JNDI server.
Oracle 9.x and up has a proprietary RMI implementation, namely ORMI. So I cannot assume any compatibility with RMI from Java JDK. There is no reference in the Oracle documentation regarding support for CORBA Portable Interceptors or any other mechanism for context propagation.