Package com.sun.enterprise.config.serverbeans

Examples of com.sun.enterprise.config.serverbeans.Domain


    @GET
    @Produces({"text/plain"})
    public String get() {

        Domain entity = RestService.getDomain();

        File loc =
                new File(System.getProperty("user.home") + "/acvs/v3/admin/rest/src/main/java/org/glassfish/admin/rest/resources");
        loc.mkdirs();
        genDir = loc.getAbsolutePath();
View Full Code Here


                    SystemPropertyConstants.INSTANCE_ROOT_PROPERTY) +
                    IAdminConstants.NODEAGENT_DOMAIN_XML_LOCATION;
            ConfigContext configContext =
                ConfigFactory.createConfigContext(domainXMLLocation);
            if (configContext != null) {
                Domain domain = ServerBeansFactory.getDomainBean(configContext);
                if (domain != null) {
                    NodeAgents nodeAgents = domain.getNodeAgents();
                    if (nodeAgents != null) {
                        NodeAgent nodeAgent = nodeAgents.getNodeAgentByName(
                            System.getProperty(
                            SystemPropertyConstants.SERVER_NAME));
                        if (nodeAgent != null) {
View Full Code Here

        if (alertRef != null) {
            try {
                ServerContext srCtx = ApplicationServer.getServerContext();
                ConfigContext cfgCtx = srCtx.getConfigContext();
       
                Domain domain = ServerBeansFactory.getDomainBean(cfgCtx);
                Applications apps = domain.getApplications();
                Mbean definedMBean = apps.getMbeanByName(alertRef);
                ObjectName objName =
                    CustomMBeanRegistrationImpl.getCascadingAwareObjectName(
                                                                  definedMBean);
                Object[] params = new Object[2];
View Full Code Here

    public AutoDeployController createAutoDeployController(ServerContext context) throws AutoDeploymentException {
       
        ConfigContext confContext = context.getConfigContext();
        AutoDeployController autoDeployController = null;            
        String targetConfigurationName = null;
        Domain domain = null;
       
        String autoDeployDir=null ;
        String sourcedir=null;
        String strPollingInterval =null ;
        long pollingInterval;                     
View Full Code Here

    }

    private String getDefaultTarget() throws AutoDeploymentException {
        try{
            ConfigContext confContext = getConfigContext();
            Domain domain = (Domain)confContext.getRootConfigBean();
            Servers svrs = domain.getServers();
            Server[] svrArr = svrs.getServer();
            int size = svrArr.length;
            String targetName = null;
            /*I am putting this logic specific for TP, as its decided to deploy directly
             *to instsnce, and not DAS. It need to be changed to next release
View Full Code Here

    * Get the resources element from domain.xml.
    * return null if not found
    */   
    private Resources getResourcesBean() {
        Resources resourcesBean = null;
        Domain domainBean = null;
        ConfigContext configCtx = this.getConfigContext();
        try {
            domainBean = ServerBeansFactory.getDomainBean(configCtx);
            if(domainBean != null) {
                resourcesBean = domainBean.getResources();
            }
        } catch (ConfigException ex) {}

        return resourcesBean;
    }
View Full Code Here

    }
   
    //Gets the Applications config bean from the application server's configcontext
    private static Applications getApplications() throws ConfigException {
        ConfigContext serverConfigCtx =  ApplicationServer.getServerContext().getConfigContext();
        Domain domain = ((Domain)serverConfigCtx.getRootConfigBean());
        return domain.getApplications();
    }
View Full Code Here

    * Get the applications element from domain.xml.
    * return null if not found
    */    
    private Applications getApplicationsBean() {
        Applications applicationsBean = null;
        Domain domainBean = null;
        ConfigContext configCtx = this.getConfigContext();
        try {
            domainBean = ServerBeansFactory.getDomainBean(configCtx);
            if(domainBean != null) {
                applicationsBean = domainBean.getApplications();
            }
        } catch (ConfigException ex) {}

        return applicationsBean;
    }
View Full Code Here

    * Get the applications element from domain.xml.
    * return null if not found
    */    
    private Applications getApplicationsBeanDynamic() {
        Applications applicationsBean = null;
        Domain domainBean = null;
        ConfigContext configCtx = this.getConfigContextDynamic();
        try {
            domainBean = ServerBeansFactory.getDomainBean(configCtx);
            if(domainBean != null) {
                applicationsBean = domainBean.getApplications();
            }
        } catch (ConfigException ex) {}
        return applicationsBean;
    }   
View Full Code Here

  */
  private void createApplicationRootPath() {
    try {
      ConfigContext context = ConfigFactory.
        createConfigContext(mConfigFilePath);
      Domain domain = ServerBeansFactory.getDomainBean(context);
      mApplicationRootPath = domain.getApplicationRoot();
      if (mApplicationRootPath == null || mApplicationRootPath.length() <=0){
        createDefaultApplicationRootPath();
      }
            mApplicationRootPath = resolvePath(mApplicationRootPath);
    }
View Full Code Here

TOP

Related Classes of com.sun.enterprise.config.serverbeans.Domain

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.