Uploaded image for project: 'Common Controller SDK'
  1. Common Controller SDK
  2. CCSDK-3543

Add function for retrieving all resolutions for an artifact

XMLWordPrintable

    • Icon: Story Story
    • Resolution: Done
    • Icon: Medium Medium
    • Jakarta Release
    • None
    • cds

      For blueprint scripts that require access to elements stored in the TEMPLATE_RESOLUTION table of the CDS DB, the blueprint processor offers the function

      AbstractComponentFunction.storedContentFromResolvedArtifactNB(resolutionKey, artifactName),

      which returns exactly one result if the specified resolutionKey and artifactName are available. 

      In some scenarios, it is necessary to find all elements matching certain criteria. We would like to add two functions

      a) AbstractComponentFunction.storedArtifactNamesAndResolutionKeysNB()

      which returns a Map<String, List<String>>, where the keys are the artifactNames stored for the current blueprint and blueprint version, with the list of their resolutionKeys as values.

      b)  AbstractComponentFunction.storedResolutionKeysForArtifactNameNB(artifactName) 

      which returns a list of String of all resolutionKeys stored for the current blueprint, blueprint version and the specified artifactName.

      If no element is found, empty lists are returned (no error thrown).

      In a second step, the retrieved list can be used to fetch the result for selected or all of the contained qualifiers iteratively, using

      AbstractComponentFunction.storedContentFromResolvedArtifactNB.

      Even though this approach requires two steps, we think it is preferable to avoid excessive data transfer.

            achrestin achrestin
            jozsef jozsef
            Votes:
            0 Vote for this issue
            Watchers:
            1 Start watching this issue

              Created:
              Updated:
              Resolved: