Package com.sun.enterprise.config

Examples of com.sun.enterprise.config.ConfigContext


    /**
     *Removes refererences to the specified module.
     *@param module the module whose references are to be removed
     */
    private static void removeReferences(ConfigBean module) throws ConfigException {
        ConfigContext configContext = module.getConfigContext();
        String name = module.getAttributeValue(ServerTags.NAME);
        Server [] servers = ServerHelper.getServersReferencingApplication(configContext, name);
        Cluster [] clusters = ClusterHelper.getClustersReferencingApplication(configContext, name);
        for (Server s : servers) {
            ApplicationRef ref = s.getApplicationRefByRef(name);
View Full Code Here


        // START IASRI 4662745

        ServerContext sCtx = ApplicationServer.getServerContext();
        // running on the server side
        if (sCtx != null) {
            ConfigContext ctx = sCtx.getConfigContext();
            TransactionService txnService = null;
            try {
                txnService = ServerBeansFactory.getTransactionServiceBean(ctx);
                transactionTimeout = Integer.parseInt(txnService.getTimeoutInSeconds());
                ElementProperty[] eprops = txnService.getElementProperty();
View Full Code Here

    //public boolean check(String name, Object value, ConfigContext context, String choice) {
    public boolean check(ConfigContextEvent ccce) {
        String name = ccce.getName();
        Object value = ccce.getObject();
        ConfigContext context = ccce.getConfigContext();
        String choice = ccce.getChoice();
        String beanName = ccce.getBeanName();
       
        if(name == null && beanName == null)
                return true;
View Full Code Here

     */
    private static String getLogFileName() {
        if (logFileName == null) {
            ServerContext sc = ApplicationServer.getServerContext();
            if (sc != null) {
                ConfigContext ctx = sc.getConfigContext();
                LogService ls = null;
                try {
                    ls = ServerBeansFactory.getConfigBean(ctx).getLogService();
                } catch (ConfigException ce) {
                    // Ignore this exception, intent is to use default file
View Full Code Here

    }
   
    // check method called from the admin GUI and iasadmin
    public Result check(ConfigContextEvent ccce) {
                Object value = ccce.getObject();
                ConfigContext context = ccce.getConfigContext();
                Result result = new Result();
                result.passed("Passed ** ");
                String beanName = ccce.getBeanName();
                if(beanName!=null) {
                    String name = ccce.getName();
View Full Code Here

        AdminEvent event = null;
        EventBuilder builder = new EventBuilder();

        //XXX Can we put the following 4 lines be done in the EventBuilder?
        EventStack stack = EventContext.getEventStackFromThreadLocal();
        ConfigContext ctx = stack.getConfigContext();
        stack.setTarget(targetName);
        stack.setConfigChangeList(ctx.getConfigChangeList());

        try{
            if (eventType == BaseDeployEvent.APPLICATION_DEPLOYED)
            {
                event = builder.createApplicationDeployEvent(
View Full Code Here

        AdminEvent event = null;
        EventBuilder builder = new EventBuilder();

        //XXX Can we put the following 4 lines be done in the EventBuilder?
        EventStack stack = EventContext.getEventStackFromThreadLocal();
        ConfigContext ctx = stack.getConfigContext();
        stack.setTarget(targetName);
        stack.setConfigChangeList(ctx.getConfigChangeList());

        try{
            if (eventType == BaseDeployEvent.APPLICATION_DEPLOYED)
            {
                event = builder.createApplicationDeployEvent(
View Full Code Here

        if (initialized) return;
        initialized = true;

        try {
            ConfigContext ctx =
                ConfigFactory.createConfigContext
                (configFile, true, false, false,
                 com.sun.enterprise.config.clientbeans.ClientContainer.class,
     new com.sun.enterprise.config.clientbeans.ClientBeansResolver());
            final ClientContainer cc  =
View Full Code Here

            _logger = Logger.getLogger("global");
        }
    }

    public void sendNotification() {
        ConfigContext context = _adminContext.getAdminConfigContext();
        String instanceName = _adminContext.getServerName();
        AdminEventCache cache =
                AdminEventCache.getInstance(instanceName);
        cache.setAdminConfigContext(context);
        ArrayList changeList = context.getConfigChangeList();
        context.resetConfigChangeList();
        ArrayList eventList = null;
        if (changeList.size() <= 0) {
            eventList = new ArrayList();
            // Return, no changes to process
            //return;
View Full Code Here

    }

    // check method called from the admin GUI and iasadmin
    public Result check(ConfigContextEvent ccce) {
        Object value = ccce.getObject();
        ConfigContext context = ccce.getConfigContext();
        Result result = new Result();
        result.passed("Passed ** ");
        String beanName = ccce.getBeanName();
        if(beanName!=null) {
            String name = ccce.getName();
View Full Code Here

TOP

Related Classes of com.sun.enterprise.config.ConfigContext

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.