Tabnine Logo
IncorrectNumberOfServersConfiguredException
Code IndexAdd Tabnine to your IDE (free)

How to use
IncorrectNumberOfServersConfiguredException
in
com.oath.micro.server

Best Java code snippets using com.oath.micro.server.IncorrectNumberOfServersConfiguredException (Showing top 2 results out of 315)

origin: aol/micro-server

private ServerApplication createServer(Module module) {
  List<ServerApplicationFactory> applications = ReactiveSeq.fromStream(PluginLoader.INSTANCE.plugins.get()
                                                   .stream())
                               .filter(m -> m.serverApplicationFactory() != null)
                               .map(Plugin::serverApplicationFactory)
                               .flatMap(Streams::optionalToStream)
                               .toList();
  if (applications.size() > 1) {
    logger.error("ERROR!  Multiple server application factories found : The solution is remove one these plugins from your classpath ",
           applications);
    System.err.println("ERROR!  Multiple server application factories found : The solution is remove one these plugins from your classpath "
        + applications);
    throw new IncorrectNumberOfServersConfiguredException(
                               "Multiple server application factories found : The solution is remove one these plugins from your classpath "
                                   + applications);
  } else if (applications.size() == 0) {
    logger.error("ERROR!  No server application factories found. If you using micro-spring-boot don't call MicroserverApp.start() method. A possible solution is add one of micro-grizzly or micro-tomcat to the classpath.");
    System.err.println("ERROR!  No server application factories found. If you using micro-spring-boot don't call MicroserverApp.start() method. A possible solution is add one of micro-grizzly or micro-tomcat to the classpath.");
    throw new IncorrectNumberOfServersConfiguredException(
                               "No server application factories found. If you using micro-spring-boot don't call MicroserverApp.start() method. A possible solution is add one of micro-grizzly or micro-tomcat to the classpath. ");
  }
  ServerApplication app = applications.get(0)
                    .createApp(module, springContext);        
  return app;
}    
origin: com.oath.microservices/micro-core

private ServerApplication createServer(Module module) {
  List<ServerApplicationFactory> applications = ReactiveSeq.fromStream(PluginLoader.INSTANCE.plugins.get()
                                                   .stream())
                               .filter(m -> m.serverApplicationFactory() != null)
                               .map(Plugin::serverApplicationFactory)
                               .flatMap(Streams::optionalToStream)
                               .toList();
  if (applications.size() > 1) {
    logger.error("ERROR!  Multiple server application factories found : The solution is remove one these plugins from your classpath ",
           applications);
    System.err.println("ERROR!  Multiple server application factories found : The solution is remove one these plugins from your classpath "
        + applications);
    throw new IncorrectNumberOfServersConfiguredException(
                               "Multiple server application factories found : The solution is remove one these plugins from your classpath "
                                   + applications);
  } else if (applications.size() == 0) {
    logger.error("ERROR!  No server application factories found. If you using micro-spring-boot don't call MicroserverApp.start() method. A possible solution is add one of micro-grizzly or micro-tomcat to the classpath.");
    System.err.println("ERROR!  No server application factories found. If you using micro-spring-boot don't call MicroserverApp.start() method. A possible solution is add one of micro-grizzly or micro-tomcat to the classpath.");
    throw new IncorrectNumberOfServersConfiguredException(
                               "No server application factories found. If you using micro-spring-boot don't call MicroserverApp.start() method. A possible solution is add one of micro-grizzly or micro-tomcat to the classpath. ");
  }
  ServerApplication app = applications.get(0)
                    .createApp(module, springContext);        
  return app;
}    
com.oath.micro.serverIncorrectNumberOfServersConfiguredException

Most used methods

  • <init>

Popular in Java

  • Making http requests using okhttp
  • compareTo (BigDecimal)
  • scheduleAtFixedRate (Timer)
  • getOriginalFilename (MultipartFile)
    Return the original filename in the client's filesystem.This may contain path information depending
  • Enumeration (java.util)
    A legacy iteration interface.New code should use Iterator instead. Iterator replaces the enumeration
  • Iterator (java.util)
    An iterator over a sequence of objects, such as a collection.If a collection has been changed since
  • TimerTask (java.util)
    The TimerTask class represents a task to run at a specified time. The task may be run once or repeat
  • Vector (java.util)
    Vector is an implementation of List, backed by an array and synchronized. All optional operations in
  • ReentrantLock (java.util.concurrent.locks)
    A reentrant mutual exclusion Lock with the same basic behavior and semantics as the implicit monitor
  • Filter (javax.servlet)
    A filter is an object that performs filtering tasks on either the request to a resource (a servlet o
  • Best plugins for Eclipse
Tabnine Logo
  • Products

    Search for Java codeSearch for JavaScript code
  • IDE Plugins

    IntelliJ IDEAWebStormVisual StudioAndroid StudioEclipseVisual Studio CodePyCharmSublime TextPhpStormVimGoLandRubyMineEmacsJupyter NotebookJupyter LabRiderDataGripAppCode
  • Company

    About UsContact UsCareers
  • Resources

    FAQBlogTabnine AcademyTerms of usePrivacy policyJava Code IndexJavascript Code Index
Get Tabnine for your IDE now