Skip to content

Commit

Permalink
NDC v0.2.0-rc.1 Support (#39)
Browse files Browse the repository at this point in the history
  • Loading branch information
daniel-chambers authored Nov 7, 2024
1 parent a696b39 commit 8459b1a
Show file tree
Hide file tree
Showing 12 changed files with 1,926 additions and 632 deletions.
5 changes: 5 additions & 0 deletions CHANGELOG.md
Original file line number Diff line number Diff line change
@@ -1,5 +1,10 @@
# NDC TypeScript SDK Changelog

## Unreleased changes
**Breaking changes** ([#39](https://github.com/hasura/ndc-sdk-typescript/pull/39)):
- Updated to support [v0.2.0 of the NDC Spec](https://hasura.github.io/ndc-spec/specification/changelog.html#020). This is a very large update which adds new features and some breaking changes.
- If the [`X-Hasura-NDC-Version`](https://hasura.github.io/ndc-spec/specification/versioning.html) header is sent, the SDK will validate that the connector supports the incoming request's version and reject it if it does not. If no header is sent, no action is taken.

## [7.0.0] - 2024-09-20
- Added support for exporting OpenTelemetry traces and metrics over GRPC. A new environment variable `OTEL_EXPORTER_OTLP_PROTOCOL` lets you switch between `http/protobuf` and `grpc`.
- **Breaking change**: the default OpenTelemetry exporter has changed from `http/protobuf` sending to `http://localhost:4318` to `grpc` sending to `http://localhost:4317`. To return to the old defaults, set the following environment variables:
Expand Down
4 changes: 2 additions & 2 deletions Cargo.lock

Some generated files are not rendered by default. Learn more about how customized files appear on GitHub.

137 changes: 52 additions & 85 deletions package-lock.json

Some generated files are not rendered by default. Learn more about how customized files appear on GitHub.

6 changes: 4 additions & 2 deletions package.json
Original file line number Diff line number Diff line change
Expand Up @@ -35,12 +35,14 @@
"commander": "^11.0.0",
"fastify": "^4.23.2",
"pino-pretty": "^10.2.3",
"prom-client": "^15.1.2"
"prom-client": "^15.1.2",
"semver": "^7.6.3"
},
"devDependencies": {
"@tsconfig/node18": "^18.2.4",
"@types/node": "^18.11.9",
"@types/semver": "^7.5.8",
"json-schema-to-typescript": "^13.1.1",
"typescript": "^5.4.3"
"typescript": "^5.6.3"
}
}
3 changes: 2 additions & 1 deletion src/schema/index.ts
Original file line number Diff line number Diff line change
@@ -1,6 +1,6 @@
import { JSONSchemaObject } from "@json-schema-tools/meta-schema";
import schema from "./schema.generated.json";
import { VERSION } from "./version.generated";
import { VERSION, VERSION_HEADER_NAME } from "./version.generated";

function schemaForType(type_name: string): JSONSchemaObject {
return {
Expand Down Expand Up @@ -32,4 +32,5 @@ export {
ErrorResponseSchema,
ValidateResponseSchema,
VERSION,
VERSION_HEADER_NAME,
};
Loading

0 comments on commit 8459b1a

Please sign in to comment.