-
Notifications
You must be signed in to change notification settings - Fork 9
Commit
This commit does not belong to any branch on this repository, and may belong to a fork outside of the repository.
See appsignal/appsignal-elixir#957. Emit a deprecation warning both when the `heartbeat` helper is used and when the `Heartbeat` class is initialised, but only once each.
- Loading branch information
Showing
8 changed files
with
579 additions
and
373 deletions.
There are no files selected for viewing
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -0,0 +1,6 @@ | ||
--- | ||
bump: patch | ||
type: deprecate | ||
--- | ||
|
||
Calls to `Appsignal.heartbeat` and to the `Appsignal.Heartbeat` constructor will emit a deprecation warning. |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -0,0 +1,22 @@ | ||
--- | ||
bump: patch | ||
type: change | ||
--- | ||
|
||
Rename heartbeats to cron check-ins. Calls to `Appsignal.heartbeat` and `Appsignal.Heartbeat` should be replaced with calls to `Appsignal.checkIn.cron` and `Appsignal.checkIn.Cron`, for example: | ||
|
||
```js | ||
// Before | ||
import { heartbeat } from "@appsignal/nodejs" | ||
|
||
heartbeat("do_something", () => { | ||
do_something() | ||
}) | ||
|
||
// After | ||
import { checkIn } from "@appsignal/nodejs" | ||
|
||
checkIn.cron("do_something", () => { | ||
do_something | ||
}) | ||
``` |
Oops, something went wrong.