Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

Agent migration stage 2 #535

Merged
merged 27 commits into from
Aug 18, 2023
Merged
Show file tree
Hide file tree
Changes from all commits
Commits
Show all changes
27 commits
Select commit Hold shift + click to select a range
d75c416
feat: `NodeConnection` can now wrap existing `QUICConnection`s
tegefaulkes Aug 7, 2023
fcc3315
feat: moved `QUICServer` into `NodeConnectionManager`
tegefaulkes Aug 8, 2023
b75ec6f
feat: `NodeConnectionManager` handles reverse intimated connections
tegefaulkes Aug 8, 2023
3a12344
tests: fixed node tests
tegefaulkes Aug 9, 2023
8f70698
feat: reimplementing hole punch logic
tegefaulkes Aug 9, 2023
7c3fb75
tests: fixing up tests
tegefaulkes Aug 9, 2023
726005b
tests: fixing up tests
tegefaulkes Aug 9, 2023
d955507
feat: replaced `uws` with `ws`
tegefaulkes Aug 10, 2023
6b39b73
refactor: combined the websocket client and server stream implementation
tegefaulkes Aug 11, 2023
919f3f4
fix: host and port are only set for the https server
tegefaulkes Aug 11, 2023
f7d044b
fix: `WebSocketServer` can now update TLS certs while running
tegefaulkes Aug 11, 2023
da4899c
1.1.4-alpha.0
tegefaulkes Aug 11, 2023
a2c2300
dep: removing `uWebSockets.js`
tegefaulkes Aug 11, 2023
ff10e13
1.1.5-alpha.0
tegefaulkes Aug 11, 2023
ef1ee20
feat: added reverse response message to raw duplex streams
tegefaulkes Aug 14, 2023
09b0923
fix: fixing up vaults agent handlers
tegefaulkes Aug 15, 2023
b8b607e
deps: removed `commander`, `tslib`, `tsyringe`, `@types/nexpect`
CMCDragonkai Aug 15, 2023
1013ca1
chore: added Amy Yan as a contributor
CMCDragonkai Aug 15, 2023
6752fa8
feat: export everything in `index.ts`
CMCDragonkai Aug 16, 2023
08d753f
fix: fixed up network and `NodeConnectionManager` config
CMCDragonkai Aug 15, 2023
63d763c
chore: removed `PK_TEST_COMMAND`, `PK_TEST_PLATFORM`, `PK_TEST_TMPDIR…
CMCDragonkai Aug 16, 2023
b18d187
chore: removed `polykeyStartupTimeout`, as it is no longer used
CMCDragonkai Aug 16, 2023
1ed063c
tests: fixing test configs
tegefaulkes Aug 16, 2023
af4c532
fix: fixing vaults handlers
tegefaulkes Aug 16, 2023
06aef8e
1.1.5-feature-agent-migration-stage2.0
tegefaulkes Aug 16, 2023
72fd7c9
feat: vaults agent handlers are using raw streams now
tegefaulkes Aug 16, 2023
c0fad60
dep: updating `@matrixai/quic` and `@types/node`
tegefaulkes Aug 18, 2023
File filter

Filter by extension

Filter by extension


Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view
28 changes: 0 additions & 28 deletions .env.example
Original file line number Diff line number Diff line change
Expand Up @@ -7,33 +7,5 @@ NODE_ENV=development
# Debug node native modules - https://nodejs.org/api/cli.html#node_debug_nativemodule
# NODE_DEBUG_NATIVE=

# Path to PK executable to override tests/bin target
# PK_TEST_COMMAND=

# If set, indicates that `PK_TEST_COMMAND` is targetting docker
# PK_TEST_COMMAND_DOCKER=
# Accessing AWS for testnet.polykey.io and mainnet.polykey.io deployment
AWS_DEFAULT_REGION='ap-southeast-2'
AWS_ACCESS_KEY_ID=
AWS_SECRET_ACCESS_KEY=

# Path to container registry authentication file used by `skopeo`
# The file has the same contents as `DOCKER_AUTH_CONFIG`
# Use this command to acquire the auth file at `./tmp/auth.json`:
# ```
# printf 'PASSWORD' | skopeo login \
# --username 'USERNAME' \
# --password-stdin \
# $CI_REGISTRY_IMAGE \
# --authfile=./tmp/auth.json
# ```
# REGISTRY_AUTH_FILE=

# Authenticate to GitHub with `gh`
# GITHUB_TOKEN=

# To allow testing different executables in the bin tests
# Both PK_TEST_COMMAND and PK_TEST_PLATFORM must be set at the same time
# PK_TEST_COMMAND= #Specify the shell command we want to test against
# PK_TEST_PLATFORM=docker #Overrides the auto set `testPlatform` variable used for enabling platform specific tests
# PK_TEST_TMPDIR= #Sets the `global.tmpDir` variable to allow overriding the temp directory used for tests
5 changes: 0 additions & 5 deletions jest.config.js
Original file line number Diff line number Diff line change
Expand Up @@ -11,7 +11,6 @@ const moduleNameMapper = pathsToModuleNameMapper(compilerOptions.paths, {

// Global variables that are shared across the jest worker pool
// These variables must be static and serializable
if ((process.env.PK_TEST_PLATFORM != null) !== (process.env.PK_TEST_COMMAND != null)) throw Error('Both PK_TEST_PLATFORM and PK_TEST_COMMAND must be set together.')
const globals = {
// Absolute directory to the project root
projectDir: __dirname,
Expand All @@ -23,13 +22,9 @@ const globals = {
),
// Default asynchronous test timeout
defaultTimeout: 20000,
polykeyStartupTimeout: 30000,
failedConnectionTimeout: 50000,
// Timeouts rely on setTimeout which takes 32 bit numbers
maxTimeout: Math.pow(2, 31) - 1,
testCmd: process.env.PK_TEST_COMMAND,
testPlatform: process.env.PK_TEST_PLATFORM,
tmpDir: path.resolve(process.env.PK_TEST_TMPDIR ?? os.tmpdir()),
};

// The `globalSetup` and `globalTeardown` cannot access the `globals`
Expand Down
70 changes: 22 additions & 48 deletions package-lock.json

Some generated files are not rendered by default. Learn more about how customized files appear on GitHub.

14 changes: 6 additions & 8 deletions package.json
Original file line number Diff line number Diff line change
@@ -1,6 +1,6 @@
{
"name": "polykey",
"version": "1.1.3-alpha.0",
"version": "1.1.5-feature-agent-migration-stage2.0",
"homepage": "https://polykey.io",
"author": "Matrix AI",
"contributors": [
Expand Down Expand Up @@ -30,6 +30,9 @@
},
{
"name": "Emma Casolin"
},
{
"name": "Amy Yan"
}
],
"description": "Polykey Core Library",
Expand Down Expand Up @@ -67,10 +70,10 @@
"@matrixai/errors": "^1.1.7",
"@matrixai/id": "^3.3.6",
"@matrixai/logger": "^3.1.0",
"@matrixai/quic": "^0.0.13",
"@matrixai/resources": "^1.1.5",
"@matrixai/timer": "^1.1.1",
"@matrixai/workers": "^1.3.7",
"@matrixai/quic": "^0.0.16",
"@peculiar/asn1-pkcs8": "^2.3.0",
"@peculiar/asn1-schema": "^2.3.0",
"@peculiar/asn1-x509": "^2.3.0",
Expand All @@ -82,7 +85,6 @@
"ajv": "^7.0.4",
"canonicalize": "^1.0.5",
"cheerio": "^1.0.0-rc.5",
"commander": "^8.3.0",
"cross-fetch": "^3.0.6",
"cross-spawn": "^7.0.3",
"encryptedfs": "^3.5.6",
Expand All @@ -99,9 +101,6 @@
"resource-counter": "^1.2.4",
"sodium-native": "^3.4.1",
"threads": "^1.6.5",
"tslib": "^2.4.0",
"tsyringe": "^4.7.0",
"uWebSockets.js": "github:uNetworking/uWebSockets.js#v20.19.0",
"ws": "^8.12.0"
},
"devDependencies": {
Expand All @@ -110,8 +109,7 @@
"@swc/jest": "^0.2.26",
"@types/cross-spawn": "^6.0.2",
"@types/jest": "^28.1.3",
"@types/nexpect": "^0.4.31",
"@types/node": "^18.11.11",
"@types/node": "^18.15.0",
"@types/pako": "^1.0.2",
"@types/prompts": "^2.0.13",
"@types/readable-stream": "^2.3.11",
Expand Down
Loading