Tabnine Logo
GlassfishNamingManager.publishObject
Code IndexAdd Tabnine to your IDE (free)

How to use
publishObject
method
in
org.glassfish.api.naming.GlassfishNamingManager

Best Java code snippets using org.glassfish.api.naming.GlassfishNamingManager.publishObject (Showing top 17 results out of 315)

origin: org.glassfish.ejb/ejb-container

void publish(GlassfishNamingManager nm) throws NamingException {
  // If it's a portable name, use rebind since the name is guaranteed
  // to be unique.  Otherwise, use bind() so we detect any clashes.
  // NOTE : Will need to revisit this if we allow a developer-specified
  // portable JNDI name.
  boolean rebind = portable;
  if( cosNaming ) {
    nm.publishCosNamingObject(name, object, rebind);
  } else {
    nm.publishObject(name, object, rebind);
  }
  publishedSuccessfully = true;
}
origin: org.glassfish.main.ejb/ejb-container

void publish(GlassfishNamingManager nm) throws NamingException {
  // If it's a portable name, use rebind since the name is guaranteed
  // to be unique.  Otherwise, use bind() so we detect any clashes.
  // NOTE : Will need to revisit this if we allow a developer-specified
  // portable JNDI name.
  boolean rebind = portable;
  if( cosNaming ) {
    nm.publishCosNamingObject(name, object, rebind);
  } else {
    nm.publishObject(name, object, rebind);
  }
  publishedSuccessfully = true;
}
origin: org.glassfish.main.common/container-common

public void postConstruct() {
  // When in the server, register in JNDI to allow container code without
  // compile-time dependency on GlassFish to use injection services.
  // We know GlassFishNaming manager is available because it's an injected field.
  if( processEnv.getProcessType().isServer() ) {
    try {
      glassfishNamingManager.publishObject("com.sun.enterprise.container.common.spi.util.InjectionManager",
        this, true);
    } catch(NamingException ne) {
      throw new RuntimeException(ne);
    }
  }
}
origin: org.glassfish.main.core/javaee-kernel

  public void postConstruct() {
    GlassfishNamingManager gfNamingManager =
      gfNamingManagerProvider.get();

    MEJBNamingObjectProxy mejbProxy = 
      new MEJBNamingObjectProxy(habitat);
    for(String next : MEJBNamingObjectProxy.getJndiNames()) {
      try {
        gfNamingManager.publishObject(next, mejbProxy, true);
      } catch (Exception e) {
        _logger.log(Level.WARNING, "Problem in publishing temp proxy for MEJB: " + 
          e.getMessage(), e);
      }
    }
  }
}
origin: org.glassfish.main.transaction/transaction-internal-api

if (nm != null) {
  try {
    nm.publishObject(USER_TX_NO_JAVA_COMP, new NamingObjectProxy.InitializationNamingObjectProxy() {
      @Override
      public Object create(Context ic) throws NamingException {
origin: org.glassfish.common/container-common

public void postConstruct() {
  // When in the server, register in JNDI to allow container code without
  // compile-time dependency on GlassFish to use injection services.
  // We know GlassFishNaming manager is available because it's an injected field.
  if( processEnv.getProcessType().isServer() ) {
    try {
      glassfishNamingManager.publishObject("com.sun.enterprise.container.common.spi.util.InjectionManager",
        this, true);
    } catch(NamingException ne) {
      throw new RuntimeException(ne);
    }
  }
}
origin: eclipse-ee4j/glassfish

if (nm != null) {
  try {
    nm.publishObject(USER_TX_NO_JAVA_COMP, new NamingObjectProxy.InitializationNamingObjectProxy() {
      @Override
      public Object create(Context ic) throws NamingException {
origin: org.glassfish.connectors/connectors-internal-api

private void bindAppScopedNameForAppclient(Object object, String jndiName, String applicationName)
    throws NamingException {
  String internalGlobalJavaAppName =
      cnu.composeInternalGlobalJavaAppName(applicationName, getAppScopedName(jndiName));
  if(_logger.isLoggable(Level.FINEST)){
    debug("binding app-scoped-resource for appclient : " + internalGlobalJavaAppName);
  }
  namingManager.publishObject(internalGlobalJavaAppName, object, true);
}
origin: org.glassfish.main.resourcebase.resources/nucleus-resources

private void bindAppScopedNameForAppclient(Object object, String jndiName, String applicationName)
    throws NamingException {
  String internalGlobalJavaAppName =
      cnu.composeInternalGlobalJavaAppName(applicationName, getAppScopedName(jndiName));
  if(_logger.isLoggable(Level.FINEST)){
    debug("binding app-scoped-resource for appclient : " + internalGlobalJavaAppName);
  }
  namingManager.publishObject(internalGlobalJavaAppName, object, true);
}
origin: org.glassfish.common/container-common

private void bindConnectorDescriptorProxies(String rarName) {
  //these proxies are needed as appclient container may lookup descriptors
  String jndiName = ConnectorsUtil.getReservePrefixedJNDINameForDescriptor(rarName);
  ConnectorDescriptorProxy proxy = habitat.getComponent(ConnectorDescriptorProxy.class);
  proxy.setJndiName(jndiName);
  proxy.setRarName(rarName);
  try {
    namingMgr.publishObject(jndiName, proxy, true);
  } catch (NamingException e) {
    Object[] params = new Object[]{rarName, e};
    logger.log(Level.WARNING, "resources.resource-manager.connector-descriptor.bind.failure", params);
  }
}
origin: org.glassfish.connectors/connectors-runtime

    + " publishing descriptor " + descriptorJNDIName);
_runtime.getNamingManager().publishObject(descriptorJNDIName, connectorDescriptor, true);
origin: org.glassfish.main.resourcebase.resources/nucleus-resources

  bindAppScopedNameForAppclient(object, jndiName, applicationName);
}else{
  namingManager.publishObject(jndiName, object, true);
origin: org.glassfish.connectors/connectors-internal-api

  bindAppScopedNameForAppclient(object, jndiName, applicationName);
}else{
  namingManager.publishObject(jndiName, object, true);
origin: org.glassfish.main.common/container-common

namingManager.publishObject(next.getName(), next.getValue(), true);
      componentNamingUtil.composeInternalGlobalJavaAppName(app.getAppName(),
          next.getName());
  namingManager.publishObject(internalGlobalJavaAppName, next.getValue(), true);
origin: org.glassfish.common/container-common

  namingManager.publishObject(jndiName, namingProxy, true);
} else {
origin: org.glassfish.main.common/container-common

  namingManager.publishObject(jndiName, namingProxy, true);
} else {
origin: org.glassfish.common/container-common

namingManager.publishObject(next.getName(), next.getValue(), true);
      componentNamingUtil.composeInternalGlobalJavaAppName(app.getAppName(),
          next.getName());
  namingManager.publishObject(internalGlobalJavaAppName, next.getValue(), true);
org.glassfish.api.namingGlassfishNamingManagerpublishObject

Javadoc

Publish an object in the naming service.

Popular methods of GlassfishNamingManager

  • getInitialContext
    Get the initial context.
  • unpublishObject
    Remove an object from the naming service.
  • bindToAppNamespace
    Binds the bindings to module namespace of an application Typically, to get access to application's n
  • restoreJavaCompEnvContext
    Recreate a context for java:comp/env or one of its sub-contexts given the context name.
  • lookup
    Lookup a naming entry for a particular componentId
  • bindToComponentNamespace
    This method enumerates the env properties, ejb and resource references etc for a J2EE component and
  • bindToModuleNamespace
    Binds the bindings to module namespace of an application Typically, to get access to application's m
  • lookupFromAppNamespace
    Lookup a naming entry in a particular application's namespace
  • lookupFromModuleNamespace
    Lookup a naming entry in a particular application's module's namespace
  • publishCosNamingObject
    Publish a CosNaming object. The object is published to both the server's CosNaming service and the g
  • unbindAppObject
    Remove an object from the application's namespace. Typically, to get access to application's namespa
  • unbindAppObjects
    Unbind app and module level bindings for the given app name.
  • unbindAppObject,
  • unbindAppObjects,
  • unbindComponentObjects,
  • unbindModuleObject,
  • unpublishCosNamingObject,
  • initializeRemoteNamingSupport

Popular in Java

  • Start an intent from android
  • getSupportFragmentManager (FragmentActivity)
  • putExtra (Intent)
  • getSharedPreferences (Context)
  • IOException (java.io)
    Signals a general, I/O-related error. Error details may be specified when calling the constructor, a
  • Collections (java.util)
    This class consists exclusively of static methods that operate on or return collections. It contains
  • NoSuchElementException (java.util)
    Thrown when trying to retrieve an element past the end of an Enumeration or Iterator.
  • ImageIO (javax.imageio)
  • JComboBox (javax.swing)
  • JList (javax.swing)
  • Top plugins for WebStorm
Tabnine Logo
  • Products

    Search for Java codeSearch for JavaScript code
  • IDE Plugins

    IntelliJ IDEAWebStormVisual StudioAndroid StudioEclipseVisual Studio CodePyCharmSublime TextPhpStormVimGoLandRubyMineEmacsJupyter NotebookJupyter LabRiderDataGripAppCode
  • Company

    About UsContact UsCareers
  • Resources

    FAQBlogTabnine AcademyTerms of usePrivacy policyJava Code IndexJavascript Code Index
Get Tabnine for your IDE now