Hi, I wanto to access an object from a remote app, the client app which would perform the lookup will have to have a interface declaration of the object so it could try to cast when performing the look up, but then how do you get the implementation of the interface?, I've been reading that you can achieve it by specifying the codebase in the DirContext, but I cannot create the DirContext I'm using the following code:
Hashtable env = new Hashtable();
env.put(Context.INITIAL_CONTEXT_FACTORY,"com.sun.jndi.ldap.LdapCtxFactory");
env.put(Context.PROVIDER_URL, "ldap://localhost:389");
ctx = new InitialDirContext(env);
DirContext next = null;
StringTokenizer st = new StringTokenizer("tms-svc");
BasicAttributes battr = new BasicAttributes("javaCodebase","ctx.bind("tms-svc", timesSvc, battr);
I guess that the problem is that there is no ldap service enable or something and I haven't found anything about this, can someone help?, thanks in advance.
Hashtable env = new Hashtable();
env.put(Context.INITIAL_CONTEXT_FACTORY,"com.sun.jndi.ldap.LdapCtxFactory");
env.put(Context.PROVIDER_URL, "ldap://localhost:389");
ctx = new InitialDirContext(env);
DirContext next = null;
StringTokenizer st = new StringTokenizer("tms-svc");
BasicAttributes battr = new BasicAttributes("javaCodebase","ctx.bind("tms-svc", timesSvc, battr);
I guess that the problem is that there is no ldap service enable or something and I haven't found anything about this, can someone help?, thanks in advance.