what is a naming Context physically?


General J2EE: what is a naming Context physically?

  1. what is a naming Context physically? (2 messages)

    Hi all
    I am really not able to visualise a 'Context' physically.We set up a resource file, get an instance of Context from ContextFactory and use the context to get an instance of EJB or something. What is this 'Context'?


    Threaded Messages (2)

  2. Contexts are just a generic "lookup" mechanism. They don't necessarily have any physical component.

    The JNDI (Java Naming and Directory Interface) API, from which contexts are derived, is used in Java to look up all kinds of things: server resources (including EJBs, datasources and messaging connections), LDAP structures, files in the file systems, CORBA names, etc.

    The idea behind JNDI is to match resources (objects) with string ids (the JNDI name) which you can use to retrieve that resource.
  3. Context[ Go to top ]

    Context is nothing just a your object's gateway to interact with placeholder where it loads.

    Like in case of EJB it is provides mechanism to interact with container,in case of servlet ServletContext serves same purpose similarly AppletContext behaves.