Details

    • Type: Sub-task
    • Status: Closed
    • Priority: Major
    • Resolution: Fixed
    • Affects Version/s: 2.15.2
    • Fix Version/s: 2.15.3, 2.16.0
    • Component/s: camel-spring-boot
    • Labels:
      None
    • Estimated Complexity:
      Unknown

      Description

      After some investigation:

      • org.apache.camel.spring.boot.CamelSpringBootApplicationController creates org.apache.camel.main.MainSupport instance
      • MainSupport.waitUntilCompleted() will hang on latch.await()
      • To release this lock MainSupport.completed() has to be called. But this never happens
      • CamelSpringBootApplicationController should implement @PreDestroy callback and call mainSupport.completed()
      • Workaround:
          @Autowired
          private CamelSpringBootApplicationController camelSpringBootApplicationController;
        
          @PreDestroy
          public void preDestroy() throws Exception {
            final Field f = camelSpringBootApplicationController.getClass().getDeclaredField("mainSupport");
            f.setAccessible(true);
            MainSupport mainSupport = (MainSupport) f.get(camelSpringBootApplicationController);
            mainSupport.completed();
          }
        

        Attachments

          Activity

            People

            • Assignee:
              davsclaus Claus Ibsen
              Reporter:
              bsmk Miroslav Matejovsky
            • Votes:
              0 Vote for this issue
              Watchers:
              3 Start watching this issue

              Dates

              • Created:
                Updated:
                Resolved: