Skip to content

Commit 28f1f51

Browse files
authored
Merge pull request #62 from splunk/release/0.11.0
Release 0.11.0
2 parents 0eba3cb + 769469f commit 28f1f51

16 files changed

+281
-170
lines changed

.github/workflows/release.yml

Lines changed: 20 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -0,0 +1,20 @@
1+
name: Create Release
2+
on:
3+
release:
4+
types: [published]
5+
jobs:
6+
build:
7+
name: Create Release
8+
runs-on: ubuntu-latest
9+
steps:
10+
- uses: actions/checkout@v2
11+
# Setup .npmrc file to publish to npm
12+
- uses: actions/setup-node@v1
13+
with:
14+
node-version: '14.0'
15+
registry-url: 'https://registry.npmjs.org'
16+
- run: npm install
17+
# Publish to npm
18+
- run: npm publish
19+
env:
20+
NODE_AUTH_TOKEN: ${{ secrets.NPM_TOKEN }}

.github/workflows/test.yml

Lines changed: 37 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -0,0 +1,37 @@
1+
# This workflow will do a clean install of node dependencies, build the source code and run tests across different versions of node
2+
# For more information see: https://help.github.com/actions/language-and-framework-guides/using-nodejs-with-github-actions
3+
4+
name: Node.js CI
5+
6+
on:
7+
[push, pull_request]
8+
9+
jobs:
10+
test-execution:
11+
runs-on: ubuntu-latest
12+
strategy:
13+
matrix:
14+
node-version:
15+
- "14.0"
16+
- "10.0"
17+
splunk-version:
18+
- latest
19+
- "8.0"
20+
services:
21+
splunk:
22+
image: splunk/splunk:${{matrix.splunk-version}}
23+
env:
24+
SPLUNK_START_ARGS: --accept-license
25+
SPLUNK_PASSWORD: changed!
26+
ports:
27+
- 8088:8088
28+
- 8089:8089
29+
steps:
30+
- uses: actions/checkout@v2
31+
- name: Use Node.js ${{ matrix.node-version }}
32+
uses: actions/setup-node@v2
33+
with:
34+
node-version: ${{ matrix.node-version }}
35+
- run: npm install
36+
- name: Test Execution
37+
run: npm test

.jshintrc

Lines changed: 1 addition & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -34,6 +34,7 @@
3434
"es5" : false, // Allow EcmaScript 5 syntax.
3535
"strict" : false, // Require `use strict` pragma in every file.
3636
"globalstrict" : false, // Allow global "use strict" (also enables 'strict').
37+
"esversion" : 6,
3738

3839

3940
// The Good Parts.

.travis.yml

Lines changed: 0 additions & 39 deletions
This file was deleted.

CHANGELOG.md

Lines changed: 14 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -1,5 +1,19 @@
11
# Splunk logging for JavaScript
22

3+
## v0.11.0
4+
5+
### New features & APIs
6+
7+
* Replaced client implementation to use `needle` in lieu of deprecated `request`
8+
* Replaced client implementation to use `nyc` in lieu of deprecated `istanbul`
9+
10+
### Minor changes
11+
12+
* Converted CI from Travis to Github Actions and added CD
13+
* Upgrade version of jsdoc to 3.6.7.
14+
* Upgrade version of jshint to 2.12.0.
15+
* Upgrade version of mocha to 8.4.0.
16+
317
## v0.10.1
418

519
### Minor changes

CREDITS.md

Lines changed: 7 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -0,0 +1,7 @@
1+
# Third-party software credits
2+
3+
Some of the components included in the Splunk logging for JavaScript are licensed under free or open source licenses. We wish to thank the contributors to those projects.
4+
5+
| Contributor | Description | License |
6+
|:----------- |:----------- |:------- |
7+
| [needle](https://github.com/tomas/needle) | Node.js http client | [MIT](https://github.com/splunk/splunk-javascript-logging/blob/master/licenses/LICENSE-NEEDLE) |

Makefile

Lines changed: 47 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -0,0 +1,47 @@
1+
# text reset
2+
NO_COLOR=\033[0m
3+
# green
4+
OK_COLOR=\033[32;01m
5+
# red
6+
ERROR_COLOR=\033[31;01m
7+
# cyan
8+
WARN_COLOR=\033[36;01m
9+
# yellow
10+
ATTN_COLOR=\033[33;01m
11+
12+
ROOT_DIR := $(shell git rev-parse --show-toplevel)
13+
14+
VERSION := `git describe --tags --dirty 2>/dev/null`
15+
COMMITHASH := `git rev-parse --short HEAD 2>/dev/null`
16+
DATE := `date "+%FT%T%z"`
17+
18+
.PHONY: all
19+
all: init test
20+
21+
init:
22+
@echo "$(ATTN_COLOR)==> init $(NO_COLOR)"
23+
24+
.PHONY: test
25+
test:
26+
@echo "$(ATTN_COLOR)==> test $(NO_COLOR)"
27+
@npm test
28+
29+
.PHONY: test_specific
30+
test_specific:
31+
@echo "$(ATTN_COLOR)==> test_specific $(NO_COLOR)"
32+
@sh ./scripts/test_specific.sh
33+
34+
.PHONY: up
35+
up:
36+
@echo "$(ATTN_COLOR)==> up $(NO_COLOR)"
37+
@docker-compose up -d
38+
39+
.PHONY: wait_up
40+
wait_up:
41+
@echo "$(ATTN_COLOR)==> wait_up $(NO_COLOR)"
42+
@for i in `seq 0 180`; do if docker exec -it splunk /sbin/checkstate.sh &> /dev/null; then break; fi; printf "\rWaiting for Splunk for %s seconds..." $$i; sleep 1; done
43+
44+
.PHONY: down
45+
down:
46+
@echo "$(ATTN_COLOR)==> down $(NO_COLOR)"
47+
@docker-compose stop

README.md

Lines changed: 3 additions & 3 deletions
Original file line numberDiff line numberDiff line change
@@ -1,13 +1,13 @@
11
# Splunk logging for JavaScript
22

3-
#### Version 0.10.1
3+
#### Version 0.11.0
44

55
This project provides a simple JavaScript interface for logging to HTTP Event Collector in Splunk Enterprise and Splunk Cloud.
66

77
## Requirements
88

9-
* Node.js v4 or later.
10-
* Splunk Enterprise 6.3.0 or later, or Splunk Cloud.
9+
* Node.js v4 or later. Splunk logging for Javascript is tested with Node.js v10.0 and v14.0.
10+
* Splunk Enterprise 6.3.0 or later, or Splunk Cloud. Splunk logging for Javascript is tested with Splunk Enterprise 8.0 and 8.2.0.
1111
* An HTTP Event Collector token from your Splunk Enterprise server.
1212

1313
## Installation

docker-compose.yml

Lines changed: 18 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -0,0 +1,18 @@
1+
version: '3.8'
2+
3+
services:
4+
splunk:
5+
image: "splunk/splunk:latest"
6+
container_name: splunk
7+
environment:
8+
- SPLUNK_START_ARGS=--accept-license
9+
- SPLUNK_PASSWORD=changed!
10+
ports:
11+
- 8000:8000
12+
- 8088:8088
13+
- 8089:8089
14+
healthcheck:
15+
test: ['CMD', 'curl', '-f', 'https://localhost:8000']
16+
interval: 5s
17+
timeout: 5s
18+
retries: 20

licenses/LICENSE-NEEDLE

Lines changed: 19 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -0,0 +1,19 @@
1+
Copyright (c) Fork, Ltd.
2+
3+
Permission is hereby granted, free of charge, to any person obtaining a copy
4+
of this software and associated documentation files (the "Software"), to deal
5+
in the Software without restriction, including without limitation the rights
6+
to use, copy, modify, merge, publish, distribute, sublicense, and/or sell
7+
copies of the Software, and to permit persons to whom the Software is
8+
furnished to do so, subject to the following conditions:
9+
10+
The above copyright notice and this permission notice shall be included in
11+
all copies or substantial portions of the Software.
12+
13+
THE SOFTWARE IS PROVIDED "AS IS", WITHOUT WARRANTY OF ANY KIND, EXPRESS OR
14+
IMPLIED, INCLUDING BUT NOT LIMITED TO THE WARRANTIES OF MERCHANTABILITY,
15+
FITNESS FOR A PARTICULAR PURPOSE AND NONINFRINGEMENT. IN NO EVENT SHALL THE
16+
AUTHORS OR COPYRIGHT HOLDERS BE LIABLE FOR ANY CLAIM, DAMAGES OR OTHER
17+
LIABILITY, WHETHER IN AN ACTION OF CONTRACT, TORT OR OTHERWISE, ARISING FROM,
18+
OUT OF OR IN CONNECTION WITH THE SOFTWARE OR THE USE OR OTHER DEALINGS IN
19+
THE SOFTWARE.

0 commit comments

Comments
 (0)