Package org.jboss.system.metadata

Examples of org.jboss.system.metadata.ServiceAttributeMetaData


         constructor.setParameters(new Object[] { unit, this, deployment });
         webModule.setConstructor(constructor);

         List<ServiceAttributeMetaData> attrs = new ArrayList<ServiceAttributeMetaData>();

         ServiceAttributeMetaData attr = new ServiceAttributeMetaData();
         attr.setName("SecurityManagement");
         ServiceInjectionValueMetaData injectionValue = new ServiceInjectionValueMetaData(deployment.getSecurityManagementName());
         attr.setValue(injectionValue);
         attrs.add(attr);

         ServiceAttributeMetaData attrPR = new ServiceAttributeMetaData();
         attrPR.setName("PolicyRegistration");
         ServiceInjectionValueMetaData injectionValuePR = new ServiceInjectionValueMetaData(deployment.getPolicyRegistrationName());
         attrPR.setValue(injectionValuePR);
         attrs.add(attrPR);

         ServiceAttributeMetaData attrKernel = new ServiceAttributeMetaData();
         attrKernel.setName("Kernel");
         ServiceInjectionValueMetaData injectionValueKernel = new ServiceInjectionValueMetaData(KernelConstants.KERNEL_NAME);
         attrKernel.setValue(injectionValueKernel);
         attrs.add(attrKernel);

         webModule.setAttributes(attrs);

         // Dependencies...Still have old jmx names here
View Full Code Here


            ServiceDependencyMetaData serviceDependencyMetaData = new ServiceDependencyMetaData();
            serviceDependencyMetaData.setIDependOnObjectName(subjaccPolicy.getObjectName());
            parentServiceMetaData.addDependency(serviceDependencyMetaData);

            // Add an attribute in the parent service
            ServiceAttributeMetaData serviceAttributeMetaData = new ServiceAttributeMetaData();
            serviceAttributeMetaData.setName("PolicyConfigurationFacadeMBean");
            ServiceDependencyValueMetaData dependencyValue = new ServiceDependencyValueMetaData();
            dependencyValue.setDependency(subjaccPolicy.getObjectName().toString());
            dependencyValue.setProxyType("attribute");
            serviceAttributeMetaData.setValue(dependencyValue);
            parentServiceMetaData.addAttribute(serviceAttributeMetaData);
         }
      }
     
      /** Register XACML/ACL policies if present in the deployment */
 
View Full Code Here

      ejbModule.setConstructor(ctor);

      // set attributes
      List<ServiceAttributeMetaData> attrs = new ArrayList<ServiceAttributeMetaData>();
      // Transaction manager
      ServiceAttributeMetaData attr = new ServiceAttributeMetaData();
      attr.setName("TransactionManagerFactory");
      ServiceDependencyValueMetaData dependencyValue = new ServiceDependencyValueMetaData();
      dependencyValue.setDependency(getTransactionManagerServiceName());
      dependencyValue.setProxyType("attribute");
      attr.setValue(dependencyValue);
      attrs.add(attr);
      // Security management
      attr = new ServiceAttributeMetaData();
      attr.setName("SecurityManagement");
      ServiceInjectionValueMetaData injectionValue = new ServiceInjectionValueMetaData(securityManagementName);
      attr.setValue(injectionValue);
      attrs.add(attr);
      //Policy Registration
      attr = new ServiceAttributeMetaData();
      attr.setName("PolicyRegistration");
      ServiceInjectionValueMetaData prInjectionValue = new ServiceInjectionValueMetaData(policyRegistrationName);
      attr.setValue(prInjectionValue);
      attrs.add(attr);
      // Add injection of the WebServiceName
      String wsName = getWebServiceName();
      if (wsName != null)
      {
         ServiceAttributeMetaData ws = new ServiceAttributeMetaData();
         ws.setName("WebServiceName");
         ServiceDependencyValueMetaData wsDepends = new ServiceDependencyValueMetaData();
         wsDepends.setDependency(wsName);
         ws.setValue(wsDepends);
         attrs.add(ws);
      }
      // Injection of the TimerService
      ServiceAttributeMetaData tms = new ServiceAttributeMetaData();
      ServiceDependencyValueMetaData tmsDepends = new ServiceDependencyValueMetaData();
      tms.setName("TimerService");
      tmsDepends.setDependency(timerServiceName);
      tmsDepends.setProxyType("attribute");
      tms.setValue(tmsDepends);
      attrs.add(tms);

      ejbModule.setAttributes(attrs);
     
      List<ServiceDependencyMetaData> dependencies = new ArrayList<ServiceDependencyMetaData>();
View Full Code Here

         if (attributeValue == null)
         {
            String aname = mapAttributeName(md, name);
            if(aname != null)
            {
               ServiceAttributeMetaData attr = new ServiceAttributeMetaData();
               attr.setName(aname);
               // Check if this is mapped to a Element
               if(mappedType != null && mappedType.equals(Element.class))
               {
                  attributeValue = new ServiceElementValueMetaData();
               }
               else if(plainValue != null)
               {                
                  // Create a text value
                  String textValue = String.valueOf(plainValue);
                  // Don't create a empty value
                  if(textValue.trim().length() > 0 )
                     attributeValue = new ServiceTextValueMetaData(textValue);
               }
               // Don't create a null serviceAttribute
               if(attributeValue == null)
                  return;
              
               // Add
               attr.setValue(attributeValue);
               md.addAttribute(attr);
            }
         }
         if (attributeValue != null)
         {
View Full Code Here

/* 172 */     constructor.setSignature(new String[] { DataSourceDeployment.class.getName() });
/* 173 */     constructor.setParameters(new Object[] { ds });
/* 174 */     dsMbean.setConstructor(constructor);
/*     */
/* 177 */     List attributes = new ArrayList();
/* 178 */     ServiceAttributeMetaData attribute = new ServiceAttributeMetaData();
/*     */
/* 180 */     attribute.setName("JndiName");
/* 181 */     attribute.setReplace(true);
/* 182 */     attribute.setTrim(true);
/* 183 */     attribute.setValue(new ServiceTextValueMetaData(jndiName));
/* 184 */     attributes.add(attribute);
/*     */
/* 186 */     attribute = new ServiceAttributeMetaData();
/* 187 */     attribute.setName("JdbcURL");
/* 188 */     if (ds.getJdbcURL() != null)
/* 189 */       attribute.setValue(new ServiceTextValueMetaData(ds.getJdbcURL()));
/* 190 */     attributes.add(attribute);
/*     */
/* 192 */     attribute = new ServiceAttributeMetaData();
/* 193 */     attribute.setName("DriverClass");
/* 194 */     if (ds.getDriverClass() != null)
/* 195 */       attribute.setValue(new ServiceTextValueMetaData(ds.getDriverClass()));
/* 196 */     attributes.add(attribute);
/*     */
/* 198 */     attribute = new ServiceAttributeMetaData();
/* 199 */     attribute.setName("Username");
/* 200 */     if (ds.getUsername() != null)
/* 201 */       attribute.setValue(new ServiceTextValueMetaData(ds.getUsername()));
/* 202 */     attributes.add(attribute);
/*     */
/* 204 */     attribute = new ServiceAttributeMetaData();
/* 205 */     attribute.setName("Password");
/* 206 */     if (ds.getPassword() != null)
/* 207 */       attribute.setValue(new ServiceTextValueMetaData(ds.getPassword()));
/* 208 */     attributes.add(attribute);
/*     */
/* 210 */     attribute = new ServiceAttributeMetaData();
/* 211 */     attribute.setName("SecurityDomain");
/* 212 */     if (ds.getSecurityDomain() != null)
/* 213 */       attribute.setValue(new ServiceTextValueMetaData(ds.getSecurityDomain()));
/* 214 */     attributes.add(attribute);
/*     */
/* 216 */     attribute = new ServiceAttributeMetaData();
/* 217 */     attribute.setName("MinPoolSize");
/* 218 */     if (ds.getMinPoolSize() != null)
/* 219 */       attribute.setValue(new ServiceTextValueMetaData(ds.getMinPoolSize()));
/* 220 */     attributes.add(attribute);
/*     */
/* 222 */     attribute = new ServiceAttributeMetaData();
/* 223 */     attribute.setName("MaxPoolSize");
/* 224 */     if (ds.getMaxPoolSize() != null)
/* 225 */       attribute.setValue(new ServiceTextValueMetaData(ds.getMaxPoolSize()));
/* 226 */     attributes.add(attribute);
/*     */
/* 228 */     attribute = new ServiceAttributeMetaData();
/* 229 */     attribute.setName("ConnectionProperties");
/* 230 */     if (ds.getMaxPoolSize() != null)
/* 231 */       attribute.setValue(new ServiceTextValueMetaData(ds.getMaxPoolSize()));
/* 232 */     attributes.add(attribute);
/*     */
/* 234 */     dsMbean.setAttributes(attributes);
/*     */
/* 237 */     Collection depends = ds.getDepends();
View Full Code Here

/*     */   }
/*     */
/*     */   public List<ServiceAttributeMetaData> buildAttributes(ManagedConnectionFactoryDeploymentMetaData deployment)
/*     */   {
/*  70 */     List attributes = new ArrayList();
/*  71 */     ServiceAttributeMetaData attribute = buildDependencyAttribute("OldRarDeployment", "jboss.jca:service=RARDeployment,name='" + deployment.getRarName() + "'");
/*  72 */     attributes.add(attribute);
/*  73 */     return attributes;
/*     */   }
View Full Code Here

/*     */   }
/*     */
/*     */   public List<ServiceAttributeMetaData> buildAttributes(ManagedConnectionFactoryDeploymentMetaData md)
/*     */   {
/*  71 */     List poolAttributes = new ArrayList();
/*  72 */     ServiceAttributeMetaData poolAttribute = null;
/*     */
/*  74 */     poolAttribute = buildSimpleAttribute("PoolJndiName", md.getJndiName());
/*  75 */     poolAttributes.add(poolAttribute);
/*     */
/*  77 */     poolAttribute = buildSimpleAttribute("MinSize", String.valueOf(md.getMinSize()));
View Full Code Here

/*     */   private static final String BINDING = "org.jboss.ejb.plugins.cmp.jdbc.metadata.DataSourceMetaData";
/*     */
/*     */   public List<ServiceAttributeMetaData> buildAttributes(ManagedConnectionFactoryDeploymentMetaData md)
/*     */   {
/*  49 */     List attributes = new ArrayList();
/*  50 */     ServiceAttributeMetaData attribute = null;
/*     */
/*  52 */     attribute = buildDependencyAttribute("MetadataLibrary", "jboss.jdbc:service=metadata");
/*  53 */     attributes.add(attribute);
/*     */
/*  55 */     String typeMapping = null;
View Full Code Here

/*     */   private static final String CONNNECTION_FACTORY_JMX = "jboss.jca:service=ConnectionFactoryBinding,name=";
/*     */
/*     */   public List<ServiceAttributeMetaData> buildAttributes(ManagedConnectionFactoryDeploymentMetaData md)
/*     */   {
/*  52 */     List attributes = new ArrayList();
/*  53 */     ServiceAttributeMetaData attribute = new ServiceAttributeMetaData();
/*     */
/*  55 */     attribute = buildSimpleAttribute("JndiName", md.getJndiName());
/*  56 */     attributes.add(attribute);
/*     */
/*  58 */     attribute = buildSimpleAttribute("UseJavaContext", String.valueOf(md.isUseJavaContext()));
View Full Code Here

/*     */   private static final String POOL_JMX = "jboss.jca:service=ManagedConnectionPool,name=";
/*     */
/*     */   public List<ServiceAttributeMetaData> buildAttributes(ManagedConnectionFactoryDeploymentMetaData md)
/*     */   {
/*  53 */     List attributes = new ArrayList();
/*  54 */     ServiceAttributeMetaData attribute = null;
/*     */
/*  56 */     attribute = buildSimpleAttribute("JndiName", md.getJndiName());
/*  57 */     attributes.add(attribute);
/*     */
/*  59 */     attribute = buildDependencyAttribute("CachedConnectionManager", "jboss.jca:service=CachedConnectionManager");
View Full Code Here

TOP

Related Classes of org.jboss.system.metadata.ServiceAttributeMetaData

Copyright © 2018 www.massapicom. All rights reserved.
All source code are property of their respective owners. Java is a trademark of Sun Microsystems, Inc and owned by ORACLE Inc. Contact coftware#gmail.com.