apollo-server/packages/apollo-tracing-js/package.json
Evans Hauser 8496387c78
Import apollo-tracing-js (#1292)
* Initial commit

* 0.0.3

* Replace endOffset with duration in resolver calls

* 0.0.4

* Fix duration

* 0.0.5

* Remove unnecessary schema level resolve function and return schema

* Update README

* 0.0.6

* Update README

* Update dependencies

* 0.0.7

* Update README

* set package.json to point to this repository (#3)

* Update dependencies

Fixes #4.

* 0.0.8

* Add asynciterable support to tsconfig.json

* Skip trace collection when context or context._traceCollector is undefined

Fixes #5.

* 0.0.9

* Rewrite to use graphql-extensions

* 0.0.10

* 0.0.11

* 0.1.0

* Update graphql-extensions dependency and downgrade TS target

* 0.1.1

* Update README

* Update README

* Increase version range for `graphql` peerDependency. (#7)

* 0.1.2

* Update dependencies

* 0.1.3

* [apollo-bot] Update the Issue/PR Templates with auto label (#9)

* Update `graphql` peer dependency range to allow 0.13.x.

* dev: Update TypeScript to latest version, v2.7.2.

* dev: Update jest & dependencies to latest versions.

* dev: Update type definitions for `graphql`, `node` and `jest`.

* Allow `undefined` to return from `format`. (#12)

* Allow `undefined` to return from `format`.

TypeScript 2.7 introduced new "Strict Class Instantiation" rules which,
as the name suggests, require properties which are intended to be set
(eventually, to a type) be set during construction.

Before this change, the `TracingExtension` class was deferred setting these
private properties (namely, `startWallTime`, `endWallTime`, `startHrTime`
and `duration`), but not during instantiation which required setting
marking them as optional and guarding their usage in other methods which
might use those (temporarily `undefined`, if even for a tick) properties.
For example, the expectation that `format` is _only_ called after
`requestDidStart` is not guaranteed with this configuration, even if it is
expected under normal operation.

Therefore, this change adds the additional guarding and updates the `format`
method to return `undefined` in the event that it doesn't have the appropriate
data.

* Update `graphql-extensions` dependency to `~0.0.9`.

Specifically, to take advantage of a type which landed in
`graphql-extensions@0.0.9` thanks to
https://github.com/apollographql/graphql-extensions/pull/10.

* 0.1.4

* Update for graphql-extensions@0.1.0 API (#13)

* Upgrade to TypeScript 2.8

* Add tslint and prettier

* Update for graphql-extensions@0.1.0 API

* 0.2.0-beta.0

* Make work with newest API usage

format() now gets called before the requestDidStart() EndHandler.

* 0.2.0-beta.1

* remove unused files from tracing package

* upgrade packages, fix compilation bugs, and add test
2018-07-03 13:53:25 -07:00

60 lines
1.3 KiB
JSON

{
"name": "apollo-tracing",
"version": "0.2.0-beta.1",
"description": "Collect and expose trace data for GraphQL requests",
"main": "./dist/index.js",
"types": "./dist/index.d.ts",
"scripts": {
"clean": "rm -rf dist",
"compile": "tsc",
"prepublish": "npm run compile",
"test": "jest --verbose",
"watch": "tsc -w"
},
"license": "MIT",
"repository": "apollographql/apollo-tracing-js",
"author": "Martijn Walraven <martijn@martijnwalraven.com>",
"engines": {
"node": ">=4.0"
},
"dependencies": {
"graphql-extensions": "0.1.0-beta.0"
},
"peerDependencies": {
"graphql": "0.10.x - 0.13.x"
},
"devDependencies": {
"@types/graphql": "^0.13.1",
"@types/jest": "^23.1.2",
"@types/node": "^10.3.6",
"jest": "^23.2.0",
"jest-matcher-utils": "^23.2.0",
"prettier": "^1.13.6",
"ts-jest": "^22.4.6",
"typescript": "^2.9.2"
},
"prettier": {
"trailingComma": "all",
"singleQuote": true
},
"jest": {
"testEnvironment": "node",
"transform": {
"^.+\\.(ts|js)$": "ts-jest"
},
"moduleFileExtensions": [
"ts",
"js",
"json"
],
"testRegex": "apollo-tracing-js/src/__tests__/.*$",
"roots": [
"../../"
],
"globals": {
"ts-jest": {
"skipBabel": true
}
}
}
}