Tabnine Logo
AutoConfig.getResourceId
Code IndexAdd Tabnine to your IDE (free)

How to use
getResourceId
method
in
org.apache.openejb.config.AutoConfig

Best Java code snippets using org.apache.openejb.config.AutoConfig.getResourceId (Showing top 15 results out of 315)

origin: org.apache.geronimo.ext.openejb/openejb-core

private String getResourceId(String beanName, String resourceId, String type, AppResources appResources) throws OpenEJBException {
  return getResourceId(beanName, resourceId, type, null, appResources);
}
origin: org.apache.openejb/openejb-core

private String getResourceId(final String beanName, final String resourceId, final String type, final AppResources appResources) throws OpenEJBException {
  return getResourceId(beanName, resourceId, type, null, appResources);
}
origin: org.apache.tomee/openejb-core

private String getResourceId(final String beanName, final String resourceId, final String type, final AppResources appResources) throws OpenEJBException {
  return getResourceId(beanName, resourceId, type, null, appResources);
}
origin: org.apache.geronimo.ext.openejb/openejb-core

private String installResource(String beanName, ResourceInfo resourceInfo) throws OpenEJBException {
  String resourceAdapterId = resourceInfo.properties.getProperty("ResourceAdapter");
  if (resourceAdapterId != null) {
    String newResourceId = getResourceId(beanName, resourceAdapterId, null, null);
    if (resourceAdapterId != newResourceId) {
      resourceInfo.properties.setProperty("ResourceAdapter", newResourceId);
    }
  }
  String dataSourceId = resourceInfo.properties.getProperty("DataSource");
  if (dataSourceId != null && dataSourceId.length() > 0) {
    String newResourceId = getResourceId(beanName, dataSourceId, null, null);
    if (dataSourceId != newResourceId) {
      resourceInfo.properties.setProperty("DataSource", newResourceId);
    }
  }
  configFactory.install(resourceInfo);
  return resourceInfo.id;
}
origin: org.apache.tomee/openejb-core

private String installResource(final String beanName, final ResourceInfo resourceInfo) throws OpenEJBException {
  final String resourceAdapterId = resourceInfo.properties.getProperty("ResourceAdapter");
  if (resourceAdapterId != null) {
    final String newResourceId = getResourceId(beanName, resourceAdapterId, null, null);
    if (!resourceAdapterId.equals(newResourceId)) {
      resourceInfo.properties.setProperty("ResourceAdapter", newResourceId);
    }
  }
  final String dataSourceId = resourceInfo.properties.getProperty("DataSource");
  if (dataSourceId != null && dataSourceId.length() > 0) {
    final String newResourceId = getResourceId(beanName, dataSourceId, null, null);
    if (!dataSourceId.equals(newResourceId)) {
      resourceInfo.properties.setProperty("DataSource", newResourceId);
    }
  }
  configFactory.install(resourceInfo);
  return resourceInfo.id;
}
origin: org.apache.openejb/openejb-core

private String installResource(final String beanName, final ResourceInfo resourceInfo) throws OpenEJBException {
  final String resourceAdapterId = resourceInfo.properties.getProperty("ResourceAdapter");
  if (resourceAdapterId != null) {
    final String newResourceId = getResourceId(beanName, resourceAdapterId, null, null);
    if (!resourceAdapterId.equals(newResourceId)) {
      resourceInfo.properties.setProperty("ResourceAdapter", newResourceId);
    }
  }
  final String dataSourceId = resourceInfo.properties.getProperty("DataSource");
  if (dataSourceId != null && dataSourceId.length() > 0) {
    final String newResourceId = getResourceId(beanName, dataSourceId, null, null);
    if (!dataSourceId.equals(newResourceId)) {
      resourceInfo.properties.setProperty("DataSource", newResourceId);
    }
  }
  configFactory.install(resourceInfo);
  return resourceInfo.id;
}
origin: org.apache.openejb/openejb-core

private String createContainer(final Class<? extends ContainerInfo> containerInfoType, final EjbDeployment ejbDeployment, final EnterpriseBean bean) throws OpenEJBException {
  if (!autoCreateContainers) {
    throw new OpenEJBException("A container of type " + getType(bean) + " must be declared in the configuration file for bean: " + bean.getEjbName());
  }
  // get the container info (data used to build the container)
  final ContainerInfo containerInfo = configFactory.configureService(containerInfoType);
  logger.info("Auto-creating a container for bean " + ejbDeployment.getDeploymentId() + ": Container(type=" + getType(bean) + ", id=" + containerInfo.id + ")");
  // if the is an MDB container we need to resolve the resource adapter
  final String resourceAdapterId = containerInfo.properties.getProperty("ResourceAdapter");
  if (resourceAdapterId != null) {
    final String newResourceId = getResourceId(ejbDeployment.getDeploymentId(), resourceAdapterId, null, null);
    if (resourceAdapterId.equals(newResourceId)) {
      containerInfo.properties.setProperty("ResourceAdapter", newResourceId);
    }
  }
  // install the container
  configFactory.install(containerInfo);
  return containerInfo.id;
}
origin: org.apache.tomee/openejb-core

private String createContainer(final Class<? extends ContainerInfo> containerInfoType, final EjbDeployment ejbDeployment, final EnterpriseBean bean) throws OpenEJBException {
  if (!autoCreateContainers) {
    throw new OpenEJBException("A container of type " + getType(bean) + " must be declared in the configuration file for bean: " + bean.getEjbName());
  }
  // get the container info (data used to build the container)
  final ContainerInfo containerInfo = configFactory.configureService(containerInfoType);
  logger.info("Auto-creating a container for bean " + ejbDeployment.getDeploymentId() + ": Container(type=" + getType(bean) + ", id=" + containerInfo.id + ")");
  // if the is an MDB container we need to resolve the resource adapter
  final String resourceAdapterId = containerInfo.properties.getProperty("ResourceAdapter");
  if (resourceAdapterId != null) {
    final String newResourceId = getResourceId(ejbDeployment.getDeploymentId(), resourceAdapterId, null, null);
    if (resourceAdapterId.equals(newResourceId)) {
      containerInfo.properties.setProperty("ResourceAdapter", newResourceId);
    }
  }
  // install the container
  configFactory.install(containerInfo);
  return containerInfo.id;
}
origin: org.apache.geronimo.ext.openejb/openejb-core

private String createContainer(Class<? extends ContainerInfo> containerInfoType, EjbDeployment ejbDeployment, EnterpriseBean bean) throws OpenEJBException {
  if (!autoCreateContainers) {
    throw new OpenEJBException("A container of type " + getType(bean) + " must be declared in the configuration file for bean: " + bean.getEjbName());
  }
  // get the container info (data used to build the container)
  ContainerInfo containerInfo = configFactory.configureService(containerInfoType);
  logger.info("Auto-creating a container for bean " + ejbDeployment.getDeploymentId() + ": Container(type=" + getType(bean) + ", id=" + containerInfo.id + ")");
  // if the is an MDB container we need to resolve the resource adapter
  String resourceAdapterId = containerInfo.properties.getProperty("ResourceAdapter");
  if (resourceAdapterId != null) {
    String newResourceId = getResourceId(ejbDeployment.getDeploymentId(), resourceAdapterId, null, null);
    if (resourceAdapterId != newResourceId) {
      containerInfo.properties.setProperty("ResourceAdapter", newResourceId);
    }
  }
  // install the container
  configFactory.install(containerInfo);
  return containerInfo.id;
}
origin: org.apache.tomee/openejb-core

        appResources);
      if (newId != null) { // app scoped resources, try to find it without creating it first
        id = getResourceId(ejbModule.getModuleId(), newId, refType, appResources);
      } else {
        id = getResourceId(ejbDeployment.getDeploymentId(), id, refType, appResources);
      id = getResourceId(ejbDeployment.getDeploymentId(), id, refType, appResources);
  ejbDeployment.addResourceLink(link);
} else {
  final String id = getResourceId(ejbDeployment.getDeploymentId(), link.getResId(), refType, appResources);
  link.setResId(id);
  link.setResRefName(refName);
origin: org.apache.openejb/openejb-core

          appResources);
      if (newId != null) { // app scoped resources, try to find it without creating it first
        id = getResourceId(ejbModule.getModuleId(), newId, refType, appResources);
      } else {
        id = getResourceId(ejbDeployment.getDeploymentId(), id, refType, appResources);
      id = getResourceId(ejbDeployment.getDeploymentId(), id, refType, appResources);
  ejbDeployment.addResourceLink(link);
} else {
  final String id = getResourceId(ejbDeployment.getDeploymentId(), link.getResId(), refType, appResources);
  link.setResId(id);
  link.setResRefName(refName);
origin: org.apache.geronimo.ext.openejb/openejb-core

private void processResourceRef(ResourceRef ref, EjbDeployment ejbDeployment, AppResources appResources) throws OpenEJBException {
  // skip destinations with a global jndi name
  String mappedName = ref.getMappedName();
  if (mappedName == null) mappedName = "";
  if ((mappedName).startsWith("jndi:")){
    return;
  }
  String refName = ref.getName();
  String refType = ref.getType();
  // skip references such as URLs which are automatically handled by the server
  if (ignoredReferenceTypes.contains(refType)) {
    return;
  }
  ResourceLink link = ejbDeployment.getResourceLink(refName);
  if (link == null) {
    String id = (mappedName.length() == 0) ? ref.getName() : mappedName;
    id = getResourceId(ejbDeployment.getDeploymentId(), id, refType, appResources);
    logger.info("Auto-linking resource-ref '" + refName + "' in bean " + ejbDeployment.getDeploymentId() + " to Resource(id=" + id + ")");
    link = new ResourceLink();
    link.setResId(id);
    link.setResRefName(refName);
    ejbDeployment.addResourceLink(link);
  } else {
    String id = getResourceId(ejbDeployment.getDeploymentId(), link.getResId(), refType, appResources);
    link.setResId(id);
    link.setResRefName(refName);
  }
}
origin: org.apache.geronimo.ext.openejb/openejb-core

destinationId = getResourceId(moduleId, destinationId, ref.getType(), appResources);
ref.setMappedName(destinationId);
origin: org.apache.tomee/openejb-core

  destinationId = getResourceId(moduleId, destinationId, refType, appResources);
} catch (final OpenEJBException ex) {
  if (!(ref instanceof ContextRef)) {
origin: org.apache.openejb/openejb-core

  destinationId = getResourceId(moduleId, destinationId, refType, appResources);
} catch (final OpenEJBException ex) {
  if (!(ref instanceof ContextRef)) {
org.apache.openejb.configAutoConfiggetResourceId

Popular methods of AutoConfig

  • <init>
  • autoCreateContainers
  • autoCreateResources
  • findResourceId
  • autoCreateResource
  • checkUnitDataSourceRefs
  • copy
  • createContainer
  • deploy
  • findResourceProviderId
  • firstMatching
  • getResourceEnvId
  • firstMatching,
  • getResourceEnvId,
  • getResourceIds,
  • getType,
  • getUsableContainer,
  • installResource,
  • isJms,
  • logAutoCreateResource,
  • normalizeResourceId

Popular in Java

  • Start an intent from android
  • getApplicationContext (Context)
  • setRequestProperty (URLConnection)
  • compareTo (BigDecimal)
  • Socket (java.net)
    Provides a client-side TCP socket.
  • Vector (java.util)
    Vector is an implementation of List, backed by an array and synchronized. All optional operations in
  • ConcurrentHashMap (java.util.concurrent)
    A plug-in replacement for JDK1.5 java.util.concurrent.ConcurrentHashMap. This version is based on or
  • JarFile (java.util.jar)
    JarFile is used to read jar entries and their associated data from jar files.
  • Filter (javax.servlet)
    A filter is an object that performs filtering tasks on either the request to a resource (a servlet o
  • JTable (javax.swing)
  • Github Copilot alternatives
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