Calculate MC2 Endpoints Port Numbers
MC2 exposes a set of REST and Web Service Endpoints. The endpoint port numbers are calculated from a base port number, which is taken from the eagle/cfg/system.xml file. For Eagle 13.1 systems the file is eagle/estar/tpe/cfg/system.xml.
For example, when the system.xml file has the following data, the MC2 base port is calculated as 20000 + 220 = 20220.
system.xml
<?xml version="1.0" encoding="UTF-8"?>
<system version="1.1">
<servers baseport="20000" server_type="1" starversion="**Eagle Version 13.1**">
...
<server ignorewsdb="1" name="extractservice" offset="220" type="extractservice"/>
All other endpoints have an offset, which is added to the base port and results in a specific endpoint port number. MC2 initiates a TpeSend listener to process requests from the EagleMLWebService30 endpoint on the MC2 base port (20220 based on the example above).
REST API Calculations
A REST API to the Eagle MC2 Extract Service is calculated as base port plus an offset of 207. The result is 20427 when using the example above. A REST API for health checks and information about the running instance of MC2 is calculated as port plus an offset of 202. The result is 20422 when using the example above. The information can be accessed at: http://mc2host:20422/actuator
This request returns a JSON document which links to all the other available management/monitoring links. The information can be accessed at http://mc2host:20422/health. This returns a simple health status check. A REST endpoint that reinitializes the rule cache is calculated as base port plus an offset of 206. The result is 20426 when using the example above. The URL is http://xn--http-4b7a//mc2host:20426/services/eagle/v2/commands/reinitrulecache.http://mc2host:20426/services/eagle/v2/commands/reinitrulecache.
The above request reinitializes the rule cache for all of the MC2 service instances. A SOAP endpoint that executes requests, exposed directly without the TpeSend/IIS, is calculated as base port plus an offset of 201 The result is 20421 when using the example above. The URL to invoke the SOAP endpoint is http://mc2host:20421/services/eagle/v2/EagleMLWebService20