APIGEE-API-ENGINEER practice question 20 of 25
You need to log certain data to a custom logging service while processing the response You want to avoid processing delays due to logging during the logic flow What should you do?
Full set: 126 questionsThe PostClientFlow is a unique processing stage in an Apigee proxy that executes after the response has been sent to the requesting client. Placing the Message Logging policy in this flow ensures that the logging operation is decoupled from the client-facing request-response transaction. This "fire-and-forget" mechanism is the standard and most efficient method for performing non-critical tasks, such as logging, without adding any latency to the client's perceived response time.
A. A Node.js target replaces the primary backend service; it is part of the critical path and not suitable for an auxiliary, non-blocking logging task.
C. While technically possible, implementing a Java Callout with a custom worker thread is overly complex and not the idiomatic Apigee solution for this common requirement.
D. A Service Callout, even when asynchronous, still executes within the main proxy flow before the response is sent, potentially consuming resources and adding complexity to the primary logic. ---
1. Google Cloud Apigee Documentation
"Message Logging policy": "This policy is particularly useful in the PostClientFlow
which is executed after the response has been sent to the requesting client. By using the policy in this flow
you can be sure that the logging will not slow down the response time for the client."
Source: https://cloud.google.com/apigee/docs/api-platform/reference/policies/message-logging-policy
Section: "When to use this policy".
2. Google Cloud Apigee Documentation
"Configuring flows": "The PostClientFlow is the only flow that is executed after the proxy sends the response back to the client app. This flow is ideal for logging and for collecting analytics data... because this logic will not add latency to the response time seen by the client app."
Source: https://cloud.google.com/apigee/docs/api-platform/fundamentals/flow-variables-policies
Section: "PostClientFlow".
3. Google Cloud Apigee Documentation
"Adding a Node.js target": "When you add a Node.js target to a proxy
the Node.js application runs instead of the TargetEndpoint's element." This confirms that a Node.js target is a replacement for the backend
not a side process for logging.
Source: https://cloud.google.com/apigee/docs/api-platform/develop/adding-nodejs-api-proxy
Section: "Adding a Node.js target".
Keep practicing
Take the free APIGEE-API-ENGINEER practice test
Ten exam-style questions with answers and explanations, plus the exam facts and study guides.
More questions
Other APIGEE-API-ENGINEER practice questions
- Question 1In your last release, there were unexpected errors uncovered by users within the first 24…
- Question 2Your company runs their internal services across two datacenters in a hot-warm configurat…
- Question 3Which features are supported in the OAulhV2 policy'? Select all that are correct. Choose …
- Question 4Which is a benefit of three-legged OAuth (authonzation_code grant)'?
- Question 5Which Apigee product feature can be used to host and version your API documentation'?
- Question 6As an API Engineer your team would like to make sure you are simulating a user experience…
