apigee/apigeelint

plugin to scan DataCapture for correct use of Source

Closed this issue · 1 comments

Using DataCapture with URIPath, when the policy is attached to the response flow, with no Source element specified, will always result in null variables.
Have a check for that.

Eg

<Capture>
    <DataCollector>dc_path_segment</DataCollector>
    <Collect default="none">
      <Source clearPayload="false">request</Source> <!-- be explicit -->
      <URIPath>
        <Pattern ignoreCase="false">/t1/{$}</Pattern>
        <Pattern ignoreCase="false">/t2/{$}</Pattern>
      </URIPath>
    </Collect>
  </Capture>

This has now been implemented. in #466