Practice
Solution
Step 1: Evaluate embedding rules in code (A) and binaries (D)
Both require redeployment or restart on rule changes, causing downtime or latency spikes.Step 2: Assess querying rules synchronously (C)
Querying rules synchronously adds latency and risk of inconsistent rule versions during scoring.Step 3: Consider external rule engine with hot-reload (B)
This allows dynamic rule updates without downtime and low latency via caching and efficient evaluation.Final Answer:
Option B -> Option BQuick Check:
External hot-reload rule engine -> dynamic updates, low latency [check]
Solution
Step 1: Analyze bandwidth and latency constraints
Mobile apps benefit from minimizing data transfer and round-trips due to limited bandwidth and latency.Step 2: Compare REST and GraphQL trade-offs
REST multiple endpoints cause multiple round-trips; single endpoint REST over-fetches; GraphQL queries exactly needed fields in one request.Final Answer:
Option D -> Option DQuick Check:
GraphQL reduces over-fetching and round-trips for mobile [check]
Solution
Step 1: Evaluate fuzzy matching and ranking requirements
Fuzzy matching and popularity ranking require complex scoring and typo tolerance, which Elasticsearch supports natively with fuzzy queries and custom scoring functions.Step 2: Assess other options
Trie and prefix hash map lack built-in fuzzy matching and ranking; relational DB LIKE queries are inefficient and don't scale well for fuzzy search.Final Answer:
Option A -> Option AQuick Check:
Elasticsearch supports fuzzy search and ranking out-of-the-box [check]
Solution
Step 1: Identify synchronous quorum coordinator role
Coordinator waits synchronously for majority acks, causing latency and throughput limits.Step 2: Compare other components' scaling challenges
Storage nodes and network scale better; client-side blocking is per client, less centralized.Final Answer:
Option A -> Option AQuick Check:
Coordinator sync wait limits throughput at scale [check]
Solution
Step 1: Identify scaling bottlenecks
Blue-Green requires two full environments; load balancer scales horizontally; feature flags scale independently.Step 2: Analyze deployment pipeline
Build servers face 10x concurrent builds, causing queueing and delays, blocking releases.Step 3: Compare other components
Load balancer and feature flags can be sharded; doubling environment cost is expensive but not a failure.Final Answer:
Option A -> Option AQuick Check:
Build servers bottleneck at 10x concurrent builds, delaying deployments [check]
