Cook Diagnostic Resources

The Cook provides some useful diagnostic information under the /- URL. If you open a browser and go to your-site:8101/- you will see a list of links to the following resources:

Incoming requests

This resource is located at your-site:8101/-/incoming. It displays a constantly updated list of the requests currently being handled by the Cook. For each request the following information is displayed:

  • The number of seconds the request has been running

  • The path of the request (/tomorrow-online/tag/ramsey, for example)

  • The request's X-Request-ID

For example:

1.243     /tomorrow-online/tag/ramsey     e59431a6-a44c-11e8-8957-67f31fc15fef

The list is updated every 3 seconds by default. You can change the refresh interval by editing the page's URL. To change the interval to 5 seconds, for example enter:

your-site:8101/-/incoming?refresh=5
Outgoing requests

This resource is located at your-site:8101/-/outgoing. It displays a constantly updated list of outgoing requests made by the Cook that have not yet completed. For each request the following information is displayed:

  • The number of seconds the request has been running

  • The request URL (http://solr.example.com:8983/solr/presentation/select?id, for example)

  • The request's X-Request-ID

For example:

1.243     http://solr.example.com:8983/solr/presentation/select?id     e59431a6-a44c-11e8-8957-67f31fc15fef

The list is updated every 3 seconds by default. You can change the refresh interval by editing the page's URL. To change the interval to 5 seconds, for example enter:

your-site:8101/-/outgoing?refresh=5
Incoming request log

This resource is located at your-site:8101/-/incoming-log. It displays a list of recently completed incoming requests. For each request the following information is displayed:

  • The time at which the request was made

  • The number of seconds the request took to complete

  • The path of the request (/tomorrow-online/tag/ramsey, for example)

  • The type of response given (HTTP response code)

  • The request's X-Request-ID

For example:

2018-10-30T13:28:06.073Z   1.195    /tomorrow-online/  200  f292fae7-adf0-4387-981c-2943dd708f9b

By default, the log shows the last 50 incoming requests. You can modify this by specifying a parameter in cook-config.yml. To increase the number to 100, for example:

log-incoming-count: 100
Outgoing request log

This resource is located at your-site:8101/-/outgoing-log. It displays a list of recently completed outgoing requests. For each request the following information is displayed:

  • The time at which the request was made

  • The number of seconds the request took to complete

  • The request URL (http://solr.example.com:8983/solr/presentation/select?id, for example)

  • The type of response received (HTTP response code)

  • The request's X-Request-ID

For example:

2018-10-30T15:56:38.448Z 0.197    http://to.example.com:8080/webservice/escenic/section/8 200 1b829a02-3e75-43d4-b9d2-1f2c4e542566

By default, the log shows the last 100 outgoing requests. You can modify this by specifying a parameter in cook-config.yml. To increase the number to 200, for example:

log-outgoing-count: 200

The X-Request-ID associated with an incoming request is passed on by the Cook to all associated outgoing requests, making it easy to see which requests in the log belong together.