Package net.myrrix.online

Examples of net.myrrix.online.ClientThread


 
  private void configureClientThread(ServletContext context,
                                     String bucket,
                                     String instanceID,
                                     MyrrixRecommender recommender) {
    ClientThread theThread;
    try {
      theThread = loadClientThreadClass(context, bucket, instanceID);
    } catch (IOException ioe) {
      throw new IllegalStateException(ioe);
    } catch (ClassNotFoundException cnfe) {
      throw new IllegalStateException(cnfe);
    }
    if (theThread != null) {
      theThread.setRecommender(recommender);       
      clientThread = theThread;
      new Thread(theThread, "MyrrixClientThread").start();
    }
  }
View Full Code Here


    }
   
    log.info("Loading class {} from {}, copied from remote JAR at key {}",
             clientThreadClassName, tempResourceFile, tempResourceFile);
   
    ClientThread clientThreadRunnable =
        ClassUtils.loadFromRemote(clientThreadClassName, ClientThread.class, tempResourceFile.toURI().toURL());

    if (!tempResourceFile.delete()) {
      log.info("Could not delete {}", tempResourceFile);
    }
View Full Code Here

  @Override
  public void contextDestroyed(ServletContextEvent event) {
    log.info("Uninitializing Myrrix in servlet context...");
   
    ClientThread theClientThread = clientThread;
    if (theClientThread != null) {
      try {
        theClientThread.close();
      } catch (IOException e) {
        log.warn("Error while closing client thread", e);
      }
    }
   
View Full Code Here

TOP

Related Classes of net.myrrix.online.ClientThread

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.