Question 370
An embeddings pipeline stores 1536-element vectors, but the Cosmos container vector policy declares only 768 dimensions. A new Cosmos DB container is being provisioned for cosine-based embeddings, but its proposed vector policy uses a different distance metric. What is the most appropriate plan for this situation?
- Plan a new supported vector policy and migration rather than assuming in-place dimension edits; configure cosine distance on the vector embedding path before creating the container.
- Create a vector policy whose declared dimension matches the actual embedding model output; configure cosine distance on the vector embedding path before creating the container.
- Create a vector policy whose declared dimension matches the actual embedding model output; plan a new supported vector policy and migration rather than assuming in-place dimension edits.
- Configure cosine distance on the vector embedding path before creating the container; do not create a vector policy whose declared dimension matches the actual embedding model output.
Explanation
Correct Answer
B:The stored embedding shape must match its declared vector path schema for reliable vector operations. search distance semantics must match the embedding model and intended nearest-neighbor ranking.
Incorrect Answers
A:Existing vector policy settings are constrained and require an explicit change path; requirement 1 requires: creating a vector policy whose declared dimension matches the actual embedding model output.
C:Configure cosine distance on the vector embedding path before creating the container.
D:Search distance semantics must match the embedding model and intended nearest-neighbor ranking; requirement 1 requires: creating a vector policy whose declared dimension matches the actual embedding model output.
Question 371
A distributed trace shows one long root span but hides which PostgreSQL query accounts for most of its duration. An exception in an embedding worker is logged without attaching it to the request span that failed. Which course of action addresses the stated issues?
- Add a database dependency span around the query with suitable attributes; remove sensitive attributes and use low-cardinality, nonsecret diagnostics.
- Add a database dependency span around the query with suitable attributes; Record the exception and error status on the active OpenTelemetry span.
- Remove sensitive attributes and use low-cardinality, nonsecret diagnostics; Record the exception and error status on the active OpenTelemetry span.
- Record the exception and error status on the active OpenTelemetry span; do not add a database dependency span around the query with suitable attributes.
Explanation
Correct Answer
B:Child spans expose individual dependency timing within an end-to-end request. span events and status connect a failure to the exact traced operation.
Incorrect Answers
A:Record the exception and error status on the active OpenTelemetry span.
C:Trace metadata should support debugging without storing private identifiers or exploding cardinality; Requirement 1 requires: add a database dependency span around the query with suitable attributes.
D:Span events and status connect a failure to the exact traced operation; Requirement 1 requires: add a database dependency span around the query with suitable attributes.
Question 372
A chatbot caches tenant-specific user preferences without an expiry, returning obsolete data weeks after a preference change. Multiple customer tenants use identical Redis cache keys and receive each other's cached responses. Which response best addresses these needs?
- Include an authorized tenant identifier in cache-key construction and enforce isolation; do not Set an appropriate Redis key TTL and explicit invalidation on updates.
- Apply suitable expiration policies and monitor cache memory consumption; Include an authorized tenant identifier in cache-key construction and enforce isolation.
- Set an appropriate Redis key TTL and explicit invalidation on updates; Include an authorized tenant identifier in cache-key construction and enforce isolation.
- Set an appropriate Redis key TTL and explicit invalidation on updates; apply suitable expiration policies and monitor cache memory consumption.
Explanation
Correct Answer
C:Bounded cache lifetime and invalidation limit stale reads after source data changes. key namespacing prevents collisions between distinct customer data scopes.
Incorrect Answers
A:Key namespacing prevents collisions between distinct customer data scopes; Requirement 1 requires: set an appropriate Redis key TTL and explicit invalidation on updates.
B:Expiring ephemeral data controls memory growth without treating the cache as a permanent database; Requirement 1 requires: set an appropriate Redis key TTL and explicit invalidation on updates.
D:Include an authorized tenant identifier in cache-key construction and enforce isolation.
Question 373
A legal search app uses only vector similarity and returns documents marked confidential to an unauthorized department. A user requests only Spanish knowledge articles, but retrieval selects highly similar English chunks because language is not filtered. What is the most appropriate plan for this situation?
- Combine authorized department metadata filters with vector retrieval and application permission checks; apply a language metadata predicate alongside the vector-distance ranking.
- Apply a language metadata predicate alongside the vector-distance ranking; do not Combine authorized department metadata filters with vector retrieval and application permission checks.
- Combine authorized department metadata filters with vector retrieval and application permission checks; Store and select document and chunk provenance columns with retrieval results.
- Store and select document and chunk provenance columns with retrieval results; apply a language metadata predicate alongside the vector-distance ranking.
Explanation
Correct Answer
A:Similarity scores do not enforce document classification or tenant access. a metadata filter enforces the requested language constraint independent of semantic proximity.
Incorrect Answers
B:A metadata filter enforces the requested language constraint independent of semantic proximity; Requirement 1 requires: combine authorized department metadata filters with vector retrieval and application permission checks.
C:Apply a language metadata predicate alongside the vector-distance ranking.
D:Source identifiers permit traceable citations and controlled post-retrieval verification; Requirement 1 requires: combine authorized department metadata filters with vector retrieval and application permission checks.
Question 374
An HTTP-based Container App experiences overload, but its scale rule observes queue messages that the app never consumes. A Container App's replicas remain at their minimum during a compute-heavy operation even when CPU usage is sustained. Which course of action addresses the stated issues?
- Configure an appropriate supported CPU-based scale rule and replica limits; do not replace the irrelevant rule with a properly configured HTTP concurrency scaling rule.
- Maintain a nonzero minimum replica count for latency-sensitive serving traffic; configure an appropriate supported CPU-based scale rule and replica limits.
- Replace the irrelevant rule with a properly configured HTTP concurrency scaling rule; Maintain a nonzero minimum replica count for latency-sensitive serving traffic.
- Replace the irrelevant rule with a properly configured HTTP concurrency scaling rule; configure an appropriate supported CPU-based scale rule and replica limits.
Explanation
Correct Answer
D:Scaling input must represent actual incoming work for the service. a compute signal can scale replicas when request concurrency is not a reliable workload proxy.
Incorrect Answers
A:A compute signal can scale replicas when request concurrency is not a reliable workload proxy; Requirement 1 requires: replace the irrelevant rule with a properly configured HTTP concurrency scaling rule.
B:Keeping warm capacity trades idle resource cost for reduced cold-start delay; Requirement 1 requires: replace the irrelevant rule with a properly configured HTTP concurrency scaling rule.
C:Configure an appropriate supported CPU-based scale rule and replica limits.
Question 375
Messages for a single customer must be processed in their original order despite multiple concurrent workers. A Service Bus queue is already session-enabled and may not be reconfigured, but publishers omit the required SessionId and their messages are rejected. Which response best addresses these needs?
- Enable Service Bus sessions and use a stable customer-specific SessionId; Set the appropriate SessionId on every message sent to that entity.
- Set the appropriate SessionId on every message sent to that entity; do not enable Service Bus sessions and use a stable customer-specific SessionId.
- Keep per-session processing state isolated and bound to its session identifier; Set the appropriate SessionId on every message sent to that entity.
- Enable Service Bus sessions and use a stable customer-specific SessionId; keep per-session processing state isolated and bound to its session identifier.
Explanation
Correct Answer
A:Sessions group related messages for ordered, exclusive session processing. session-enabled entities require publishers to identify the intended session.
Incorrect Answers
B:Session-enabled entities require publishers to identify the intended session; Requirement 1 requires: enable Service Bus sessions and use a stable customer-specific SessionId.
C:Session isolation preserves the correct ordering and context of each logical stream; Requirement 1 requires: enable Service Bus sessions and use a stable customer-specific SessionId.
D:Set the appropriate SessionId on every message sent to that entity.
Question 376
An Event Grid webhook subscription stays pending because a custom HTTPS endpoint never acknowledges the validation handshake. An Event Grid webhook publicly accepts arbitrary callers and executes expensive AI tasks from unauthenticated POST requests. What is the most appropriate plan for this situation?
- Acknowledge promptly and hand off long-running work to a durable queue or job; require supported event delivery authentication and validate request origin or tokens.
- Implement the required Event Grid subscription validation response or supported validation flow; Acknowledge promptly and hand off long-running work to a durable queue or job.
- Require supported event delivery authentication and validate request origin or tokens; do not implement the required Event Grid subscription validation response or supported validation flow.
- Implement the required Event Grid subscription validation response or supported validation flow; require supported event delivery authentication and validate request origin or tokens.
Explanation
Correct Answer
D:The publisher validates endpoint ownership before activating supported webhook delivery. a public URL alone does not establish that an event came from the approved publisher.
Incorrect Answers
A:Event handlers should complete the delivery handshake quickly and process heavy tasks asynchronously; requirement 1 requires: implementing the required Event Grid subscription validation response or supported validation flow.
B:Require supported event delivery authentication and validate request origin or tokens.
C:A public URL alone does not establish that an event came from the approved publisher; requirement 1 requires: implementing the required Event Grid subscription validation response or supported validation flow.
Question 377
A storage event should invoke a Python Function without periodic blob listing or custom webhook polling. A Function is triggered by every event on a shared Event Grid topic although only model status updates are relevant. Which course of action addresses the stated issues?
- Configure an Event Grid trigger and matching event subscription; update and validate the Event Grid subscription's Function destination.
- Update and validate the Event Grid subscription's Function destination; Narrow its Event Grid subscription with matching event filters.
- Narrow its Event Grid subscription with matching event filters; do not configure an Event Grid trigger and matching event subscription.
- Configure an Event Grid trigger and matching event subscription; Narrow its Event Grid subscription with matching event filters.
Explanation
Correct Answer
D:Event Grid delivery can invoke the Function in response to published source events. filtering upstream prevents irrelevant events from invoking the handler.
Incorrect Answers
A:Narrow its Event Grid subscription with matching event filters.
B:Events reach the deployed function only when the subscription targets its live endpoint; requirement 1 requires: configuring an Event Grid trigger and matching event subscription.
C:Filtering upstream prevents irrelevant events from invoking the handler; requirement 1 requires: configuring an Event Grid trigger and matching event subscription.
Question 378
One distributed trace includes the HTTP request but not the Service Bus send operation that initiated its background job. A consumer span is always a child of whichever unrelated request was last handled by a pooled worker. Which response best addresses these needs?
- Model batch processing with appropriate span links or separate contexts for the incoming messages; Extract the incoming message trace context for each independently processed message.
- Create an appropriate producer span around the broker send and inject propagation metadata; Model batch processing with appropriate span links or separate contexts for the incoming messages.
- Create an appropriate producer span around the broker send and inject propagation metadata; Extract the incoming message trace context for each independently processed message.
- Extract the incoming message trace context for each independently processed message; do not create an appropriate producer span around the broker send and inject propagation metadata.
Explanation
Correct Answer
C:Messaging instrumentation makes the asynchronous handoff visible in the trace timeline. reusing stale context misattributes a message to the wrong business operation.
Incorrect Answers
A:Independent message parents should not be falsely represented as one single ancestor; requirement 1 requires: creating an appropriate producer span around the broker send and inject propagation metadata.
B:Extract the incoming message trace context for each independently processed message.
D:Reusing stale context misattributes a message to the wrong business operation; requirement 1 requires: creating an appropriate producer span around the broker send and inject propagation metadata.
Question 379
An engineer accidentally deletes a production Key Vault secret and needs the previous value restored without inventing a new one. A vault must protect critical keys from immediate permanent deletion by an overprivileged operator. What is the most appropriate plan for this situation?
- Inspect the soft-deleted vault state and use the authorized recovery or purge lifecycle; enable and retain appropriate Key Vault purge protection.
- Recover the soft-deleted secret within its retention window; inspect the soft-deleted vault state and use the authorized recovery or purge lifecycle.
- Recover the soft-deleted secret within its retention window; enable and retain appropriate Key Vault purge protection.
- Enable and retain appropriate Key Vault purge protection; do not Recover the soft-deleted secret within its retention window.
Explanation
Correct Answer
C:Soft-delete recovery can restore a deleted secret before permanent purge. purge protection prevents bypassing the retention period to destroy deleted vault objects.
Incorrect Answers
A:Soft-deleted vaults can retain their names until the retention process is resolved; Requirement 1 requires: recover the soft-deleted secret within its retention window.
B:Enable and retain appropriate Key Vault purge protection.
D:Purge protection prevents bypassing the retention period to destroy deleted vault objects; Requirement 1 requires: recover the soft-deleted secret within its retention window.
Question 380
An Azure Function reads one Key Vault secret using a plaintext credential in its configuration. A worker Function uses a global storage-account key to list all containers although it only needs one blob container. Which course of action addresses the stated issues?
- Enable the Function's managed identity and grant scoped secret-read permission; implement bounded secret caching and refresh on rotation or authentication failures.
- Use least-privilege data-plane authorization for the required blob scope; do not enable the Function's managed identity and grant scoped secret-read permission.
- Implement bounded secret caching and refresh on rotation or authentication failures; use least-privilege data-plane authorization for the required blob scope.
- Enable the Function's managed identity and grant scoped secret-read permission; use least-privilege data-plane authorization for the required blob scope.
Explanation
Correct Answer
D:Managed identity supplies short-lived tokens without embedding a separate service principal password. scoped role assignment limits a compromised function to the resources it actually processes.
Incorrect Answers
A:Use least-privilege data-plane authorization for the required blob scope.
B:Scoped role assignment limits a compromised function to the resources it actually processes; Requirement 1 requires: enable the Function's managed identity and grant scoped secret-read permission.
C:A long-lived process may retain stale credentials even when Key Vault has a newer version; Requirement 1 requires: enable the Function's managed identity and grant scoped secret-read permission.
Developing AI Cloud Solutions on Azure (AI-200) Practice Tests