Free Google Apigee-API-Engineer Actual Exam Questions - Question 8 Discussion
you expect. You have verified that there is a RouteRule that matches conditions, and should be
called. What should you do?
A/D? If conditions are definitely matching but the wrong endpoint is called, maybe the RouteRule targets a generic TargetServer that doesn’t handle this case right. So adding a new TargetServer (D) for your special condition makes sense. On the other hand, if multiple RouteRules overlap and the wrong one gets picked first, making them more specific (A) can help avoid conflicts before jumping to new servers. Both seem valid steps depending on whether the problem is condition specificity or the actual TargetServer setup.
D imo, if the RouteRule is matching but still sending you to the wrong endpoint, maybe the TargetServer it references isn’t set up right for that condition. Adding a new TargetServer specifically for your edge case could clear up the confusion without changing how you order or write your rules. Sometimes the problem isn’t the routing logic but the actual server config behind it.
C, since RouteRules are processed in order and reordering can fix priority conflicts.
B tbh, creating a new proxy isolates the special case and avoids messing with existing rules, which can get messy. It’s cleaner if that condition is unique enough to warrant separate handling.
Maybe D could work if the issue is that the TargetServer itself doesn’t correctly represent the intended endpoint for that condition. Adding a new TargetServer for specific cases can help route traffic properly without messing with RouteRules. This assumes the RouteRules are actually matching but pointing to the wrong backend, so just shuffling rules won’t fix the underlying mapping problem.
Adeel I.: A imo, making RouteRules more specific helps prevent overlap issues that reordering alone won’t fix if conditions still match multiple rules. It’s a cleaner long-term fix.
C makes the most sense here. RouteRules are evaluated top to bottom, so if a more generic rule comes before your specific one, it’ll catch the request first and send it to the wrong TargetEndpoint. Just reordering them usually fixes this without changing any logic or adding complexity. No need to create new proxies or targets unless you want to handle entirely different use cases. Less hassle and cleaner setup if you just adjust the order.
I’m going with C here. RouteRules get evaluated in order and if a more general rule is listed first, it can prevent more specific ones from being triggered. Just swapping the order usually fixes the problem without complicating the setup.
C imo, because RouteRules are checked in order, so if a more general rule is before your specific one, it could hijack the call. Reordering often fixes this without needing to change conditions.
I think option A could be the key here. If your RouteRule conditions are too broad or overlap, Apigee might match an earlier rule unintentionally, causing the wrong target endpoint to be selected. Making the conditions more specific can prevent that confusion. Just reordering (C) might not help if the rules themselves aren’t distinct enough. Has anyone tested what happens when you tighten conditions instead of just moving rules around?
C/D? Reordering RouteRules (C) often fixes the issue since they’re checked top to bottom, but if your targets need separate handling, adding a new TargetServer (D) might be necessary. Depends on your setup.
Maybe A makes sense too. If the RouteRule conditions aren’t specific enough, Apigee might pick the wrong one even if the order is right. Tightening conditions could help clarify which endpoint to call.
I’d go with C. Sometimes the order of RouteRules matters, so reordering them can fix which endpoint gets called.