Uploaded image for project: 'REST Client'
  1. REST Client
  2. MGNLRESTCL-65

Declare rest calls using definitions (as opposed to actual implementation)

XMLWordPrintable

    • Icon: Improvement Improvement
    • Resolution: Fixed
    • Icon: Neutral Neutral
    • 2.0
    • None
    • None
    • None
    • Yes
    • Yes
    • Declarative REST 4
    • 8

      Rationale

      We've got some issues with modifying requests that are already declared in the configuration. Modifications to original rest calls lead into undesired behavior. Moreover, with introduction of info.magnolia.rest.client.call.AbstractRestCall and it's subclasses back then, i've added unnecessary abstraction layer above JAX-RS abstraction, that makes working with rest client very cumbersome.

      Proposal

      Declare rest calls using definitions, make them utilize JAX-RS API directly, removing implementations of info.magnolia.rest.client.call.AbstractRestCall. Make JAX-RS API available through the info.magnolia.rest.client.RestClient, the info.magnolia.rest.client.RestClient could be a mere provider of configured rest calls with almost no logic inside.

      Things to consider

      As aichimescu pointed out in the discussion, we should make sure, that it is not possible to deduct passwords for 3rd party APIs rest client is connecting to.

        Acceptance criteria

              aichimescu Andrei Ichimescu
              jsimak Jaroslav Simak
              Votes:
              0 Vote for this issue
              Watchers:
              2 Start watching this issue

                Created:
                Updated:
                Resolved: