• Home
  • Features
  • Pricing
  • Docs
  • Announcements
  • Sign In

TykTechnologies / tyk / 5521

Build:
DEFAULT BRANCH: master
Ran 09 Sep 2018 02:50PM UTC
Jobs 2
Files 100
Run time 18s
Badge
Embed ▾
README BADGES
x

If you need to use a raster PNG badge, change the '.svg' to '.png' in the link

Markdown

Textile

RDoc

HTML

Rst

pending completion
5521

push

travis-ci

web-flow
Added new Debugging API (#1896)

Added new Tracing API, which allows you to debug API definition, by sending sample request to it.

As input, Tracing API require sample request object, and direct API definition.
This means that tracing API can be used even without creating API. Or for example, you can test API changes without saving them.

Example request:
```
POST /tyk/trace
{
    "request": {
        "method": "GET",
        "path": "/get",
        "headers": {
            "Header": ["Value"]
        }
    },
    "spec": {
        ...valid API definition...
    }
}
```

As output, it gives you response object, and gateway logs as JSON multi-line string.

Example output:
```
{
    "message": "ok"
    "response": "<raw-http-response-dump>",
    "logs": "{...}\n{...}"
}
```

Logging itself now way more structured, and prepared for easy parsing. Based on the logs you can see:
* API loading process: which middleware was loaded or not, issues during parsing and etc.
* Middleware logs: order of running, elapsed time, individual MW logs

Example of log output:

```
{"level":"debug","msg":"Default JSVM timeout used: 5s","prefix":"jsvm","time":"2018-09-05T17:49:19+03:00"}
{"api_id":"test","api_name":"","level":"info","msg":"Loading API","org_id":"","time":"2018-09-05T17:49:19+03:00"}
{"api_id":"test","api_name":"","level":"debug","msg":"Initializing API","org_id":"","time":"2018-09-05T17:49:19+03:00"}
{"api_id":"test","api_name":"","level":"debug","msg":"Init","mw":"RateCheckMW","org_id":"","time":"2018-09-05T17:49:19+03:00"}
{"api_id":"test","api_name":"","level":"debug","msg":"Init","mw":"VersionCheck","org_id":"","time":"2018-09-05T17:49:19+03:00"}
{"api_id":"test","api_name":"","level":"info","msg":"Checking security policy: Token","org_id":"","time":"2018-09-05T17:49:19+03:00"}
{"api_id":"test","api_name":"","level":"debug","msg":"Init","mw":"AuthKey","org_id":"","time":"2018-09-05T17:49:19+03:00"}
{"api_id"... (continued)

9630 of 15803 relevant lines covered (60.94%)

1.35 hits per line

Jobs
ID Job ID Ran Files Coverage
1 5521.1 (LATEST_GO=true) 09 Sep 2018 02:50PM UTC 0
60.33
Travis Job 5521.1
2 5521.2 (LATEST_GO=true) 09 Sep 2018 02:50PM UTC 0
60.95
Travis Job 5521.2
Source Files on build 5521
Detailed source file information is not available for this build.
  • Back to Repo
  • Travis Build #5521
  • 9caced01 on github
  • Prev Build on master (#5512)
  • Next Build on master (#5522)
STATUS · Troubleshooting · Open an Issue · Sales · Support · CAREERS · ENTERPRISE · START FREE · SCHEDULE DEMO
ANNOUNCEMENTS · TWITTER · TOS & SLA · Supported CI Services · What's a CI service? · Automated Testing

© 2025 Coveralls, Inc