Get hands-on experience with 20+ free Google Cloud products and $300 in free credit for new customers.

Response Cache not working when i use uri with query param

I am trying with response cache to cache the entire response from target and it's working only if i cache the full response but my requirement is query param if the query param value change request has to go to target and get the response but it is not going to target .

eg : /crew/roster/v1/SearchMaxPublishDatesByGrade?CrewType=A

the query param value change from CrewType=A to CrewType=C the response  i am getting rom CrewType=A not from CrewType=C.

<ResponseCache name="RC-SearchMaxPublishDatesByGrade">
  <DisplayName>RC-SearchMaxPublishDatesByGrade</DisplayName>
  <CacheResource>SearchMaxPublishDatesByGrade</CacheResource>
  <CacheKey>
    <KeyFragment ref="request.uri" type="string"/>
    <KeyFragment ref="request.queryparam.CrewType"/>
  </CacheKey>
  <Scope>Exclusive</Scope>
  <ExpirySettings>
    <TimeoutInSec>300</TimeoutInSec>
  </ExpirySettings>
</ResponseCache>
0 3 220
3 REPLIES 3
Top Solution Authors