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

CamelContext Start command shouldn't start a Suspended context

    XMLWordPrintableJSON

    Details

    • Type: Bug
    • Status: Resolved
    • Priority: Minor
    • Resolution: Fixed
    • Affects Version/s: 2.21.0, 2.22.0
    • Fix Version/s: 2.21.3, 2.22.2, 2.23.0
    • Component/s: karaf
    • Labels:
      None
    • Estimated Complexity:
      Unknown

      Description

      We found this problem in Karaf camel command, but think it should also exist in other camel command usecases.

      In Karaf

      karaf@root()> camel:context-list
       Context        Status              Total #       Failed #     Inflight #   Uptime         
       -------        ------              -------       --------     ----------   ------         
       camel-1        Started                   0              0              0   1.366 seconds  
      karaf@root()> camel:context-suspend camel-1
      karaf@root()> camel:context-list
       Context        Status              Total #       Failed #     Inflight #   Uptime         
       -------        ------              -------       --------     ----------   ------         
       camel-1        Suspended                 0              0              0   7.554 seconds  
      karaf@root()> camel:context-start camel-1 
      karaf@root()> camel:context-list
       Context        Status              Total #       Failed #     Inflight #   Uptime        
       -------        ------              -------       --------     ----------   ------        
       camel-1        Started                   0              0              0   2 minutes
      

      So after start a suspended context, there is still one in context-list. But in JMX tree there are two camel-1 context. This mismatch should be addressed. Either improve ContextList command or if it's a suspended context, throw a RuntimeException and let users resume it other than starting it.

        Attachments

        1. CAMEL-12843.patch
          1 kB
          Freeman Yue Fang

          Activity

            People

            • Assignee:
              ffang Freeman Yue Fang
              Reporter:
              ffang Freeman Yue Fang
            • Votes:
              0 Vote for this issue
              Watchers:
              2 Start watching this issue

              Dates

              • Created:
                Updated:
                Resolved: