Skip to content

Commit 3c92f13

Browse files
authored
chore: update to latest js-ipfs (#17)
- Updates all deps and refactors to async/await js-ipfs - Adds clone concurrency control to clone with cluster workers
1 parent aae2460 commit 3c92f13

Some content is hidden

Large Commits have some content hidden by default. Use the searchbox below for content that may be hidden.

67 files changed

+58883
-25098
lines changed

.travis.yml

Lines changed: 7 additions & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -5,8 +5,14 @@ stages:
55
- test
66
- cov
77

8+
branches:
9+
only:
10+
- master
11+
- /^release\/.*$/
12+
813
node_js:
9-
- '10'
14+
- 'lts/*'
15+
- 'node'
1016

1117
os:
1218
- linux

docker-compose.yml

Lines changed: 1 addition & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -57,6 +57,7 @@ services:
5757
- STORE_S3_PATH=replication-master
5858
- FOLLOW_SEQ_FILE=seq.txt
5959
- CLONE_DELAY=30000
60+
- CLONE_CONCCURRENCY=0
6061
- FOLLOW_CONCURRENCY=5
6162
- REQUEST_CONCURRENCY=5
6263
logging:

package-lock.json

Lines changed: 5043 additions & 23886 deletions
Some generated files are not rendered by default. Learn more about customizing how changed files appear on GitHub.

package.json

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -4,7 +4,7 @@
44
"description": "Install your dependencies from IPFS",
55
"scripts": {
66
"postinstall": "lerna bootstrap --ci",
7-
"reset": "lerna run --parallel clean && rm -rf packages/*/node_modules packages/*/package-lock.json && rm -rf node_modules package-lock.json && npm i --ignore-scripts && lerna bootstrap",
7+
"reset": "lerna run --parallel clean && rm -rf packages/*/node_modules && rm -rf node_modules && npm i --ignore-scripts && lerna bootstrap",
88
"test": "lerna run --parallel test",
99
"test:node": "lerna run --parallel test",
1010
"coverage": "lerna run --parallel coverage",
Lines changed: 14 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -0,0 +1,14 @@
1+
'use strict'
2+
3+
const AbortController = require('abort-controller')
4+
5+
module.exports = function (request, response, next) {
6+
const controller = new AbortController()
7+
response.locals.signal = controller.signal
8+
9+
request.on('aborted', () => {
10+
controller.abort()
11+
})
12+
13+
next()
14+
}

packages/common/handlers/index.js

Lines changed: 1 addition & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -1,6 +1,7 @@
11
'use strict'
22

33
module.exports = {
4+
abortableRequest: require('./abortable-request'),
45
errorLog: require('./error-log'),
56
requestLog: require('./request-log'),
67
favicon: require('./favicon'),

0 commit comments

Comments
 (0)