/** * Get the bean validation groups * @param id The MDR identifier * @return The groups; <code>null</code> if none were found */ private Set<String> getBeanValidationGroups(String id) { if (id == null || id.equals("")) return null; try { Activation a = mdr.getActivation(id); if (a != null && a.getBeanValidationGroups() != null && a.getBeanValidationGroups().size() > 0) { Set<String> groups = new HashSet<String>(); for (String group : a.getBeanValidationGroups()) { groups.add(group); } return groups; } } catch (Throwable t) { log.debugf(t, "Exception while loading ironjacamar.xml: %s", id); } return null; }
for (String id : mdr.getResourceAdapters()) Connector raXml = mdr.getResourceAdapter(id); if (raXml != null)
for (String entry : mdr.getResourceAdapters()) if (mdr.hasJndiMappings(deployment) || hasResourceAdapter(rar, mdr.getResourceAdapter(deployment))) configured.add(deployment); try Connector raXml = mdr.getResourceAdapter(deployment); for (String entry : mdr.getResourceAdapters()) Connector entryXml = mdr.getResourceAdapter(entry);
Set<String> deployments = ((RAConfiguration) getConfiguration()).getMetadataRepository().getResourceAdapters(); Connector cmd = mdr.getResourceAdapter(deployment.toExternalForm()); File root = mdr.getRoot(deployment.toExternalForm());
@Override protected javax.resource.spi.ResourceAdapter createRa(String uniqueId, ClassLoader cl) throws NotFoundException, Exception, DeployException { Connector md = mdr.getResourceAdapter(uniqueId); ResourceAdapter ra = md.getResourceadapter(); List<? extends ConfigProperty> l = new ArrayList<ConfigProperty>(); javax.resource.spi.ResourceAdapter rar = (javax.resource.spi.ResourceAdapter)initAndInject(ra.getResourceadapterClass(), l, cl); return rar; }
Connector cmd = metadataRepository.getResourceAdapter(url.toExternalForm()); Activation activation = metadataRepository.getActivation(url.toExternalForm());
ResourceAdapterRepository rar = ((RAConfiguration) getConfiguration()).getResourceAdapterRepository(); Set<String> rarDeployments = mdr.getResourceAdapters(); Set<String> configuredRars = getConfiguredResourceAdapters(mdr, rar);
@Override public String[] bindAdminObject(URL url, String deployment, Object ao) throws Throwable { JndiStrategy js = ((RAConfiguration) getConfiguration()).getJndiStrategy().clone(); String[] result = js.bindAdminObjects(deployment, new Object[]{ao}); ((RAConfiguration) getConfiguration()).getMetadataRepository().registerJndiMapping(url.toExternalForm(), ao.getClass().getName(), result[0]); log.infof("Bound admin object under: %s", result[0]); return result; }
/** * Stop */ @Override public void stop() { super.stop(); if (mdr != null) { try { mdr.unregisterResourceAdapter(deployment.toExternalForm()); } catch (Throwable t) { log.warn("Exception during unregistering deployment in the metadata repository", t); } } }
@Override protected void registerResourceAdapterToMDR(URL url, File root, Connector cmd, Activation activation) throws org.jboss.jca.core.spi.mdr.AlreadyExistsException { ((RAConfiguration) getConfiguration()).getMetadataRepository(). registerResourceAdapter(url.toExternalForm(), root, cmd, activation); }
String jndi = cfJndis[i]; mdr.unregisterJndiMapping(deployment.toExternalForm(), cf, jndi); String jndi = aoJndis[i]; mdr.unregisterJndiMapping(deployment.toExternalForm(), ao, jndi);
/** * Is the resource adapter a 1.6 archive * @param id The MDR identifier * @return True if 1.6; otherwise false */ private boolean is16(String id) { if (id == null || id.equals("")) return false; try { Connector raXml = mdr.getResourceAdapter(id); if (raXml != null) { return (raXml.getVersion() == Version.V_16 || raXml.getVersion() == Version.V_17); } } catch (Throwable t) { log.debugf(t, "Exception while loading ra.xml: %s", id); } return false; }
Set<String> raDeployments = mdr.getResourceAdapters(); String uniqueJdbcLocalId = null; String uniqueJdbcXAId = null;
@Override public String[] bindAdminObject(URL url, String deployment, Object ao, String jndi) throws Throwable { JndiStrategy js = ((RAConfiguration) getConfiguration()).getJndiStrategy().clone(); String[] result = js.bindAdminObjects(deployment, new Object[]{ao}, new String[]{jndi}); ((RAConfiguration) getConfiguration()).getMetadataRepository().registerJndiMapping(url.toExternalForm(), ao.getClass().getName(), jndi); log.infof("Bound admin object under: %s", jndi); return result; }
/** * Stop */ @Override public void stop() { super.stop(); if (mdr != null) { try { mdr.unregisterResourceAdapter(deployment.toExternalForm()); } catch (Throwable t) { log.warn("Exception during unregistering deployment in the metadata repository", t); } } } }
Connector md = null; Set<String> mdrKeys = mdr.getResourceAdapters(); Iterator<String> mdrIt = mdrKeys.iterator(); try Connector c = mdr.getResourceAdapter(mdrId);
/** * Get the product name for the resource adapter * @param id The MDR identifier * @return The value */ private String getProductName(String id) { if (id == null || id.equals("")) return ""; try { Connector raXml = mdr.getResourceAdapter(id); if (raXml != null && !XsdString.isNull(raXml.getEisType())) { return raXml.getEisType().getValue(); } } catch (Throwable t) { log.debugf(t, "Exception while loading ra.xml: %s", id); } return ""; }
@Override public String[] bindConnectionFactory(URL url, String deployment, Object cf) throws Throwable { JndiStrategy js = ((RAConfiguration) getConfiguration()).getJndiStrategy().clone(); String[] result = js.bindConnectionFactories(deployment, new Object[]{cf}); ((RAConfiguration) getConfiguration()).getMetadataRepository().registerJndiMapping(url.toExternalForm(), cf.getClass().getName(), result[0]); log.infof("Bound connection factory under: %s", result[0]); return result; }
Connector md = null; Set<String> mdrKeys = mdr.getResourceAdapters(); Iterator<String> mdrIt = mdrKeys.iterator(); try Connector c = mdr.getResourceAdapter(mdrId);
/** * Get the product version for the resource adapter * @param id The MDR identifier * @return The value */ private String getProductVersion(String id) { if (id == null || id.equals("")) return ""; try { Connector raXml = mdr.getResourceAdapter(id); if (raXml != null) { if (!XsdString.isNull(raXml.getResourceadapterVersion())) return raXml.getResourceadapterVersion().getValue(); } } catch (Throwable t) { log.debugf(t, "Exception while loading ra.xml: %s", id); } return ""; }