Getting a runtime exception - TargetMissing

Not applicable

I am trying to connect a Resource to a target Endpoint in my API Proxy. I have added the target server to Apigee via POST call. I have configured routing rule for this resource to flow through the identified Target Server.

When i try to run the call, I am getting the following error code.

messaging.Runtime.TargetMissing

I can reach the internal service directly. And my Network teams confirmed that a Firewall rule is configured to allow interaction between Apigee and Internal service. Yet. I receive this error all the time.

Could someone help me with this issue. why I am seeing this error and what are my next possible steps to debug the issue ?

0 9 954
9 REPLIES 9

can you attach the proxy here?

or ... alternatively, rather than describing the routing rule, .... show the code.

Also show the code for the Target.

Not applicable

@Dino - Sorry My Bad. Please find the configuration I used.

Following is the Routing rule in Proxy

<RouteRule name="TaxesService">

<Condition>(proxy.pathsuffix MatchesPath "/*/taxes/quote**") or (proxy.pathsuffix MatchesPath "/*/taxes/invoice**") or (proxy.pathsuffix MatchesPath "/*/taxes/distribute**")

</Condition>

<TargetEndpoint>TaxesService</TargetEndpoint>

</RouteRule>

Following is the Target Connection on my Target End point : TaxesService

<HTTPTargetConnection>

<LoadBalancer>

<MaxFailures>0</MaxFailures>

<RetryEnabled>true</RetryEnabled>

<Server name="TAX-SVC-STANDALONE">

<IsEnabled>true</IsEnabled>

<IsFallback>false</IsFallback>

<Weight>1</Weight>

</Server>

</LoadBalancer>

<Path>/gsi-taxes-duties-fees-service/svc/external/v1.0</Path>

<Properties/>

</HTTPTargetConnection>.


Following is the named Target Server added


{

"host": "[redacted for security]",

"isEnabled": true,

"name": "TAX-SVC-STANDALONE",

"port": [redacted for security]

}

@Srivatssan Srinivasan

Answers are strictly for answers. Use comments / Edit your question to update more details.

Not applicable

Following is the Routing rule in Proxy

<RouteRule name="TaxesService">

<Condition>(proxy.pathsuffix MatchesPath "/*/taxes/quote**") or (proxy.pathsuffix MatchesPath "/*/taxes/invoice**") or (proxy.pathsuffix MatchesPath "/*/taxes/distribute**")

</Condition>

<TargetEndpoint>TaxesService</TargetEndpoint>

</RouteRule>

Following is the Target Connection on my Target End point : TaxesService

<HTTPTargetConnection>

<LoadBalancer>

<MaxFailures>0</MaxFailures>

<RetryEnabled>true</RetryEnabled>

<Server name="TAX-SVC-STANDALONE">

<IsEnabled>true</IsEnabled>

<IsFallback>false</IsFallback>

<Weight>1</Weight>

</Server>

</LoadBalancer>

<Path>/gsi-taxes-duties-fees-service/svc/external/v1.0</Path>

<Properties/>

</HTTPTargetConnection>.

Following is the named Target Server added

{

"host": "[redacted for security]",

"isEnabled": true,

"name": "TAX-SVC-STANDALONE",

"port": [redacted for security]

}

Not applicable

Hi,

I also tried extract a debug log from the call. I found that my routing rule is failing even though the name of Target endpoint is specified properly. Please note the Expression Result and that the variable target.name

has no value.

How is this variable populated and is there any other place I missed in configuration ?

{ "id": "Condition", "results":

[ { "ActionResult": "DebugInfo",

"properties": {

"property":

[ { "name": "ExpressionResult",

"value": "false" },

{ "name": "Expression",

"value": "(\"TaxesService\" equals target.name)"

},

{ "name": "Tree",

"value": "TARGET_TaxesService" } ]

},

"timestamp": "11-10-16 20:27:35:843" },

{ "ActionResult": "VariableAccess",

"accessList": [

{ "Get": { "name": "target.name" } } ]

} ] }

Not applicable

Hi Srivatssan Srinivasan

From your description and code, I couldn't find any reason why it failed.

The only checkpoint I could think of is, have you setup the variable

target.copy.pathsuffix to false, as I found the request suffix path is different from the target endpoint path.

@Zheng Yang - You are correct in your analysis . However, in my case, the problem was that the deployment failed on one of the Message Processor and hence the route rule was failing for all traffic in that node. I am running a private installed version of Apigee and hence could control this aspect. I rolled back, re-deployed and it worked fine.

We are using an old version of Apigee 14.04 and the failure in deployment was not displayed via the UI or the ReST call. Apigee team is helping us resolve the issue currently for ensure these types of issues don't arise in the future. Will update this thread with solution once we have it in place.

Thank you all!

14.04? Three years old?!!? Wow.

4399-screenshot-20170228-111742.png

LOL. Yes Dino. We have signed a contract for an upgrade to 16.9 by this quarter. I will then bring back more interesting questions to the community hopefully! 🙂