public Object doInContext(Context ctx) throws NamingException {
                ctx.rebind(name, object);
                return null;
            }
Rebind the given object to the current JNDI context, using the given name.
Overwrites any existing binding.

@param name   the JNDI name of the object
@param object the object to rebind
@throws NamingException thrown by JNDI
core/src/main/java/org/apache/shiro/jndi/JndiTemplate.java