Package org.apache.hadoop.gateway.config

Examples of org.apache.hadoop.gateway.config.GatewayConfig


  }

  @Test
  public void testFullConfig() {
    System.setProperty( GatewayConfigImpl.GATEWAY_HOME_VAR, getHomeDirName( "conf-full/conf/gateway-default.xml" ) );
    GatewayConfig config = new GatewayConfigImpl();
    assertThat( config.getGatewayPort(), is( 7777 ) );
    assertNull("ssl.exclude.protocols should be null.", config.getExcludedSSLProtocols());
    //assertThat( config.getShiroConfigFile(), is( "full-shiro.ini") );
  }
View Full Code Here


  }

  @Test
  public void testDemoConfig() {
    System.setProperty( GatewayConfigImpl.GATEWAY_HOME_VAR, getHomeDirName( "conf-demo/conf/gateway-default.xml" ) );
    GatewayConfig config = new GatewayConfigImpl();
    assertThat(config.getGatewayPort(), is( 8888 ) );
    assertTrue( config.getExcludedSSLProtocols().get(0).equals("SSLv3"));
    //assertThat( config.getShiroConfigFile(), is( "full-shiro.ini") );
  }
View Full Code Here

  }

  @Test
  public void testSiteConfig() {
    System.setProperty( GatewayConfigImpl.GATEWAY_HOME_VAR, getHomeDirName( "conf-site/conf/gateway-site.xml" ) );
    GatewayConfig config = new GatewayConfigImpl();
    assertThat( config.getGatewayPort(), is( 5555 ) );
    //assertThat( config.getShiroConfigFile(), is( "site-shiro.ini") );
  }
View Full Code Here

  }

  @Test
  public void testEmptyConfig() {
    System.setProperty( GatewayConfigImpl.GATEWAY_HOME_VAR, getHomeDirName( "conf-empty/conf/empty" ) );
    GatewayConfig config = new GatewayConfigImpl();
    assertThat( config.getGatewayPort(), is( 8888 ) );
    //assertThat( config.getShiroConfigFile(), is( "shiro.ini") );
  }
View Full Code Here

    //assertThat( config.getShiroConfigFile(), is( "shiro.ini") );
  }

  @Test
  public void testDefaultTopologyName() {
    GatewayConfig config = new GatewayConfigImpl();
    assertThat( config.getDefaultTopologyName(), is( "sandbox" ) );
  }
View Full Code Here

    assertThat( config.getDefaultTopologyName(), is( "sandbox" ) );
  }

  @Test
  public void testDefaultAppRedirectPath() {
    GatewayConfig config = new GatewayConfigImpl();
    assertThat( config.getDefaultAppRedirectPath(), is( "/gateway/sandbox" ) );
  }
View Full Code Here

public class DeploymentFactoryFuncTest {

  @Test
  public void testGenericProviderDeploymentContributor() throws ParserConfigurationException, SAXException, IOException, TransformerException {
    GatewayConfig config = new GatewayTestConfig();
    File targetDir = new File( System.getProperty( "user.dir" ), "target" );
    File gatewayDir = new File( targetDir, "gateway-home-" + UUID.randomUUID() );
    gatewayDir.mkdirs();

    ((GatewayTestConfig) config).setGatewayHomeDir( gatewayDir.getAbsolutePath() );

    File deployDir = new File( config.getGatewayDeploymentDir() );
    deployDir.mkdirs();

//    ((GatewayTestConfig) config).setDeploymentDir( "clusters" );

    DefaultGatewayServices srvcs = new DefaultGatewayServices();
View Full Code Here

    assertThat( gateway, hasXPath( "/gateway/resource[1]/filter[1]/param[1]/value", equalTo( "test-param-value" ) ) );
  }

  @Test
  public void testInvalidGenericProviderDeploymentContributor() throws ParserConfigurationException, SAXException, IOException, TransformerException {
    GatewayConfig config = new GatewayTestConfig();
    File targetDir = new File( System.getProperty( "user.dir" ), "target" );
    File gatewayDir = new File( targetDir, "gateway-home-" + UUID.randomUUID() );
    gatewayDir.mkdirs();
    ((GatewayTestConfig) config).setGatewayHomeDir( gatewayDir.getAbsolutePath() );
    File deployDir = new File( config.getGatewayDeploymentDir() );
    deployDir.mkdirs();

    DefaultGatewayServices srvcs = new DefaultGatewayServices();
    Map<String,String> options = new HashMap<String,String>();
    options.put("persist-master", "false");
View Full Code Here

    }
  }

  @Test
  public void testSimpleTopology() throws IOException, SAXException, ParserConfigurationException, URISyntaxException {
    GatewayConfig config = new GatewayTestConfig();
    File targetDir = new File( System.getProperty( "user.dir" ), "target" );
    File gatewayDir = new File( targetDir, "gateway-home-" + UUID.randomUUID() );
    gatewayDir.mkdirs();
    ((GatewayTestConfig) config).setGatewayHomeDir( gatewayDir.getAbsolutePath() );
    File deployDir = new File( config.getGatewayDeploymentDir() );
    deployDir.mkdirs();

    DefaultGatewayServices srvcs = new DefaultGatewayServices();
    Map<String,String> options = new HashMap<String,String>();
    options.put("persist-master", "false");
View Full Code Here

  }


   @Test
   public void testWebXmlGeneration() throws IOException, SAXException, ParserConfigurationException, URISyntaxException {
      GatewayConfig config = new GatewayTestConfig();
      File targetDir = new File(System.getProperty("user.dir"), "target");
      File gatewayDir = new File(targetDir, "gateway-home-" + UUID.randomUUID());
      gatewayDir.mkdirs();
      ((GatewayTestConfig) config).setGatewayHomeDir(gatewayDir.getAbsolutePath());
      File deployDir = new File(config.getGatewayDeploymentDir());
      deployDir.mkdirs();

      DefaultGatewayServices srvcs = new DefaultGatewayServices();
      Map<String, String> options = new HashMap<String, String>();
      options.put("persist-master", "false");
View Full Code Here

TOP

Related Classes of org.apache.hadoop.gateway.config.GatewayConfig

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.