Package org.apache.catalina

Examples of org.apache.catalina.LifecycleException


         proxy_.start();

         batchingManager = proxy_.getBatchingManager();
         if(batchingManager == null)
         {
            throw new LifecycleException("JBossCacheManager.start(): Obtain null batchingManager");
         }
        
         initializeUnloadedSessions();
        
         // Setup our SnapshotManager
         initSnapshotManager();
        
         // Add SnapshotValve and, if needed, JvmRouteValve and batch repl valve
         installValves();
        
         // Let subclasses do what they want
         startExtensions();

         log_.debug("start(): DistributedCacheManager started");        
      }
      catch (LifecycleException le)
      {
         throw le;
      }
      catch (Exception e)
      {
         log_.error("Unable to start manager.", e);
         throw new LifecycleException(e);
      }
   }
View Full Code Here


            props.put("db.username", user);
            props.put("db.password", password);
            oauthProvider = (OAuthProvider)constructor.newInstance(props);
            validator = new OAuthValidator(oauthProvider);
        } catch (Exception ex) {
            throw new LifecycleException("In memory OAuth DB can not be created " + ex.getMessage());
        }
    }
View Full Code Here

        // Initialize some naming specific properties
        initNaming();

        // Validate and update our current component state
        if (started)
            throw new LifecycleException
                (sm.getString("embedded.alreadyStarted"));
        lifecycle.fireLifecycleEvent(START_EVENT, null);
        started = true;
        initialized = true;
View Full Code Here

        if( log.isDebugEnabled() )
            log.debug("Stopping embedded server");

        // Validate and update our current component state
        if (!started)
            throw new LifecycleException
                (sm.getString("embedded.notStarted"));
        lifecycle.fireLifecycleEvent(STOP_EVENT, null);
        started = false;

        // Stop our defined Connectors first
View Full Code Here

               
            } catch (IOException e) {
                if (e.getCause() instanceof LifecycleException) {
                    throw (LifecycleException) e.getCause();
                }
                throw new LifecycleException(e);
            } catch (ServletException e) {
                throw new LifecycleException(e);
            }
        } else
            super.start();
    }
View Full Code Here

     * Initialize this connector (create ServerSocket here!)
     */
    public void initialize()
    throws LifecycleException {
        if (initialized)
            throw new LifecycleException("Already initialized");
        this.initialized=true;

        // Get a hold on a server socket
        try {
            ServerSocketFactory fact=this.getFactory();
            int port=this.getPort();
            int accc=this.getAcceptCount();

            if (this.getAddress()==null) {
                this.server=fact.createSocket(port,accc);
            } else {
                InetAddress addr=InetAddress.getByName(this.getAddress());
                this.server=fact.createSocket(port,accc,addr);
            }
        } catch (Exception e) {
            throw new LifecycleException("Error creating server socket ("+
                e.getClass().getName()+")",e);
        }
    }
View Full Code Here

    /**
     * Start accepting connections by this <code>Connector</code>.
     */
    public void start() throws LifecycleException {
        if (!initialized) this.initialize();
        if (started) throw new LifecycleException("Already started");

        // Can't get a hold of a server socket
        if (this.server==null)
            throw new LifecycleException("Server socket not created");

        lifecycle.fireLifecycleEvent(START_EVENT, null);

        this.started = true;

View Full Code Here

    /**
     * Stop accepting connections by this <code>Connector</code>.
     */
    public void stop() throws LifecycleException {
        if (!started) throw new LifecycleException("Not started");

        lifecycle.fireLifecycleEvent(STOP_EVENT, null);

        this.started = false;

View Full Code Here

        }
        if( !initialized ) {
            try {
                init();
            } catch( Exception ex ) {
                throw new LifecycleException("Error initializaing ", ex);
            }
        }
        if(log.isDebugEnabled())
            log.debug("Starting " + ("".equals(getName()) ? "ROOT" : getName()));
View Full Code Here

            log.debug(sm.getString("deltaManager.stopped", getName()));


        // Validate and update our current component state
        if (!started)
            throw new LifecycleException(sm
                    .getString("deltaManager.notStarted"));
        lifecycle.fireLifecycleEvent(STOP_EVENT, null);
        started = false;

        // Expire all active sessions
View Full Code Here

TOP

Related Classes of org.apache.catalina.LifecycleException

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.