Uploaded image for project: 'Metadata Aggregator'
  1. Metadata Aggregator
  2. MDA-132

generic conditional execution of stages

    XMLWordPrintable

    Details

    • Type: New Feature
    • Status: Closed
    • Priority: Major
    • Resolution: Fixed
    • Affects Version/s: 0.8.0
    • Fix Version/s: 0.9.0
    • Component/s: Pipeline
    • Labels:
      None

      Description

      There are a number of cases where it would be nice to execute or not execute a stage depending on a predicate applied to the collection being processed. For example, one might want to perform assembly of an EntitiesDescriptor if and only if the number of items in the collection was greater than one.

      Obviously one could code this up for each stage that needs it, but it might be better in the long run to implement this as a collectionPredicate property of BaseStage<T>, which is of type Predicate<Collection<Item<T>>>>. This would be initialised to Predicates.alwaysTrue and used to control the execution of doExecute within the execute method. This would provide the ability to conditionally execute essentially any stage depending on properties of the collection.

        Attachments

          Activity

            People

            Assignee:
            ian@iay.org.uk Ian Young
            Reporter:
            ian@iay.org.uk Ian Young
            Watchers:
            1 Start watching this issue

              Dates

              Created:
              Updated:
              Resolved: