Examples of addRules()


Examples of com.axemblr.provisionr.api.network.NetworkBuilder.addRules()

    @VisibleForTesting
    Network apply(Network network) {
        NetworkBuilder result = network.toBuilder();
        for (int port : ports) {
            result.addRules(Rule.builder().anySource().tcp().port(port).createRule());
        }
        return result.createNetwork();
    }

    @XmlAttribute(name = "id")
View Full Code Here

Examples of com.puppetlabs.xtext.dommodel.formatter.css.DomCSS.addRules()

    final StyleSet oneSpaceOneOptionalLine = StyleSet.withImmutableStyles(//
      styles.oneSpace(), styles.lineBreaks(0, 0, 1, true, true));

    DomCSS css = super.get();

    css.addRules(
      // RESOURCE
      // Resource expression with single titled body, should allow body to have title on same line
      // so, no line break, but one space here
      Select.and(inASingleBodiesResourceWithTitle, Select.whitespaceAfter(resourceLeftCurlyBracket)) //
      .withStyles( //
View Full Code Here

Examples of io.fabric8.service.jclouds.firewall.FirewallManager.addRules()

            if (firewallManager.isSupported()) {
                listener.onStateChange("Configuring firewall.");
                String source = getOriginatingIp();

                Rule httpRule = Rule.create().source("0.0.0.0/0").destination(nodeMetadata).port(8181);
                firewallManager.addRules(httpRule);

                if (source != null) {
                    Rule jmxRule = Rule.create().source(source).destination(nodeMetadata).ports(44444, 1099);
                    Rule sshRule = Rule.create().source(source).destination(nodeMetadata).port(8101);
                    Rule zookeeperRule = Rule.create().source(source).destination(nodeMetadata).port(2181);
View Full Code Here

Examples of io.fabric8.service.jclouds.firewall.FirewallManager.addRules()

                if (source != null) {
                    Rule jmxRule = Rule.create().source(source).destination(nodeMetadata).ports(44444, 1099);
                    Rule sshRule = Rule.create().source(source).destination(nodeMetadata).port(8101);
                    Rule zookeeperRule = Rule.create().source(source).destination(nodeMetadata).port(2181);
                    firewallManager.addRules(jmxRule, sshRule, zookeeperRule);
                }
                //We do add the target node public address to the firewall rules, as a way to make things easier in cases
                //where firewall configuration is shared among nodes of the same groups, e.g. EC2.
                if (!Strings.isNullOrEmpty(publicAddress)) {
                    Rule zookeeperFromTargetRule = Rule.create().source(publicAddress + "/32").destination(nodeMetadata).port(2181);
View Full Code Here

Examples of org.apache.hadoop.gateway.filter.rewrite.api.UrlRewriteRulesDescriptor.addRules()

  }

  private void contributeRewriteRules( DeploymentContext context, Service service ) throws URISyntaxException, IOException {
    UrlRewriteRulesDescriptor hbaseRules = loadRulesFromTemplate();
    UrlRewriteRulesDescriptor clusterRules = context.getDescriptor( "rewrite" );
    clusterRules.addRules( hbaseRules );
  }

  private void contributeResources( DeploymentContext context, Service service ) throws URISyntaxException {
    List<FilterParamDescriptor> params;
View Full Code Here

Examples of org.apache.hadoop.gateway.filter.rewrite.api.UrlRewriteRulesDescriptor.addRules()

  }

  private void contributeRewriteRules( DeploymentContext context, Service service ) throws IOException {
    UrlRewriteRulesDescriptor hbaseRules = loadRulesFromTemplate();
    UrlRewriteRulesDescriptor clusterRules = context.getDescriptor( "rewrite" );
    clusterRules.addRules( hbaseRules );
  }

  private UrlRewriteRulesDescriptor loadRulesFromTemplate() throws IOException {
    InputStream stream = this.getClass().getClassLoader().getResourceAsStream( RULES_RESOURCE );
    Reader reader = new InputStreamReader( stream );
View Full Code Here

Examples of org.apache.hadoop.gateway.filter.rewrite.api.UrlRewriteRulesDescriptor.addRules()

  }

  private void contributeRewriteRules( DeploymentContext context, Service service ) throws URISyntaxException, IOException {
    UrlRewriteRulesDescriptor serviceRules = loadRulesFromClassPath();
    UrlRewriteRulesDescriptor clusterRules = context.getDescriptor( "rewrite" );
    clusterRules.addRules( serviceRules );
  }

  public void contributeNameNodeResource( DeploymentContext context, Service service ) throws URISyntaxException {
    List<FilterParamDescriptor> params;
    ResourceDescriptor rootResource = context.getGatewayDescriptor().addResource();
View Full Code Here

Examples of org.apache.hadoop.gateway.filter.rewrite.api.UrlRewriteRulesDescriptor.addRules()

  }

  private void contributeRewriteRules( DeploymentContext context, Service service ) throws URISyntaxException, IOException {
    UrlRewriteRulesDescriptor oozieRules = loadRulesFromTemplate();
    UrlRewriteRulesDescriptor clusterRules = context.getDescriptor( "rewrite" );
    clusterRules.addRules( oozieRules );
  }

  public void contributeResources( DeploymentContext context, Service service ) throws URISyntaxException {
    ResourceDescriptor rootResource = context.getGatewayDescriptor().addResource();
    rootResource.role( service.getRole() );
View Full Code Here

Examples of org.apache.hadoop.gateway.filter.rewrite.api.UrlRewriteRulesDescriptor.addRules()

  private void contributeRewriteRules(DeploymentContext context, Service service)
      throws URISyntaxException, IOException {
    UrlRewriteRulesDescriptor serviceRules = loadRulesFromClassPath();
    UrlRewriteRulesDescriptor clusterRules = context.getDescriptor( "rewrite" );
    clusterRules.addRules( serviceRules );
  }

  private UrlRewriteRulesDescriptor loadRulesFromClassPath() throws IOException {
    InputStream stream = this.getClass().getClassLoader()
        .getResourceAsStream( RULES_RESOURCE );
View Full Code Here

Examples of org.apache.hadoop.gateway.filter.rewrite.api.UrlRewriteRulesDescriptor.addRules()

  }

  private void contributeRewriteRules( DeploymentContext context, Service service ) throws URISyntaxException, IOException {
    UrlRewriteRulesDescriptor serviceRules = loadRulesFromClassPath();
    UrlRewriteRulesDescriptor clusterRules = context.getDescriptor( "rewrite" );
    clusterRules.addRules( serviceRules );
  }

  public void contributeNameNodeResource( DeploymentContext context, Service service ) throws URISyntaxException {
    List<FilterParamDescriptor> params;
    ResourceDescriptor rootResource = context.getGatewayDescriptor().addResource();
View Full Code Here
TOP
Copyright © 2018 www.massapi.com. 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.