Search in sources :

Example 1 with WSRefRegistry

use of org.jboss.as.webservices.webserviceref.WSRefRegistry in project wildfly by wildfly.

the class ASHelper method getWSRefRegistry.

public static WSRefRegistry getWSRefRegistry(final DeploymentUnit unit) {
    WSRefRegistry refRegistry = unit.getAttachment(WSAttachmentKeys.WS_REFREGISTRY);
    if (refRegistry == null) {
        refRegistry = WSRefRegistry.newInstance();
        unit.putAttachment(WSAttachmentKeys.WS_REFREGISTRY, refRegistry);
    }
    return refRegistry;
}
Also used : WSRefRegistry(org.jboss.as.webservices.webserviceref.WSRefRegistry)

Example 2 with WSRefRegistry

use of org.jboss.as.webservices.webserviceref.WSRefRegistry in project wildfly by wildfly.

the class UnifiedServiceRefDeploymentAspect method start.

@Override
public void start(final Deployment dep) {
    final DeploymentUnit unit = getRequiredAttachment(dep, DeploymentUnit.class);
    WSRefRegistry wsRefRegistry = ASHelper.getWSRefRegistry(unit);
    Object obj = dep.getProperty("ServiceAddressMap");
    if (obj != null) {
        @SuppressWarnings("unchecked") Map<QName, String> deployedPortsAddress = (Map<QName, String>) obj;
        for (UnifiedServiceRefMetaData metaData : wsRefRegistry.getUnifiedServiceRefMetaDatas()) {
            metaData.addDeployedServiceAddresses(deployedPortsAddress);
        }
    }
}
Also used : WSRefRegistry(org.jboss.as.webservices.webserviceref.WSRefRegistry) QName(javax.xml.namespace.QName) UnifiedServiceRefMetaData(org.jboss.wsf.spi.metadata.j2ee.serviceref.UnifiedServiceRefMetaData) DeploymentUnit(org.jboss.as.server.deployment.DeploymentUnit) Map(java.util.Map)

Aggregations

WSRefRegistry (org.jboss.as.webservices.webserviceref.WSRefRegistry)2 Map (java.util.Map)1 QName (javax.xml.namespace.QName)1 DeploymentUnit (org.jboss.as.server.deployment.DeploymentUnit)1 UnifiedServiceRefMetaData (org.jboss.wsf.spi.metadata.j2ee.serviceref.UnifiedServiceRefMetaData)1