Skip to content

Releases: BlueOakJS/blueoak-server

Add support for configuring HTTP Server Timeout Values

13 Jul 14:08
Compare
Choose a tag to compare

See: https://nodejs.org/api/http.html#http_class_http_server

In particular, support added for:

  • timeout (available when running Node v0.9.12 and later)
  • keepAliveTimeout (available when running Node v8.0.0 and later)
  • headersTimeout (available when running Node v11.3.0 and later)

These can be set in the "express" block in default.json as:

"express": {
    "httpServer": {
      "timeout": 111111,
      "keepAliveTimeout": 222222,
      "headersTimeout": 333333
    }
  }

This feature is also documented on the Wiki as HTTP Server Timeouts.

Attach "sent body" to Express response object when response model validation is on

01 Apr 18:47
Compare
Choose a tag to compare

When response validation is enabled in any mode, the validated body is attached to the Express response object in a field named sentBody for use by handlers and/or middleware that are configured to execute after the response is sent.

Updates to resolve security vulnerabilities

23 Nov 18:30
Compare
Choose a tag to compare

lodash from 3.x to 4.x
request from 2.85 to 2.88
mocha to latest

In addition to these updates, Node.js v4 is no longer supported.

User-initiated Swagger (OpenAPI) model validation

23 Jan 18:11
Compare
Choose a tag to compare

This release exposes a new function on the swagger service, validateObject.

It also raises response model validation errors/warnings (depending on your config) when "unknown" properties, i.e. properties that are not defined in the spec, are returned in the response.

Compose BlueOak Server Projects into One

14 Feb 19:31
Compare
Choose a tag to compare

Use config option:
"server-provisions": ["node-module-name", ...]
To compose BlueOak Server projects into a single server.

Modules implementing "server-provisions" should implement BlueOak Server services and middleware in directories with those names.

Get started with the BlueOak Server project, use the template.

Full request validation

17 Dec 20:37
Compare
Choose a tag to compare

BOS now validates all request parameters (body, form, header, path, query) before returning a validation error.
(It used to return after the first, which meant users may need to make multiple requests before learning everything that was wrong with their original request. The old behavior can be restored by setting swagger.rejectRequestAfterFirstValidationError in your config.)

Note also, that it is possible to use middleware loaded from a node module.

OpenAPI $ref Compiler

14 Oct 12:39
Compare
Choose a tag to compare

A feature has been added to help the management of OpenAPI (swagger) spec $refs to external files by automatically adding references to them to your main API file's definitions, responses, and parameters properties.

Learn more on the wiki.

Polymorphic Validation of Swagger Models

15 Sep 18:16
Compare
Choose a tag to compare

The major feature of this release is support for polymorphic swagger models (issue #60).
Learn more on the wiki.

The response model validation support that was added in v2.3.0 has also been updated to support a new level, "fail".
Read more about that on the wiki too.

Swagger Response Model Validation

23 Aug 09:29
Compare
Choose a tag to compare

This version adds support for validating response models against the defined Swagger spec for each method.
This is very useful during development and is controlled via the swagger.validateResponseModels parameter, (learn more)[https://github.com/BlueOakJS/blueoak-server/wiki/Handlers#swagger-model-validation].

v2.1.1

19 Feb 19:20
Compare
Choose a tag to compare

Fixes minor issue in unit test util.