How to Troubleshoot

  • <SERVICE-NAME> can be found in make -f .stoobly/docker/Makefile <WORKFLOW-NAME>/services

  • <WORKFLOW-NAME> by default can either be record, mock, or test

After Scaffolding an App

1

Double check scaffold configuration

  • Workflow run --app-dir-path option matches the location of the application scaffold

  • Workflow run --context-dir-path option matches the location of .stoobly folder where snapshots are stored

  • Service create --port and --scheme option matches how the service is running

2

Double check custom container configuration

  • See .stoobly/docker/<SERVICE-NAME>/<WORKFLOW-NAME/docker-compose.yml

    • If running custom container(s) in a service, ensure that profiles contains the workflow name and networks contains the workflow name and/or the application name.

After Running a Workflow

1

Ensure two worklows are not running at the same time

  • Bring one workflow down before running another

    • e.g. make -f .stoobly/docker/Makefile <WORKFLOW-NAME>/down

2

Double check expected containers are running

  • Ensure the proxy container for each service is running

    • e.g. docker ps | grep <WORKFLOW-NAME>-<SERVICE-NAME>.proxy-1

    • To learn about which containers should be running, see here

  • If the workflow is either recordor mock ensure the gateway service is running

    • e.g. docker ps | grep <WORKFLOW-NAME>-gateway.service-1

3

Gather logs to search for errors

  • To view init and configure logs run:

    • make -f .stoobly/docker/Makefile <WORKFLOW-NAME>/logs options="--container init --container configure"

  • To view service logs run:

    • make -f .stoobly/docker/Makefile <WORKFLOW-NAME>/logs

4

Gather logs to trace request

  • Ensure that a request gets routed to the correct service container

    • To learn more about request service flow, see here

  • To view service logs run:

    • make -f .stoobly/docker/Makefile <WORKFLOW-NAME>/logs

  • To view gateway logs run:

    • make -f .stoobly/docker/Makefile <WORKFLOW-NAME>/logs options="--container service --service gateway"

5

Use validate workflow command

  • To learn more about the command, see here

After Unexpected 5xx Error

1

Double check system configuration

  • /etc/hosts contains the correct hostname(s)

2

Ensure CA certs are installed

After 499 Status Code (Mock Not Found)

1

Double check if the correct scenario is used

  • Double check if request exists in the scenario

  • By default the UI is configured to run on http://localhost:4200

2

Double check rewrite rules

  • See .stoobly/docker/<SERVICE-NAME>/<WORKFLOW-NAME>/bin/configure

  • To learn more about rewrite rules, see here

3

Double check lifecycle hooks

  • See .stoobly/docker/<SERVICE-NAME>/<WORKFLOW-NAME>/lifecycle_hooks.py

  • To learn more about lifecycle hooks, see here

4

Double check match rules

  • See .stoobly/docker/<SERVICE-NAME>/<WORKFLOW-NAME>/bin/configure

  • To learn more about match rules, see here

5

Gather logs to confirm correct application of rules (if any)

  • Search in the service logs to see if any rewrite rules are applied

  • To view service logs run:

    • make -f .stoobly/docker/Makefile <WORKFLOW-NAME>/logs

After Incorrect Response Returned

1

Double check if the correct scenario is used

  • Double check if request exists in the scenario

  • By default the UI is configured to run on http://localhost:4200

2

Create an Endpoint to enable component specific matching

  • To learn more, see here

Last updated

Was this helpful?