Codota Logo
RouteDefinitionHelper.forceAssignIds
Code IndexAdd Codota to your IDE (free)

How to use
forceAssignIds
method
in
org.apache.camel.model.RouteDefinitionHelper

Best Java code snippets using org.apache.camel.model.RouteDefinitionHelper.forceAssignIds (Showing top 7 results out of 315)

  • Add the Codota plugin to your IDE and get smart completions
private void myMethod () {
ScheduledThreadPoolExecutor s =
  • Codota Iconnew ScheduledThreadPoolExecutor(corePoolSize)
  • Codota IconThreadFactory threadFactory;new ScheduledThreadPoolExecutor(corePoolSize, threadFactory)
  • Codota IconString str;new ScheduledThreadPoolExecutor(1, new ThreadFactoryBuilder().setNameFormat(str).build())
  • Smart code suggestions by Codota
}
origin: org.fusesource/camel-sap

@Override
public Processor wrapProcessorInInterceptors(final CamelContext context, final ProcessorDefinition<?> definition, final Processor target, final Processor nextTarget)
    throws Exception {
  
  RouteDefinitionHelper.forceAssignIds(context, definition);
  return new DelegateAsyncProcessor(target) {
    @Override
    public boolean process(final Exchange exchange, final AsyncCallback callback) {
      LOG.debug("Setting current processor defintion '" + definition.getId() + "'");
      exchange.setProperty(CURRENT_PROCESSOR_DEFINITION, definition);
      return processor.process(exchange, callback);
    }
  };
  
}
origin: jboss-fuse/fabric8

private void forceAutoAssigningIds() {
  for (RouteContext routeContext : routeContexts) {
    CamelContext camelContext = routeContext.getCamelContext();
    NodeIdFactory factory = camelContext.getNodeIdFactory();
    if (factory != null) {
      for (ProcessorDefinition<?> child : processors) {
        // ensure also the children get ids assigned
        RouteDefinitionHelper.forceAssignIds(camelContext, child);
      }
    }
  }
}
origin: org.fusesource.insight/insight-camel

private void forceAutoAssigningIds() {
  for (RouteContext routeContext : routeContexts) {
    CamelContext camelContext = routeContext.getCamelContext();
    NodeIdFactory factory = camelContext.getNodeIdFactory();
    if (factory != null) {
      for (ProcessorDefinition<?> child : processors) {
        // ensure also the children get ids assigned
        RouteDefinitionHelper.forceAssignIds(camelContext, child);
      }
    }
  }
}
origin: org.fusesource.insight/insight-camel

public Processor wrap(RouteContext routeContext, ProcessorDefinition<?> definition, Processor processor) {
  if (processor == null) {
    return null;
  }
  // is this the first output from a route, as we want to know this so we can do special logic in first
  boolean first = false;
  RouteDefinition route = ProcessorDefinitionHelper.getRoute(definition);
  if (route != null) {
    if (routeContext.getCamelContext().getNodeIdFactory() != null) {
      RouteDefinitionHelper.forceAssignIds(routeContext.getCamelContext(), route);
    }
    if (!route.getOutputs().isEmpty()) {
      first = route.getOutputs().get(0) == definition;
    }
  }
  routeContexts.add(routeContext);
  processors.add(definition);
  return new TraceProcessor(queue, processor, definition, route, first, this);
}
origin: org.fusesource.insight/insight-camel

public Processor wrap(RouteContext routeContext, ProcessorDefinition<?> definition, Processor proc) {
  if (proc == null) {
    return null;
  }
  RouteDefinition route = ProcessorDefinitionHelper.getRoute(definition);
  if (route != null) {
    if (routeContext.getCamelContext().getNodeIdFactory() != null) {
      RouteDefinitionHelper.forceAssignIds(routeContext.getCamelContext(), route);
    }
  }
  return new ProfilerProcessor(this, proc, getStats(definition), exchanges);
}
origin: jboss-fuse/fabric8

public Processor wrap(RouteContext routeContext, ProcessorDefinition<?> definition, Processor processor) {
  if (processor == null) {
    return null;
  }
  // is this the first output from a route, as we want to know this so we can do special logic in first
  boolean first = false;
  RouteDefinition route = ProcessorDefinitionHelper.getRoute(definition);
  if (route != null) {
    if (routeContext.getCamelContext().getNodeIdFactory() != null) {
      RouteDefinitionHelper.forceAssignIds(routeContext.getCamelContext(), route);
    }
    if (!route.getOutputs().isEmpty()) {
      first = route.getOutputs().get(0) == definition;
    }
  }
  routeContexts.add(routeContext);
  processors.add(definition);
  TraceProcessor traceProcessor = new TraceProcessor(queue, processor, definition, route, first, this);
  traceProcessor.setCamelContext(routeContext.getCamelContext());
  if (processor instanceof CamelContextAware) {
    ((CamelContextAware) processor).setCamelContext(routeContext.getCamelContext());
  }
  return traceProcessor;
}
origin: jboss-fuse/fabric8

public Processor wrap(RouteContext routeContext, ProcessorDefinition<?> definition, Processor processor) {
  if (processor == null) {
    return null;
  }
  if (processor instanceof FilterProcessor) {
    return processor;
  }
  RouteDefinition route = ProcessorDefinitionHelper.getRoute(definition);
  if (route != null) {
    if (routeContext.getCamelContext().getNodeIdFactory() != null) {
      RouteDefinitionHelper.forceAssignIds(routeContext.getCamelContext(), route);
    }
  }
  ProfilerProcessor profilerProcessor = new ProfilerProcessor(this, processor, getStats(definition), exchanges);
  profilerProcessor.setCamelContext(routeContext.getCamelContext());
  if (processor instanceof CamelContextAware) {
    ((CamelContextAware) processor).setCamelContext(routeContext.getCamelContext());
  }
  return profilerProcessor;
}
org.apache.camel.modelRouteDefinitionHelperforceAssignIds

Popular methods of RouteDefinitionHelper

    Popular in Java

    • Making http requests using okhttp
    • startActivity (Activity)
    • scheduleAtFixedRate (ScheduledExecutorService)
      Creates and executes a periodic action that becomes enabled first after the given initial delay, and
    • setScale (BigDecimal)
      Returns a BigDecimal whose scale is the specified value, and whose value is numerically equal to thi
    • BufferedImage (java.awt.image)
      The BufferedImage subclass describes an java.awt.Image with an accessible buffer of image data. All
    • OutputStream (java.io)
      A writable sink for bytes.Most clients will use output streams that write data to the file system (
    • Scanner (java.util)
      A parser that parses a text string of primitive types and strings with the help of regular expressio
    • Filter (javax.servlet)
      A filter is an object that performs filtering tasks on either the request to a resource (a servlet o
    • Base64 (org.apache.commons.codec.binary)
      Provides Base64 encoding and decoding as defined by RFC 2045.This class implements section 6.8. Base
    • Logger (org.apache.log4j)
      This is the central class in the log4j package. Most logging operations, except configuration, are d
    Codota Logo
    • Products

      Search for Java codeSearch for JavaScript codeEnterprise
    • IDE Plugins

      IntelliJ IDEAWebStormAndroid StudioEclipseVisual Studio CodePyCharmSublime TextPhpStormVimAtomGoLandRubyMineEmacsJupyter
    • Company

      About UsContact UsCareers
    • Resources

      FAQBlogCodota Academy Plugin user guide Terms of usePrivacy policyJava Code IndexJavascript Code Index
    Get Codota for your IDE now