Show TOC

Framework $expandLocate this document in the navigation structure

SAP Gateway always recommends implementing the $expand (therefore using the data provider expand) rather than relying on the framework $expand (generic expand) due to performance reasons.

There are strict restrictions related to the functionality of framework $expand in combination with Last-Modified and cache control:

  1. You are not allowed to set export parameter ES_RESPONSE_CONTEXT-IS_NOT_MODIFIED to ABAP_TRUE.

  2. The application must always return the application data in full.

  3. The value of the if-modified-since will be suppressed (hidden) in the backend system to ensure that the application is forced to return data in full.

The different nodes of the framework $expand are allowed to return a different time stamp in export parameter ES_RESPONSE_CONTEXT-LAST_MODIFIED. In this case the following rules apply:

  1. The youngest LAST_MODIFIED time stamp wins (will be set as response header).

  2. If at least one LAST_MODIFIED time stamp is initial, then the LAST_MODIFIED response header is not set at all.

The different nodes are allowed to return a different MAX_AGE in export parameter ES_RESPONSE_CONTEXT-MAX_AGE. The following rules apply:

  1. The smallest MAX_AGE wins.

  2. If the smallest MAX_AGE is initial, then MAX_AGE is ignored altogether.

The following rule applies for export parameter ES_RESPONSE_CONTEXT-DO_NOT_CACHE_ON_CLIENT: If at least one of the nodes returns DO_NOT_CACHE_ON_CLIENT = ABAP_FALSE, then DO_NOT_CACHE_ON_CLIENT= ABAP_FALSE is valid for the entire header.