Package org.tamacat.httpd.config

Examples of org.tamacat.httpd.config.ServiceConfig


    HostRequestHandlerResolver hostResolver = new HostRequestHandlerResolver();
    HostServiceConfig hostConfig = new ServiceConfigParser(serverConfig).getConfig();
    for (String host : hostConfig.getHosts()) {
      HttpRequestHandlerRegistry registry = new HttpRequestHandlerRegistry();
      ServiceConfig serviceConfig = hostConfig.getServiceConfig(host);
      for (ServiceUrl serviceUrl : serviceConfig.getServiceUrlList()) {
        HttpHandler handler = factory.getHttpHandler(serviceUrl);
        if (handler != null) {
          LOG.info(serviceUrl.getPath() + " - " + handler.getClass().getName());
          registry.register(serviceUrl.getPath() + "*", handler);
        } else {
View Full Code Here


  ServerConfig config;
 
  @Before
  public void setUp() throws Exception {
    config = new ServerConfig();
    ServiceConfig serviceConfig  = new ServiceConfig();
   
    ServiceUrl serviceUrl = new ServiceUrl(config);
    serviceUrl.setHandlerName("ReverseHandler");
    serviceUrl.setPath("/test2/");
    serviceUrl.setType(ServiceType.REVERSE);
   
    reverseUrl = new DefaultReverseUrl(serviceUrl);
    reverseUrl.setReverse(new URL("http://localhost:8080/test/"));
    serviceUrl.setReverseUrl(reverseUrl);
    serviceConfig.addServiceUrl(serviceUrl);
   
    url = serviceConfig.getServiceUrl("/test2/");
    reverseUrl = url.getReverseUrl();
  }
View Full Code Here

  ServerConfig config;
 
  @Before
  public void setUp() throws Exception {
    config = new ServerConfig();
    ServiceConfig serviceConfig = new ServiceConfig();
   
    ServiceUrl serviceUrl = new ServiceUrl(config);
    serviceUrl.setHandlerName("ReverseHandler");
    serviceUrl.setPath("/test2/");
    serviceUrl.setType(ServiceType.REVERSE);
   
    reverseUrl = new DefaultReverseUrl(serviceUrl);
    reverseUrl.setReverse(new URL("http://localhost:8080/test/"));
    serviceUrl.setReverseUrl(reverseUrl);
    serviceConfig.addServiceUrl(serviceUrl);

    serviceUrl = serviceConfig.getServiceUrl("/test2/");
    reverseUrl = serviceUrl.getReverseUrl();
  }
View Full Code Here

  ServiceUrl serviceUrl;
 
  @Before
  public void setUp() throws Exception {
    serverConfig = new ServerConfig();
    serviceConfig = new ServiceConfig();
    serviceUrl = new ServiceUrl(serverConfig);
    serviceUrl.setHandlerName("DocsHandler");
    serviceUrl.setPath("/docs/");
    serviceUrl.setType(ServiceType.NORMAL);
    serviceConfig.addServiceUrl(serviceUrl);
View Full Code Here

TOP

Related Classes of org.tamacat.httpd.config.ServiceConfig

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.