Uploaded image for project: 'Camel'
  1. Camel
  2. CAMEL-8077

NullPointerException in getRouteDefinition before context is started

    XMLWordPrintableJSON

Details

    • Bug
    • Status: Resolved
    • Minor
    • Resolution: Fixed
    • 2.14.0
    • 2.14.1, 2.15.0
    • camel-core
    • None
    • Unknown

    Description

      Not sure if this occurs in 2.14.0. Does not occur in 2.13.3.

      I am extending CamelSpringTestSupport with:

      @Override
      public boolean isUseAdviceWith() {
      return true;
      }

      In a @Before method I call context.getRouteDefintion("some.id")

      It throws a NullPointerException:

      org.apache.camel.impl.DefaultCamelContext.getRouteDefinition(DefaultCamelContext.java:1464)

      If I put context.start() at the top of the @Before method, it works.

      Attachments

        Activity

          People

            davsclaus Claus Ibsen
            camelguy Camel Guy
            Votes:
            0 Vote for this issue
            Watchers:
            3 Start watching this issue

            Dates

              Created:
              Updated:
              Resolved: