slice arguments of APIcast's Liquid implementation are interpreted differently than in the documentation

Solution Verified - Updated -

Issue

  • slice arguments in Logging policy are interpreted differently than in the document.

    • If there is one argument, APIcast throws an exception.
    • Second argument is interpreted as an index.

      {{ "Liquid" | slice: 0 }}
      Expected output: L
      Actual: APIcast throws an exception
      
      {{ "Liquid" | slice: 0,1 }}
      Expected: L
      Actual: Li
      
      {{ "Liquid" | slice: -3, 2 }}
      Expected: ui
      Actual: APIcast throws an exception
      

Environment

  • Red Hat 3scale API Management

Subscriber exclusive content

A Red Hat subscription provides unlimited access to our knowledgebase of over 48,000 articles and solutions.

Current Customers and Partners

Log in for full access

Log In