HOTSPOT
You updating an existing multitenant ASP.NET MVC application for medical clinics. The application
aggressively uses output caching to improve performance by caching content for 36 hours. The application
uses a query string parameter named “clinicID” that contains the clinic that the user is currently viewing.
Users report that they are occasionally seeing data for the wrong clinic. Users also report that the application
seems to take a long time to return data for a specific clinic even if they have viewed it recently.
You need to configure web.config to resolve the reported problems.
You have the following markup:
Which markup segments should you include in Target 1, Target 2 and Target 3 to complete the markup? (To
answer, select the correct markup segment from each drop-down list in the answer area.)
Hot Area:
Explanation:
Target 1: noStore=”false”
The page that has the OutputCacheProfile.NoStore property set to true issues a response specifying in its
header to prevent secondary storage of sensitive information.
Target 2: VaryByParam =”clinicID”
The VaryByParam is a semicolon-delimited set of parameters used to vary the cached output. It allows varying
the cached output by GET query string or form POST parameters. For instance, you can vary the user-control
output to the cache by specifying the user-control name along with either a query string or a form POST
parameter.
Incorrect: Not varyByControl=”ClinicID”
The VaryByControl is a semicolon-delimited set of IDs of controls to be cached.
Target 3: duration=129600″
The Duration represents the time in seconds that the page or user control is cached. Setting this property
establishes an expiration policy for HTTP responses from the page or control to which it applies and will
automatically cause the caching of their output.
129600 seconds is 36 hours (60*60*36).
https://msdn.microsoft.com/en-us/library/system.web.configuration.outputcacheprofile
(v=vs.110).aspx