Skip to content

Commit 069e5ea

Browse files
gitKrystanrunspiredrichgtleoeuclidsrenovate[bot]
authored
Bulk backports to v4-main (3/7 edition) (#9751)
* Add perf info for re-materialization (#9681) * feat: runtime logging activation (#9683) * feat: runtime logging activation * fix bugs * more fixes * fix lint * fix build * fix more lint * nicer names * Fix bug where race condition causes errors during Request refresh (#9685) * Fix bug where race condition causes errors during Request refresh * Fix lint * Lint * feat(cache): add peekRemoteState to cache to view remote state (#9624) * feat(cache): add peekRemoteState to cache to view remote state * fix lint * update comment * commit working state * Add test for getRemoteRelationship * lint fixes * another change to expected docs * prettier fix * Test fixes * feat: add patchRecord util to JSON:API (#9687) * feat: immutable records should show only remote state, make builder types more useful (#9686) * chore: add more tests around edit workflows, make builder types more useful * implement immutable-shows-only-remote-state * fix lint * Fix: support all known http methods (#9689) * fix: support all known http methods * fix: support all known http methods * chore: fixup SchemaRecord readme (#9690) * chore: minor docs fixes * Feat: hasMany linksMode (#9676) * Port ManyArray class from the model package into the store package * Improve the MinimumManager type definition * Relax the json-api validation for hasMany relationships in linksMode * Adds schema record hasMany relationships in sync linksMode * Adds ManyArrayManager to manage hasMany relationship arrays * Adds mutate method to RecordArrayManager * Set the new ManyArrayManager to newly created ManyArrays * Fix hasMany read tests * Adds reloadHasMany method to ManyArrayManager * Adds mutate method to ManyArrayManager * Adds reference stability tests for sync hasMany relationships * Adds reordering hasMany relationship content test * Adds hasMany relationship reload test * Adds hasMany relationship reload tests * General fixes on hasMany tests * Improve logging on JsonApi cache * Update the parent record on a findHasMany operation * cleanup logging and types * fix types a different way * smarter still * fix lint --------- Co-authored-by: Chris Thoburn <runspired@users.noreply.github.com> * fix: make serialize utils smarter (#9692) * fix: make serialize utils smarter * fix lint * chore: add env vars to turbo config (#9693) * docs: small cleanup for SchemaRecord intro (#9694) * feat: SchemaRecord guide * cleanup schema-record * chore: [BREAKING to prior alpha/betas] prepare SchemaRecord for stable, lockdown exports (#9697) * chore: prepare SchemaRecord for stable, lockdown exports * cleanup imports * fix assertion * doc: link to jsonapi.org when referencing * doc: cleanup wording in SchemaRecord README * fix: Don't notify changes for attributes not registered with the schema (#9698) * internal: fixup diagnostic reporting (#9704) * internal: fixup diagnostic reporting * fix exit code * chore: update to pnpm 10 (#9699) * chore: update to pnpm 10 * fix prettier * fixup settings * fixup npmrc * fix lockfile * bump to 10.5.2 * make work with pnpm * add script to warp-drive package * fix patch * fixup no-shadow-rule * chore: fix fastboot test app * fix lock * chore: make diagnostic shutdown safer, use bun for holodeck server (#9705) * refactor diagnostic for safer teardown * make holodeck cleanup appropriately * fix request test and improve diagnostic a little bit * fix more tests * cleanup config * cleanup dependencies for fastboot scenario * fix types * fixup more tests * fixup more tests * dont launch holodeck for main test app (yet) * ensure less noise in CI * some improvements * a new approach * attempt no sync * use internal sync * more cleanup * fix sync * fix install * fix more missing peers * more vite cleanup * fix more tests, make diagnostic easier to launch * disable caching * try something * fix no-cache * fix missing testem * try fastboot again * cleanup * cleanup * try * updated lockfile with new npmrc settings * fixup comment * fixup fastboot * fix prod tests * restore settings * fix deprecation test * make nicer? * keep some changes * fix it * fix newline * dont use turbo * fixup more commands? * maybe * fixup * still use exec * fix scneario * update npmrc text * fix quote mark * fix(deps): update dependency vite to ^5.4.14 (#9666) Co-authored-by: renovate[bot] <29139614+renovate[bot]@users.noreply.github.com> * chore(deps): update dependency globby to ^14.1.0 (#9708) Co-authored-by: renovate[bot] <29139614+renovate[bot]@users.noreply.github.com> * chore(deps): update dependency bun-types to v1.2.4 (#9706) Co-authored-by: renovate[bot] <29139614+renovate[bot]@users.noreply.github.com> * fix(deps): update dependency inflection to ~3.0.2 (#9664) Co-authored-by: renovate[bot] <29139614+renovate[bot]@users.noreply.github.com> * chore(deps): update dependency terser-webpack-plugin to ^5.3.12 (#9710) Co-authored-by: renovate[bot] <29139614+renovate[bot]@users.noreply.github.com> * chore(deps): update node.js to >= 18.20.7 (#9711) Co-authored-by: renovate[bot] <29139614+renovate[bot]@users.noreply.github.com> * fix(deps): update dependency globals to ^15.15.0 (#9715) Co-authored-by: renovate[bot] <29139614+renovate[bot]@users.noreply.github.com> * fix(deps): update dependency rollup to ^4.34.9 (#9716) Co-authored-by: renovate[bot] <29139614+renovate[bot]@users.noreply.github.com> * fix(deps): update dependency semver to ^7.7.1 (#9717) Co-authored-by: renovate[bot] <29139614+renovate[bot]@users.noreply.github.com> * chore(deps): update ember-core (#9719) Co-authored-by: renovate[bot] <29139614+renovate[bot]@users.noreply.github.com> * fix(deps): update dependency debug to ^4.4.0 (#9714) Co-authored-by: renovate[bot] <29139614+renovate[bot]@users.noreply.github.com> * fix(deps): update dependency @ember/optional-features to ^2.2.0 (#9713) Co-authored-by: renovate[bot] <29139614+renovate[bot]@users.noreply.github.com> * fix(deps): update asset-compilation (#9712) Co-authored-by: renovate[bot] <29139614+renovate[bot]@users.noreply.github.com> * chore(deps): update dependency @ember/string to v4.0.1 (#9721) Co-authored-by: renovate[bot] <29139614+renovate[bot]@users.noreply.github.com> * chore(deps): update dependency command-line-args to v6 (#9722) Co-authored-by: renovate[bot] <29139614+renovate[bot]@users.noreply.github.com> * chore(deps): update dependency expect-type to v1 (#9724) Co-authored-by: renovate[bot] <29139614+renovate[bot]@users.noreply.github.com> * chore(deps): update dependency ember-inflector to v5 (#9723) Co-authored-by: renovate[bot] <29139614+renovate[bot]@users.noreply.github.com> * chore(deps): update dependency mocha to v11 (#9726) Co-authored-by: renovate[bot] <29139614+renovate[bot]@users.noreply.github.com> * chore(deps): update dependency rimraf to v6 (#9727) Co-authored-by: renovate[bot] <29139614+renovate[bot]@users.noreply.github.com> * chore(deps): update oven-sh/setup-bun action to v2 (#9729) Co-authored-by: renovate[bot] <29139614+renovate[bot]@users.noreply.github.com> * fix(deps): update dependency ember-cli to v6 (#9733) Co-authored-by: renovate[bot] <29139614+renovate[bot]@users.noreply.github.com> * fix(deps): update build-tools (#9570) Co-authored-by: renovate[bot] <29139614+renovate[bot]@users.noreply.github.com> * fix(deps): update dependency ember-load-initializers to v3 (#9736) Co-authored-by: renovate[bot] <29139614+renovate[bot]@users.noreply.github.com> * fix(deps): update dependency globals to v16 (#9737) Co-authored-by: renovate[bot] <29139614+renovate[bot]@users.noreply.github.com> * Fix metric count data typo * fix(deps): update code-quality (#9571) * fix(deps): update code-quality * dont bump @types/qunit --------- Co-authored-by: renovate[bot] <29139614+renovate[bot]@users.noreply.github.com> Co-authored-by: Chris Thoburn <runspired@users.noreply.github.com> * bump version of tracerbench * chore: add logging to proxy server for debugging * chore: Modernize Performance App (use Vite) (#9707) * stash * stash * cleanup lockfile * more updates to harness * more work on scenarios * add bun log * simplify perf test build * another pass through * turns out we want compat * make easier to debug * turn on verbose logging * try * use string :eyeroll: * exclude more logs * exclude more * add debug mode for chrome * give longer timeout for logging * lets inspect * fix server * update check, reduce logging * fckn finly * chore: update main version of perf checks * chore: fixup vite config for perf (#9744) fixup vite config for perf * feat: new perf scenario for complex records (#9745) * chore: update scenario * chore: remove mixin workaround * More dramatic update for update-with-same-state perf test (#9743) * More dramatic update * Iterate parent of each child * Add big many to many scenario * Tidy up * Enbiggen * chore: bump size of benchmark (#9746) * Actually add the m2m test case to the perf test output (#9748) * Actually add the m2m test case to the perf test output * Update .github/workflows/perf-check.yml --------- Co-authored-by: Chris Thoburn <runspired@users.noreply.github.com> * chore: update perf suite (#9749) * Don't overnotify for updates to added state that match local updates (#9702) * Don't overnotify for updates to added state that match local updates * Fix typo * Tidy up * stash stuffs * Add log counts to replace-related-records * update all the stuffs * fixup log --------- Co-authored-by: Chris Thoburn <runspired@users.noreply.github.com> * Backport tests/main/tsconfig * Remove unneccessary test assertions --------- Co-authored-by: Chris Thoburn <runspired@users.noreply.github.com> Co-authored-by: Rich Glazerman <rglazerman@squareup.com> Co-authored-by: Leo Euclides <leoeuclidss@gmail.com> Co-authored-by: renovate[bot] <29139614+renovate[bot]@users.noreply.github.com>
1 parent 9f8dca3 commit 069e5ea

File tree

227 files changed

+25075
-18938
lines changed

Some content is hidden

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

227 files changed

+25075
-18938
lines changed

.github/actions/setup/action.yml

+6-1
Original file line numberDiff line numberDiff line change
@@ -70,7 +70,7 @@ runs:
7070
node-version-file: 'package.json'
7171
cache: 'pnpm'
7272

73-
- uses: oven-sh/setup-bun@v1
73+
- uses: oven-sh/setup-bun@v2
7474
with:
7575
bun-version: latest
7676

@@ -101,6 +101,11 @@ runs:
101101
sudo apt install libnss3-tools
102102
brew install mkcert
103103
104+
- name: 'Setup DBus for Chrome'
105+
shell: bash
106+
run: |
107+
echo "DBUS_SESSION_BUS_ADDRESS=unix:path=/run/user/1000/bus" >> $GITHUB_ENV
108+
104109
- name: Configure Parallel Builds
105110
if: ${{ inputs.parallel-build == 'true' }}
106111
shell: bash

.github/workflows/compat-tests.yml

+18-12
Original file line numberDiff line numberDiff line change
@@ -54,18 +54,24 @@ jobs:
5454
repo-token: ${{ secrets.GITHUB_TOKEN }}
5555
- name: Run Tests
5656
run: pnpm test:vite
57-
floating-dependencies:
58-
timeout-minutes: 9
59-
runs-on: ubuntu-latest
60-
steps:
61-
- uses: actions/checkout@11bd71901bbe5b1630ceea73d27597364c9af683 # v4
62-
- uses: ./.github/actions/setup
63-
with:
64-
repo-token: ${{ secrets.GITHUB_TOKEN }}
65-
- name: Install dependencies w/o lockfile
66-
run: pnpm install --no-lockfile
67-
- name: Basic Tests
68-
run: pnpm test
57+
###
58+
# This Test No Longer Works Because pnpm install --no-lockfile
59+
# returns exit code 1 whenever there is a lockfile present and
60+
# changes are made to node_modules. This is probably a bug in pnpm.
61+
###
62+
#
63+
# floating-dependencies:
64+
# timeout-minutes: 9
65+
# runs-on: ubuntu-latest
66+
# steps:
67+
# - uses: actions/checkout@11bd71901bbe5b1630ceea73d27597364c9af683 # v4
68+
# - uses: ./.github/actions/setup
69+
# with:
70+
# repo-token: ${{ secrets.GITHUB_TOKEN }}
71+
# - name: Install dependencies w/o lockfile
72+
# run: pnpm install --no-lockfile
73+
# - name: Basic Tests
74+
# run: pnpm test
6975
node-version-test:
7076
name: Use Node.js ${{ matrix.node-version }}
7177
timeout-minutes: 10

.github/workflows/main.yml

+10-2
Original file line numberDiff line numberDiff line change
@@ -174,7 +174,11 @@ jobs:
174174
timeout-minutes: 12
175175
env:
176176
CI: true
177-
run: pnpm test:try-one ${{ matrix.scenario }} -- ember test --test-port=0
177+
run: |
178+
cd tests/main;
179+
pnpm exec ember try:one ${{ matrix.scenario }} --skip-cleanup;
180+
pnpm build:tests;
181+
pnpm run test;
178182
179183
releases:
180184
timeout-minutes: 12
@@ -201,4 +205,8 @@ jobs:
201205
- name: Basic tests with ${{ matrix.release }}
202206
env:
203207
CI: true
204-
run: pnpm test:try-one ${{ matrix.release }} -- ember test --test-port=0
208+
run: |
209+
cd tests/main;
210+
pnpm exec ember try:one ${{ matrix.release }} --skip-cleanup;
211+
pnpm build:tests;
212+
pnpm run test;

.github/workflows/perf-check.yml

+37-6
Original file line numberDiff line numberDiff line change
@@ -53,12 +53,14 @@ jobs:
5353
run: |
5454
BROWSER_FLAGS=$(node ./scripts/perf-tracking/browser-flags.mjs)
5555
echo "BROWSER_FLAGS=$BROWSER_FLAGS" >> $GITHUB_OUTPUT
56-
- uses: tracerbench/tracerbench-compare-action@35f3ab44b512fd2caffbe81adf875ab47272b5b5
56+
#env:
57+
# DEBUG: true
58+
- uses: tracerbench/tracerbench-compare-action@6b56fb774f78e4a85cf02396412b0164870cdab3
5759
with:
58-
experiment-build-command: pnpm install && pnpm --filter performance-test-app exec ember build -e production --output-path dist-experiment --suppress-sizes
59-
experiment-serve-command: pnpm --filter performance-test-app exec ember s --path dist-experiment --port 4201
60-
control-build-command: pnpm install && pnpm --filter performance-test-app exec ember build -e production --output-path dist-control --suppress-sizes
61-
control-serve-command: pnpm --filter performance-test-app exec ember s --path dist-control
60+
experiment-build-command: pnpm --filter performance-test-app build --outDir dist-experiment
61+
experiment-serve-command: pnpm --filter performance-test-app start dist-experiment -p 4201
62+
control-build-command: pnpm --filter performance-test-app build --outDir dist-control
63+
control-serve-command: pnpm --filter performance-test-app start dist-control -p 4200
6264
control-sha: origin/main
6365
sample-timeout: 60
6466
use-pnpm: true
@@ -70,6 +72,16 @@ jobs:
7072
"experiment": "http://localhost:4201/basic-record-materialization",
7173
"markers": "start-data-generation,start-push-payload,start-peek-records,start-record-materialization,end-record-materialization"
7274
},
75+
"complex-record-materialization": {
76+
"control": "http://localhost:4200/complex-record-materialization",
77+
"experiment": "http://localhost:4201/complex-record-materialization",
78+
"markers": "start-data-generation,start-push-payload,start-peek-records,start-record-materialization,end-record-materialization"
79+
},
80+
"complex-record-materialization-with-relationship-materialization": {
81+
"control": "http://localhost:4200/complex-record-materialization-with-relationship-materialization",
82+
"experiment": "http://localhost:4201/complex-record-materialization-with-relationship-materialization",
83+
"markers": "start-data-generation,start-push-payload,start-peek-records,start-record-materialization,start-field-access,start-relationship-access,end-relationship-access"
84+
},
7385
"relationship-materialization-simple": {
7486
"control": "http://localhost:4200/relationship-materialization-simple",
7587
"experiment": "http://localhost:4201/relationship-materialization-simple",
@@ -78,7 +90,7 @@ jobs:
7890
"relationship-materialization-complex": {
7991
"control": "http://localhost:4200/relationship-materialization-complex",
8092
"experiment": "http://localhost:4201/relationship-materialization-complex",
81-
"markers": "start-data-generation,start-push-payload,start-peek-records,start-record-materialization,start-relationship-materialization,end-relationship-materialization"
93+
"markers": "start-data-generation,start-push-payload,start-peek-records,start-record-materialization,start-relationship-materialization,start-push-payload2,start-relationship-materialization2,end-relationship-materialization2"
8294
},
8395
"unload": {
8496
"control": "http://localhost:4200/unload",
@@ -104,11 +116,30 @@ jobs:
104116
"control": "http://localhost:4200/unused-relationships",
105117
"experiment": "http://localhost:4201/unused-relationships",
106118
"markers": "start-push-payload,end-push-payload"
119+
},
120+
"update-with-same-state": {
121+
"control": "http://localhost:4200/update-with-same-state",
122+
"experiment": "http://localhost:4201/update-with-same-state",
123+
"markers": "start-data-generation,start-push-initial-payload,start-peek-records,start-record-materialization,start-relationship-materialization,start-local-removal,start-push-minus-one-payload,start-local-addition,start-push-plus-one-payload,end-push-plus-one-payload"
124+
},
125+
"update-with-same-state-m2m": {
126+
"control": "http://localhost:4200/update-with-same-state-m2m",
127+
"experiment": "http://localhost:4201/update-with-same-state-m2m",
128+
"markers": "start-data-generation,start-push-initial-payload,start-peek-records,start-record-materialization,start-relationship-materialization,start-local-removal,start-push-minus-one-payload,start-local-addition,start-push-plus-one-payload,end-push-plus-one-payload"
107129
}
108130
}
109131
fidelity: 60
110132
upload-traces: true
111133
upload-results: true
134+
# env:
135+
# DEBUG: '*,-babel*,-vite*,-rollup*,-ember*,-broccoli*,-pnpm*,-embroider*,-tree-sync*,-fs-tree-diff*'
136+
# - name: Upload Assets
137+
# if: failure() || success()
138+
# uses: actions/upload-artifact@v4
139+
# with:
140+
# name: built-files
141+
# path: 'tests/performance/dist-*'
142+
# retention-days: 1
112143
- name: Report TracerBench Results
113144
if: failure() || success()
114145
env:

.github/workflows/perf-over-release.yml

+33-7
Original file line numberDiff line numberDiff line change
@@ -45,20 +45,22 @@ jobs:
4545
registry-url: 'https://registry.npmjs.org'
4646
node-version-file: 'package.json'
4747
cache: 'pnpm'
48-
- uses: oven-sh/setup-bun@v1
48+
- uses: oven-sh/setup-bun@v2
4949
with:
5050
bun-version: latest
5151
- name: Get Browser Flags
5252
id: browser-flags
5353
run: |
5454
BROWSER_FLAGS=$(node ./scripts/perf-tracking/browser-flags.mjs)
5555
echo "BROWSER_FLAGS=$BROWSER_FLAGS" >> $GITHUB_OUTPUT
56-
- uses: tracerbench/tracerbench-compare-action@35f3ab44b512fd2caffbe81adf875ab47272b5b5
56+
# env:
57+
# DEBUG: true
58+
- uses: tracerbench/tracerbench-compare-action@6b56fb774f78e4a85cf02396412b0164870cdab3
5759
with:
58-
experiment-build-command: pnpm install && pnpm --filter performance-test-app exec ember build -e production --output-path dist-experiment --suppress-sizes
59-
experiment-serve-command: pnpm --filter performance-test-app exec ember s --path dist-experiment --port 4201
60-
control-build-command: pnpm install && pnpm --filter performance-test-app exec ember build -e production --output-path dist-control --suppress-sizes
61-
control-serve-command: pnpm --filter performance-test-app exec ember s --path dist-control
60+
experiment-build-command: pnpm --filter performance-test-app build --outDir dist-experiment
61+
experiment-serve-command: pnpm --filter performance-test-app start dist-experiment -p 4201
62+
control-build-command: pnpm --filter performance-test-app build --outDir dist-control
63+
control-serve-command: pnpm --filter performance-test-app start dist-control -p 4200
6264
sample-timeout: 60
6365
use-pnpm: true
6466
browser-args: ${{ steps.browser-flags.outputs.BROWSER_FLAGS }}
@@ -69,6 +71,16 @@ jobs:
6971
"experiment": "http://localhost:4201/basic-record-materialization",
7072
"markers": "start-data-generation,start-push-payload,start-peek-records,start-record-materialization,end-record-materialization"
7173
},
74+
"complex-record-materialization": {
75+
"control": "http://localhost:4200/complex-record-materialization",
76+
"experiment": "http://localhost:4201/complex-record-materialization",
77+
"markers": "start-data-generation,start-push-payload,start-peek-records,start-record-materialization,end-record-materialization"
78+
},
79+
"complex-record-materialization-with-relationship-materialization": {
80+
"control": "http://localhost:4200/complex-record-materialization-with-relationship-materialization",
81+
"experiment": "http://localhost:4201/complex-record-materialization-with-relationship-materialization",
82+
"markers": "start-data-generation,start-push-payload,start-peek-records,start-record-materialization,start-field-access,start-relationship-access,end-relationship-access"
83+
},
7284
"relationship-materialization-simple": {
7385
"control": "http://localhost:4200/relationship-materialization-simple",
7486
"experiment": "http://localhost:4201/relationship-materialization-simple",
@@ -77,7 +89,7 @@ jobs:
7789
"relationship-materialization-complex": {
7890
"control": "http://localhost:4200/relationship-materialization-complex",
7991
"experiment": "http://localhost:4201/relationship-materialization-complex",
80-
"markers": "start-data-generation,start-push-payload,start-peek-records,start-record-materialization,start-relationship-materialization,end-relationship-materialization"
92+
"markers": "start-data-generation,start-push-payload,start-peek-records,start-record-materialization,start-relationship-materialization,start-push-payload2,start-relationship-materialization2,end-relationship-materialization2"
8193
},
8294
"unload": {
8395
"control": "http://localhost:4200/unload",
@@ -104,11 +116,25 @@ jobs:
104116
"experiment": "http://localhost:4201/unused-relationships",
105117
"markers": "start-push-payload,end-push-payload"
106118
}
119+
"update-with-same-state-m2m": {
120+
"control": "http://localhost:4200/update-with-same-state-m2m",
121+
"experiment": "http://localhost:4201/update-with-same-state-m2m",
122+
"markers": "start-data-generation,start-push-initial-payload,start-peek-records,start-record-materialization,start-relationship-materialization,start-local-removal,start-push-minus-one-payload,start-local-addition,start-push-plus-one-payload,end-push-plus-one-payload"
123+
}
107124
}
108125
fidelity: 60
109126
control-sha: origin/release
110127
upload-traces: true
111128
upload-results: true
129+
# env:
130+
# DEBUG: '*,-babel*,-vite*,-rollup*,-ember*,-broccoli*,-pnpm*,-embroider*,-tree-sync*,-fs-tree-diff*'
131+
# - name: Upload Assets
132+
# if: failure() || success()
133+
# uses: actions/upload-artifact@v4
134+
# with:
135+
# name: built-files
136+
# path: 'tests/performance/dist-*'
137+
# retention-days: 1
112138
- name: Report TracerBench Results
113139
if: failure() || success()
114140
env:

0 commit comments

Comments
 (0)