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

Simplify ServiceSupport and introduce ServiceWithStatus interface to remove tangle between util and support

    XMLWordPrintableJSON

Details

    • Improvement
    • Status: Resolved
    • Major
    • Resolution: Fixed
    • 2.8.0
    • 2.9.0
    • camel-core
    • None
    • Unknown

    Description

      Currently ServiceSupport and ServiceHelper form a dependency cycle. ServiceSupport calls ServiceHelper to start and stop services and ServiceSupport operate on ServiceSupport classes.
      To solve that I introduce an Interface ServiceWithSupport (open for a better naming). This interface extends Service and has all relevant methods from ServiceSupport. So ServiceHelper can operate on ServiceWithStatus and the tangle goes away.

      Addtionally I split up ServiceSupport into ServiceSupport which has no children and ChildServiceSupport which has. This is because we seem to have only two classes that actually use the children functionality. The rest of the classes that extend ServiceSupport have no children. So having them all extend the old ServiceSupport introduces a lot of unneeded complexity.

      The change should be fairly compatible. The only possible problem are third party components that use children. As we only had two such components in camel the chance that something breaks is fairly low.

      Attachments

        Activity

          People

            cschneider Christian Schneider
            cschneider Christian Schneider
            Votes:
            0 Vote for this issue
            Watchers:
            0 Start watching this issue

            Dates

              Created:
              Updated:
              Resolved: