Uploaded image for project: 'Red Hat Fuse'
  1. Red Hat Fuse
  2. ENTESB-6804

Blueprint graceperiod and timeout directives ignored under Fabric

XMLWordPrintable

    • Icon: Bug Bug
    • Resolution: Won't Do
    • Icon: Major Major
    • None
    • jboss-fuse-6.2.1, jboss-fuse-6.3
    • Aries, Fabric8 v1
    • None
    • % %
    • Hide

      Reproducer attached:

      – Build reproducer.
      – Create a fabric with:
      > fabric:create --wait-for-provisioning --zookeeper-password admin
      – Restart container to avoid NPE when calling profile-edit
      – Add profile with:
      > profile-create foo-test
      – Add feature repository to profile with:
      > profile-edit --repository mvn:com.acme.test.foo/repository/1.0.0-SNAPSHOT/xml/features foo-test 1.0
      – Add feature to profile with:
      > profile-edit --feature foo-test foo-test 1.0
      – Create a child container with:
      > container-create-child nodex workerx (assuming nodex is the parent)
      – Add the profile to the child container:
      > container-add-profile workerx foo-test
      – Connect to the container and tail the log
      – Note that container seems to wait almost indefinitely with no indication in the log of errors

      When adding the profile to a normal Karaf container created with:
      > admin:create workerx
      > admin:start workerx
      >admin:connect workerx
      > features:addurl mvn:org.apache.camel.karaf/apache-camel/2.17.0.redhat-630262/xml/features
      > features: addurl mvn:com.acme.test.foo/repository/1.0.0-SNAPSHOT/xml/features
      > features:install camel
      > features:install foo-test

      Provisioning fails immediately with the error message above.

      Show
      Reproducer attached: – Build reproducer. – Create a fabric with: > fabric:create --wait-for-provisioning --zookeeper-password admin – Restart container to avoid NPE when calling profile-edit – Add profile with: > profile-create foo-test – Add feature repository to profile with: > profile-edit --repository mvn:com.acme.test.foo/repository/1.0.0-SNAPSHOT/xml/features foo-test 1.0 – Add feature to profile with: > profile-edit --feature foo-test foo-test 1.0 – Create a child container with: > container-create-child nodex workerx (assuming nodex is the parent) – Add the profile to the child container: > container-add-profile workerx foo-test – Connect to the container and tail the log – Note that container seems to wait almost indefinitely with no indication in the log of errors When adding the profile to a normal Karaf container created with: > admin:create workerx > admin:start workerx >admin:connect workerx > features:addurl mvn:org.apache.camel.karaf/apache-camel/2.17.0.redhat-630262/xml/features > features: addurl mvn:com.acme.test.foo/repository/1.0.0-SNAPSHOT/xml/features > features:install camel > features:install foo-test Provisioning fails immediately with the error message above.

      Bundle Manifest directives blueprint.graceperiod and blueprint.timeout are ignored under Fabric. Given the following manifest:

      Manifest-Version: 1.0
      Bnd-LastModified: 1494705828370
      Build-Jdk: 1.8.0_131
      Built-By: dhawkins
      Bundle-Blueprint: OSGI-INF/blueprint/cbr.xml
      Bundle-ManifestVersion: 2
      Bundle-Name: FOOTEST :: ROUTES
      Bundle-SymbolicName: routes;blueprint.graceperiod:=false;blueprint.tim
       eout:=10000
      Bundle-Version: 1.0.0.SNAPSHOT
      Created-By: Apache Maven Bundle Plugin
      Import-Package: org.osgi.service.blueprint;version="[1.0.0,2.0.0)",org
       .apache.camel.impl;version="[2.17,3)",org.osgi.service.url;version="[
       1.0,2)"
      Tool: Bnd-3.2.0.201605172007
      

      deployment on a non-fabric child container (admin:create) fails immediately with:

      2017-05-13 16:10:26,320 | INFO  | pool-12-thread-1 | BlueprintCamelContext            | 62 - org.apache.camel.camel-core - 2.17.0.redhat-630262 | Apache Camel 2.17.0.redhat-630262 (CamelContext: foo-test-context) is starting
      2017-05-13 16:10:26,322 | INFO  | pool-12-thread-1 | ManagedManagementStrategy        | 62 - org.apache.camel.camel-core - 2.17.0.redhat-630262 | JMX is enabled
      2017-05-13 16:10:26,405 | INFO  | pool-12-thread-1 | DefaultRuntimeEndpointRegistry   | 62 - org.apache.camel.camel-core - 2.17.0.redhat-630262 | Runtime endpoint registry is in extended mode gathering usage statistics of all incoming and outgoing endpoints (cache limit: 1000)
      2017-05-13 16:10:26,478 | INFO  | pool-12-thread-1 | ReferenceRecipe                  | 18 - org.apache.aries.blueprint.core - 1.7.1 | Timeout expired when waiting for mandatory OSGi service reference (&(component=amq)(objectClass=org.apache.camel.spi.ComponentResolver))
      2017-05-13 16:10:26,480 | INFO  | pool-12-thread-1 | BlueprintCamelContext            | 62 - org.apache.camel.camel-core - 2.17.0.redhat-630262 | Apache Camel 2.17.0.redhat-630262 (CamelContext: foo-test-context) is shutting down
      2017-05-13 16:10:26,485 | INFO  | pool-12-thread-1 | BlueprintCamelContext            | 62 - org.apache.camel.camel-core - 2.17.0.redhat-630262 | Apache Camel 2.17.0.redhat-630262 (CamelContext: foo-test-context) uptime 0.164 seconds
      2017-05-13 16:10:26,485 | INFO  | pool-12-thread-1 | BlueprintCamelContext            | 62 - org.apache.camel.camel-core - 2.17.0.redhat-630262 | Apache Camel 2.17.0.redhat-630262 (CamelContext: foo-test-context) is shutdown in 0.004 seconds
      

      When added to a profile and deployed to a container without camel-blueprint deployed, the bundle goes into a grace period with:

      2017-05-13 16:27:20,382 | INFO  | loyer-4-thread-1 | BlueprintContainerImpl           | 18 - org.apache.aries.blueprint.core - 1.7.1 | Bundle routes/1.0.0.SNAPSHOT is waiting for namespace handlers [http://camel.apache.org/schema/blueprint]
      

      and takes a very long time to timeout (over 5 minutes)

            ggrzybek Grzegorz Grzybek
            rhn-support-dhawkins Duane Hawkins
            Votes:
            0 Vote for this issue
            Watchers:
            2 Start watching this issue

              Created:
              Updated:
              Resolved: