Skip to content

Fix type of ApolloServerPluginUsageReporting reportTimer#7799

Merged
trevor-scheer merged 2 commits intoapollographql:mainfrom
stijnbe:fix_report_timer
Dec 11, 2023
Merged

Fix type of ApolloServerPluginUsageReporting reportTimer#7799
trevor-scheer merged 2 commits intoapollographql:mainfrom
stijnbe:fix_report_timer

Conversation

@stijnbe
Copy link
Copy Markdown
Contributor

@stijnbe stijnbe commented Dec 10, 2023

Fixes #7798
In src/plugin/usageReporting/plugin.ts reportTimer is typed as NodeJS.Timer, it is actually a timeout, so using node 18> types it is incompatible with clearInterval()

@apollo-cla
Copy link
Copy Markdown

@stijnbe: Thank you for submitting a pull request! Before we can merge it, you'll need to sign the Apollo Contributor License Agreement here: https://contribute.apollographql.com/

@netlify
Copy link
Copy Markdown

netlify Bot commented Dec 10, 2023

👷 Deploy request for apollo-server-docs pending review.

Visit the deploys page to approve it

Name Link
🔨 Latest commit e8ca46c

@codesandbox-ci
Copy link
Copy Markdown

codesandbox-ci Bot commented Dec 10, 2023

This pull request is automatically built and testable in CodeSandbox.

To see build info of the built libraries, click here or the icon next to each commit SHA.

Latest deployment of this branch, based on commit e8ca46c:

Sandbox Source
Apollo Server Typescript Configuration
Apollo Server Configuration

Copy link
Copy Markdown
Contributor

@trevor-scheer trevor-scheer left a comment

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Thanks, lgtm. Can you please add a patch changeset? You can run npx changeset and follow the prompts.

@trevor-scheer trevor-scheer merged commit 63dc50f into apollographql:main Dec 11, 2023
@github-actions github-actions Bot mentioned this pull request Dec 11, 2023
trevor-scheer pushed a commit that referenced this pull request Jan 2, 2024
This PR was opened by the [Changesets
release](https://github.com/changesets/action) GitHub action. When
you're ready to do a release, you can merge this and the packages will
be published to npm automatically. If you're not ready to do a release
yet, that's fine, whenever you add more changesets to main, this PR will
be updated.


# Releases
## @apollo/[email protected]

### Minor Changes

- [#7786](#7786)
[`869ec98`](869ec98)
Thanks [@ganemone](https://github.com/ganemone)! - Restore missing v1
`skipValidation` option as `dangerouslyDisableValidation`. Note that
enabling this option exposes your server to potential security and
unexpected runtime issues. Apollo will not support issues that arise as
a result of using this option.

### Patch Changes

- [#7740](#7740)
[`fe68c1b`](fe68c1b)
Thanks [@barnisanov](https://github.com/barnisanov)! - Uninstalled
`body-parser` and used `express` built-in `body-parser` functionality
instead(mainly the json middleware)

- Updated dependencies
\[[`869ec98`](869ec98),
[`9bd7748`](9bd7748),
[`63dc50f`](63dc50f),
[`fe68c1b`](fe68c1b),
[`e9a0d6e`](e9a0d6e)]:
    -   @apollo/[email protected]

## @apollo/[email protected]

### Minor Changes

- [#7786](#7786)
[`869ec98`](869ec98)
Thanks [@ganemone](https://github.com/ganemone)! - Restore missing v1
`skipValidation` option as `dangerouslyDisableValidation`. Note that
enabling this option exposes your server to potential security and
unexpected runtime issues. Apollo will not support issues that arise as
a result of using this option.

- [#7803](#7803)
[`e9a0d6e`](e9a0d6e)
Thanks [@favna](https://github.com/favna)! - allow `stringifyResult` to
return a `Promise<string>`

Users who implemented the `stringifyResult` hook can now expect error
responses to be formatted with the hook as well. Please take care when
updating to this version to ensure this is the desired behavior, or
implement the desired behavior accordingly in your `stringifyResult`
hook. This was considered a non-breaking change as we consider that it
was an oversight in the original PR that introduced `stringifyResult`
hook.

### Patch Changes

- [#7793](#7793)
[`9bd7748`](9bd7748)
Thanks [@bnjjj](https://github.com/bnjjj)! - General availability of
subscription callback protocol

- [#7799](#7799)
[`63dc50f`](63dc50f)
Thanks [@stijnbe](https://github.com/stijnbe)! - Fix type of
ApolloServerPluginUsageReporting reportTimer

- [#7740](#7740)
[`fe68c1b`](fe68c1b)
Thanks [@barnisanov](https://github.com/barnisanov)! - Uninstalled
`body-parser` and used `express` built-in `body-parser` functionality
instead(mainly the json middleware)

Co-authored-by: github-actions[bot] <github-actions[bot]@users.noreply.github.com>
@github-actions github-actions Bot locked as resolved and limited conversation to collaborators Jan 11, 2024
Sign up for free to subscribe to this conversation on GitHub. Already have an account? Sign in.

Labels

None yet

Projects

None yet

Development

Successfully merging this pull request may close these issues.

ApolloServerPluginUsageReporting reportTimer has incorrect type

3 participants