Skip to content

Commit 5f0fa56

Browse files
authored
Update dependencies & workflows (#997)
1 parent ba62039 commit 5f0fa56

File tree

9 files changed

+1223
-417
lines changed

9 files changed

+1223
-417
lines changed

.github/workflows/npm-publish.yml

Lines changed: 2 additions & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -16,9 +16,9 @@ jobs:
1616
submodules: recursive
1717
- uses: actions/setup-node@v3
1818
with:
19-
node-version: 10
19+
node-version: 18
2020
registry-url: https://registry.npmjs.org/
21-
cache: 'npm'
21+
cache: "npm"
2222
- run: npm ci
2323
- run: npm publish
2424
env:

.github/workflows/test.yml

Lines changed: 5 additions & 9 deletions
Original file line numberDiff line numberDiff line change
@@ -1,20 +1,16 @@
1-
# This workflow will run tests using node and then publish a package to GitHub Packages when a release is created
2-
# For more information see: https://help.github.com/actions/language-and-framework-guides/publishing-nodejs-packages
3-
41
name: Test node-rdkafka
52

63
on:
74
push:
8-
branches: [ "master" ]
5+
branches: ["master"]
96
pull_request:
10-
branches: [ "master" ]
7+
branches: ["master"]
118

129
jobs:
1310
build:
1411
strategy:
1512
matrix:
16-
# 8, 10, 12, 14, 15, 16
17-
version: [12]
13+
version: [14, 16, 18, 19]
1814
runs-on: ubuntu-latest
1915
steps:
2016
- uses: actions/checkout@v3
@@ -23,7 +19,7 @@ jobs:
2319
- uses: actions/setup-node@v3
2420
with:
2521
node-version: ${{ matrix.version }}
26-
cache: 'npm'
22+
cache: "npm"
2723
- run: npm ci
2824
- run: npm test
29-
name: test
25+
name: test

.gitignore

Lines changed: 1 addition & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -11,5 +11,4 @@ deps/*
1111

1212
.DS_Store
1313

14-
package-lock.json
15-
.vscode
14+
.vscode

CONTRIBUTING.md

Lines changed: 6 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -220,3 +220,9 @@ Steps to update:
220220
1. Run end to end tests: `npm run test:e2e`. This requires running kafka & zookeeper locally.
221221
222222
1. Update the version numbers referenced in the [`README.md`](https://github.com/Blizzard/node-rdkafka/blob/master/README.md) file to the new version.
223+
224+
## Publishing new npm version
225+
226+
1. Increment the `version` in `package.json` and merge that change in.
227+
228+
1. Create a new github release. Set the tag & release title to the same string as `version` in `package.json`.

Makefile

Lines changed: 2 additions & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -57,13 +57,13 @@ $(CONFIG_OUTPUTS): node_modules/.dirstamp binding.gyp
5757
@$(NODE-GYP) configure
5858

5959
test: node_modules/.dirstamp
60-
@./node_modules/.bin/mocha $(TEST_REPORTER) $(TESTS) $(TEST_OUTPUT)
60+
@./node_modules/.bin/mocha --ui exports $(TEST_REPORTER) $(TESTS) $(TEST_OUTPUT)
6161

6262
check: node_modules/.dirstamp
6363
@$(NODE) util/test-compile.js
6464

6565
e2e: $(E2E_TESTS)
66-
@./node_modules/.bin/mocha --exit --timeout 120000 $(TEST_REPORTER) $(E2E_TESTS) $(TEST_OUTPUT)
66+
@./node_modules/.bin/mocha --exit --timeout 120000 --ui exports $(TEST_REPORTER) $(E2E_TESTS) $(TEST_OUTPUT)
6767

6868
define release
6969
NEXT_VERSION=$(shell node -pe 'require("semver").inc("$(VERSION)", "$(1)")')

README.md

Lines changed: 2 additions & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -63,7 +63,7 @@ Using Alpine Linux? Check out the [docs](https://github.com/Blizzard/node-rdkafk
6363
Windows build **is not** compiled from `librdkafka` source but it is rather linked against the appropriate version of [NuGet librdkafka.redist](https://www.nuget.org/packages/librdkafka.redist/) static binary that gets downloaded from `https://globalcdn.nuget.org/packages/librdkafka.redist.1.9.2.nupkg` during installation. This download link can be changed using the environment variable `NODE_RDKAFKA_NUGET_BASE_URL` that defaults to `https://globalcdn.nuget.org/packages/` when it's no set.
6464

6565
Requirements:
66-
* [node-gyp for Windows](https://github.com/nodejs/node-gyp#on-windows) (the easies way to get it: `npm install --global --production windows-build-tools`, if your node version is 6.x or below, please use `npm install --global --production windows-build-tools@3.1.0`)
66+
* [node-gyp for Windows](https://github.com/nodejs/node-gyp#on-windows)
6767

6868
**Note:** I _still_ do not recommend using `node-rdkafka` in production on Windows. This feature was in high demand and is provided to help develop, but we do not test against Windows, and windows support may lag behind Linux/Mac support because those platforms are the ones used to develop this library. Contributors are welcome if any Windows issues are found :)
6969

@@ -267,7 +267,7 @@ To see the configuration options available to you, see the [Configuration](#conf
267267
|`producer.beginTransaction(callback)`| Starts a new transaction. |
268268
|`producer.sendOffsetsToTransaction(offsets, consumer, timeout, callback)`| Sends consumed topic-partition-offsets to the broker, which will get committed along with the transaction. |
269269
|`producer.abortTransaction(timeout, callback)`| Aborts the ongoing transaction. |
270-
|`producer.commitTransaction(timeout, callback)`| Commits the ongoing transaction. |
270+
|`producer.commitTransaction(timeout, callback)`| Commits the ongoing transaction. |
271271

272272
##### Events
273273

binding.gyp

Lines changed: 3 additions & 3 deletions
Original file line numberDiff line numberDiff line change
@@ -43,7 +43,7 @@
4343
}
4444
],
4545
'cflags_cc' : [
46-
'-std=c++14'
46+
'-std=c++17'
4747
],
4848
'msvs_settings': {
4949
'VCLinkerTool': {
@@ -122,7 +122,7 @@
122122
'OS=="linux"',
123123
{
124124
'cflags_cc' : [
125-
'-std=c++14'
125+
'-std=c++17'
126126
],
127127
'cflags_cc!': [
128128
'-fno-rtti'
@@ -140,7 +140,7 @@
140140
],
141141
'OTHER_CPLUSPLUSFLAGS': [
142142
'-I/usr/local/opt/openssl/include',
143-
'-std=c++14'
143+
'-std=c++17'
144144
],
145145
},
146146
}

0 commit comments

Comments
 (0)