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

chore: Greater stability at 1TPS #10981

Merged
merged 57 commits into from
Jan 9, 2025
Merged
Show file tree
Hide file tree
Changes from all commits
Commits
Show all changes
57 commits
Select commit Hold shift + click to select a range
749cf20
WIP
PhilWindle Dec 24, 2024
724a182
WIP
PhilWindle Dec 24, 2024
2038cc5
WIP
PhilWindle Dec 24, 2024
c8bdcdb
WIP
PhilWindle Dec 24, 2024
0c5f63f
WIP
PhilWindle Dec 24, 2024
b231a8c
WIP
PhilWindle Dec 24, 2024
45163a6
WIP
PhilWindle Dec 24, 2024
2c722b4
Fix
PhilWindle Dec 24, 2024
c5f15bd
Fix
PhilWindle Dec 24, 2024
51ddac2
WIP
PhilWindle Dec 24, 2024
e9f4ca3
More WIP
PhilWindle Dec 24, 2024
3b7522e
Fix
PhilWindle Dec 24, 2024
21b6915
WIP
PhilWindle Dec 26, 2024
a01ffb2
WIP
PhilWindle Dec 26, 2024
ebb85b6
WIP
PhilWindle Dec 26, 2024
f5cc8b2
WIP
PhilWindle Dec 26, 2024
f15352f
Set max old space
PhilWindle Dec 28, 2024
e9b8697
Prover broker map size
PhilWindle Dec 28, 2024
832f208
Prover broker map size
PhilWindle Dec 28, 2024
285d684
Fix
PhilWindle Dec 28, 2024
48e5bda
More TPS
PhilWindle Dec 28, 2024
1b53617
Validate block headers
PhilWindle Dec 30, 2024
e2837f8
Updated lmdb version
PhilWindle Dec 31, 2024
32ba085
Merge branch 'master' into pw/ssd
PhilWindle Dec 31, 2024
b30623e
Merge branch 'master' into pw/ssd
PhilWindle Jan 2, 2025
cfb9200
WIP
PhilWindle Jan 3, 2025
af96f0c
Merge branch 'pw/ssd' of github.com:AztecProtocol/aztec-packages into…
PhilWindle Jan 3, 2025
5ff44e0
WIP
PhilWindle Jan 3, 2025
3c77397
WIP
PhilWindle Jan 3, 2025
87701e5
Fixes
PhilWindle Jan 3, 2025
3b63fe7
More broker/facade refactoring
PhilWindle Jan 5, 2025
368f0db
Fix
PhilWindle Jan 5, 2025
f952364
Fixes
PhilWindle Jan 5, 2025
2bec804
Fix
PhilWindle Jan 5, 2025
98a2f24
Serialise proving broker cleanup ops
PhilWindle Jan 6, 2025
977fcb9
Don't start the broker twice
PhilWindle Jan 6, 2025
2b6ca64
Handle starting the broker multiple times
PhilWindle Jan 6, 2025
266ffa8
Cleanup
PhilWindle Jan 7, 2025
e223958
Merge remote-tracking branch 'origin/master' into pw/ssd
PhilWindle Jan 7, 2025
99d8a76
Formatting
PhilWindle Jan 7, 2025
2f1379d
Cleanup
PhilWindle Jan 7, 2025
04312f5
Fixes
PhilWindle Jan 7, 2025
27b15a3
Another attempt
PhilWindle Jan 7, 2025
f61c316
Merge remote-tracking branch 'origin/master' into pw/ssd
PhilWindle Jan 7, 2025
5436239
Merge fixes
PhilWindle Jan 7, 2025
c4a0bf6
Test fixes
PhilWindle Jan 7, 2025
ee01558
Merge branch 'master' into pw/ssd
PhilWindle Jan 7, 2025
086b284
Lock file
PhilWindle Jan 7, 2025
b070521
Don't delete individual jobs
PhilWindle Jan 8, 2025
d28fe4e
Logging
PhilWindle Jan 8, 2025
eaba030
More tests
PhilWindle Jan 8, 2025
ca2d03e
Fixes
PhilWindle Jan 9, 2025
45a441d
Merge remote-tracking branch 'origin/master' into pw/ssd
PhilWindle Jan 9, 2025
cfd0ebd
Cleanup
PhilWindle Jan 9, 2025
eeab53d
Cleanup
PhilWindle Jan 9, 2025
83e47ad
Fixes
PhilWindle Jan 9, 2025
3fc753c
Merge remote-tracking branch 'origin/master' into pw/ssd
PhilWindle Jan 9, 2025
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
60 changes: 30 additions & 30 deletions boxes/yarn.lock
Original file line number Diff line number Diff line change
Expand Up @@ -78,7 +78,7 @@ __metadata:
"@aztec/ethereum": "workspace:^"
"@aztec/foundation": "workspace:^"
idb: "npm:^8.0.0"
lmdb: "npm:^3.0.6"
lmdb: "npm:^3.2.0"
languageName: node
linkType: soft

Expand Down Expand Up @@ -1553,44 +1553,44 @@ __metadata:
languageName: node
linkType: hard

"@lmdb/lmdb-darwin-arm64@npm:3.1.6":
version: 3.1.6
resolution: "@lmdb/lmdb-darwin-arm64@npm:3.1.6"
"@lmdb/lmdb-darwin-arm64@npm:3.2.1":
version: 3.2.1
resolution: "@lmdb/lmdb-darwin-arm64@npm:3.2.1"
conditions: os=darwin & cpu=arm64
languageName: node
linkType: hard

"@lmdb/lmdb-darwin-x64@npm:3.1.6":
version: 3.1.6
resolution: "@lmdb/lmdb-darwin-x64@npm:3.1.6"
"@lmdb/lmdb-darwin-x64@npm:3.2.1":
version: 3.2.1
resolution: "@lmdb/lmdb-darwin-x64@npm:3.2.1"
conditions: os=darwin & cpu=x64
languageName: node
linkType: hard

"@lmdb/lmdb-linux-arm64@npm:3.1.6":
version: 3.1.6
resolution: "@lmdb/lmdb-linux-arm64@npm:3.1.6"
"@lmdb/lmdb-linux-arm64@npm:3.2.1":
version: 3.2.1
resolution: "@lmdb/lmdb-linux-arm64@npm:3.2.1"
conditions: os=linux & cpu=arm64
languageName: node
linkType: hard

"@lmdb/lmdb-linux-arm@npm:3.1.6":
version: 3.1.6
resolution: "@lmdb/lmdb-linux-arm@npm:3.1.6"
"@lmdb/lmdb-linux-arm@npm:3.2.1":
version: 3.2.1
resolution: "@lmdb/lmdb-linux-arm@npm:3.2.1"
conditions: os=linux & cpu=arm
languageName: node
linkType: hard

"@lmdb/lmdb-linux-x64@npm:3.1.6":
version: 3.1.6
resolution: "@lmdb/lmdb-linux-x64@npm:3.1.6"
"@lmdb/lmdb-linux-x64@npm:3.2.1":
version: 3.2.1
resolution: "@lmdb/lmdb-linux-x64@npm:3.2.1"
conditions: os=linux & cpu=x64
languageName: node
linkType: hard

"@lmdb/lmdb-win32-x64@npm:3.1.6":
version: 3.1.6
resolution: "@lmdb/lmdb-win32-x64@npm:3.1.6"
"@lmdb/lmdb-win32-x64@npm:3.2.1":
version: 3.2.1
resolution: "@lmdb/lmdb-win32-x64@npm:3.2.1"
conditions: os=win32 & cpu=x64
languageName: node
linkType: hard
Expand Down Expand Up @@ -8398,16 +8398,16 @@ __metadata:
languageName: node
linkType: hard

"lmdb@npm:^3.0.6":
version: 3.1.6
resolution: "lmdb@npm:3.1.6"
dependencies:
"@lmdb/lmdb-darwin-arm64": "npm:3.1.6"
"@lmdb/lmdb-darwin-x64": "npm:3.1.6"
"@lmdb/lmdb-linux-arm": "npm:3.1.6"
"@lmdb/lmdb-linux-arm64": "npm:3.1.6"
"@lmdb/lmdb-linux-x64": "npm:3.1.6"
"@lmdb/lmdb-win32-x64": "npm:3.1.6"
"lmdb@npm:^3.2.0":
version: 3.2.1
resolution: "lmdb@npm:3.2.1"
dependencies:
"@lmdb/lmdb-darwin-arm64": "npm:3.2.1"
"@lmdb/lmdb-darwin-x64": "npm:3.2.1"
"@lmdb/lmdb-linux-arm": "npm:3.2.1"
"@lmdb/lmdb-linux-arm64": "npm:3.2.1"
"@lmdb/lmdb-linux-x64": "npm:3.2.1"
"@lmdb/lmdb-win32-x64": "npm:3.2.1"
msgpackr: "npm:^1.11.2"
node-addon-api: "npm:^6.1.0"
node-gyp: "npm:latest"
Expand All @@ -8429,7 +8429,7 @@ __metadata:
optional: true
bin:
download-lmdb-prebuilds: bin/download-prebuilds.js
checksum: 10c0/081804f72aab6eb0f712654e3bbb2d454dd455bbfe09f223e10728971f201cfc166d4d6dd6a3099aabf79e4fd62e9c2a5eb9117bd5f2153ec5a419333f69a338
checksum: 10c0/cccf17b95a821c56d3eef87abbdd7c30e4bc3147fbdd1cae44a5ba8f1977dbb3177021cfda9b7e8a293fc53fe78fc81979ce032885b777d3bec556c255c25724
languageName: node
linkType: hard

Expand Down
3 changes: 2 additions & 1 deletion cspell.json
Original file line number Diff line number Diff line change
Expand Up @@ -11,8 +11,8 @@
"asyncify",
"auditability",
"authwit",
"authwits",
"authwitness",
"authwits",
"Automine",
"autonat",
"autorun",
Expand Down Expand Up @@ -125,6 +125,7 @@
"ierc",
"indexeddb",
"initialise",
"initialised",
"initialising",
"interruptible",
"isequal",
Expand Down
5 changes: 5 additions & 0 deletions spartan/aztec-network/templates/_helpers.tpl
Original file line number Diff line number Diff line change
Expand Up @@ -183,3 +183,8 @@ affinity:
topologyKey: "kubernetes.io/hostname"
namespaceSelector: {}
{{- end -}}

{{- define "aztec-network.gcpLocalSsd" -}}
nodeSelector:
cloud.google.com/gke-ephemeral-storage-local-ssd: "true"
{{- end -}}
18 changes: 18 additions & 0 deletions spartan/aztec-network/templates/boot-node.yaml
Original file line number Diff line number Diff line change
Expand Up @@ -11,6 +11,7 @@ spec:
matchLabels:
{{- include "aztec-network.selectorLabels" . | nindent 6 }}
app: boot-node
{{- if not .Values.storage.localSsd }}
volumeClaimTemplates:
- metadata:
name: boot-node-data
Expand All @@ -19,12 +20,16 @@ spec:
resources:
requests:
storage: {{ .Values.bootNode.storageSize }}
{{- end }}
template:
metadata:
labels:
{{- include "aztec-network.selectorLabels" . | nindent 8 }}
app: boot-node
spec:
{{- if .Values.storage.localSsd }}
{{- include "aztec-network.gcpLocalSsd" . | nindent 6 }}
{{- end }}
dnsPolicy: ClusterFirstWithHostNet
{{- if .Values.network.public }}
hostNetwork: true
Expand Down Expand Up @@ -174,6 +179,8 @@ spec:
valueFrom:
fieldRef:
fieldPath: metadata.name
- name: NODE_OPTIONS
value: "--max-old-space-size={{ .Values.bootNode.maxOldSpaceSize}}"
- name: AZTEC_PORT
value: "{{ .Values.bootNode.service.nodePort }}"
- name: LOG_LEVEL
Expand Down Expand Up @@ -220,6 +227,12 @@ spec:
value: {{ .Values.bootNode.viemPollingInterval | quote }}
- name: PEER_ID_PRIVATE_KEY
value: "{{ .Values.bootNode.peerIdPrivateKey }}"
- name: DATA_DIRECTORY
value: "{{ .Values.bootNode.dataDir }}"
- name: DATA_STORE_MAP_SIZE_KB
value: "{{ .Values.storage.dataStoreMapSize }}"
- name: WS_DB_MAP_SIZE_KB
value: "{{ .Values.storage.worldStateMapSize }}"
ports:
- containerPort: {{ .Values.bootNode.service.nodePort }}
- containerPort: {{ .Values.bootNode.service.p2pTcpPort }}
Expand All @@ -232,9 +245,14 @@ spec:
emptyDir: {}
- name: config
emptyDir: {}
{{- if .Values.storage.localSsd }}
- name: boot-node-data
emptyDir: {}
{{ else }}
- name: boot-node-data
persistentVolumeClaim:
claimName: boot-node-data
{{- end }}
{{- if .Values.bootNode.deployContracts }}
- name: scripts
configMap:
Expand Down
41 changes: 39 additions & 2 deletions spartan/aztec-network/templates/prover-broker.yaml
Original file line number Diff line number Diff line change
@@ -1,6 +1,6 @@
{{- if .Values.proverBroker.enabled }}
apiVersion: apps/v1
kind: ReplicaSet
kind: StatefulSet
metadata:
name: {{ include "aztec-network.fullname" . }}-prover-broker
labels:
Expand All @@ -11,13 +11,26 @@ spec:
matchLabels:
{{- include "aztec-network.selectorLabels" . | nindent 6 }}
app: prover-broker
{{- if not .Values.storage.localSsd }}
volumeClaimTemplates:
- metadata:
name: prover-broker-data
spec:
accessModes: [ "ReadWriteOnce" ]
resources:
requests:
storage: {{ .Values.proverBroker.storageSize }}
{{- end }}
template:
metadata:
labels:
{{- include "aztec-network.selectorLabels" . | nindent 8 }}
app: prover-broker
spec:
serviceAccountName: {{ include "aztec-network.fullname" . }}-node
{{- if .Values.storage.localSsd }}
{{- include "aztec-network.gcpLocalSsd" . | nindent 6 }}
{{- end }}
{{- if .Values.network.public }}
hostNetwork: true
dnsPolicy: ClusterFirstWithHostNet
Expand All @@ -26,6 +39,8 @@ spec:
volumes:
- name: config
emptyDir: {}
- name: prover-broker-data
emptyDir: {}
- name: scripts
configMap:
name: {{ include "aztec-network.fullname" . }}-scripts
Expand Down Expand Up @@ -55,6 +70,8 @@ spec:
volumeMounts:
- name: config
mountPath: /shared/config
- name: prover-broker-data
mountPath: {{ .Values.proverBroker.dataDir }}
command:
- "/bin/bash"
- "-c"
Expand All @@ -70,10 +87,14 @@ spec:
valueFrom:
fieldRef:
fieldPath: metadata.name
- name: NODE_OPTIONS
value: "--max-old-space-size={{ .Values.proverBroker.maxOldSpaceSize}}"
- name: AZTEC_PORT
value: "{{ .Values.proverBroker.service.nodePort }}"
- name: LOG_LEVEL
value: "{{ .Values.proverBroker.logLevel }}"
- name: DATA_DIRECTORY
value: "{{ .Values.proverBroker.dataDir }}"
- name: LOG_JSON
value: "1"
- name: PROVER_BROKER_POLL_INTERVAL_MS
Expand All @@ -83,11 +104,27 @@ spec:
- name: PROVER_BROKER_JOB_MAX_RETRIES
value: "{{ .Values.proverBroker.jobMaxRetries }}"
- name: PROVER_BROKER_DATA_DIRECTORY
value: "{{ .Values.proverBroker.dataDirectory }}"
value: "{{ .Values.proverBroker.dataDir }}"
- name: PROVER_BROKER_DATA_MAP_SIZE_KB
value: "{{ .Values.storage.dataStoreMapSize }}"
- name: OTEL_RESOURCE_ATTRIBUTES
value: service.name={{ .Release.Name }},service.namespace={{ .Release.Namespace }},service.version={{ .Chart.AppVersion }},environment={{ .Values.environment | default "production" }}
resources:
{{- toYaml .Values.proverBroker.resources | nindent 12 }}
volumes:
- name: scripts
configMap:
name: {{ include "aztec-network.fullname" . }}-scripts
- name: config
emptyDir: {}
{{- if .Values.storage.localSsd }}
- name: prover-broker-data
emptyDir: {}
{{ else }}
- name: prover-broker-data
persistentVolumeClaim:
claimName: prover-broker-data
{{- end }}
{{- end }}
---
# Headless service for StatefulSet DNS entries
Expand Down
41 changes: 31 additions & 10 deletions spartan/aztec-network/templates/prover-node.yaml
Original file line number Diff line number Diff line change
Expand Up @@ -11,12 +11,25 @@ spec:
matchLabels:
{{- include "aztec-network.selectorLabels" . | nindent 6 }}
app: prover-node
{{- if not .Values.storage.localSsd }}
volumeClaimTemplates:
- metadata:
name: prover-node-data
spec:
accessModes: [ "ReadWriteOnce" ]
resources:
requests:
storage: {{ .Values.proverNode.storageSize }}
{{- end }}
template:
metadata:
labels:
{{- include "aztec-network.selectorLabels" . | nindent 8 }}
app: prover-node
spec:
{{- if .Values.storage.localSsd }}
{{- include "aztec-network.gcpLocalSsd" . | nindent 6 }}
{{- end }}
{{- if .Values.network.public }}
hostNetwork: true
dnsPolicy: ClusterFirstWithHostNet
Expand Down Expand Up @@ -106,6 +119,8 @@ spec:
mountPath: /shared/p2p
- name: config
mountPath: /shared/config
- name: prover-node-data
mountPath: {{ .Values.proverNode.dataDir }}
env:
- name: K8S_POD_UID
valueFrom:
Expand All @@ -119,6 +134,8 @@ spec:
valueFrom:
fieldRef:
fieldPath: status.podIP
- name: NODE_OPTIONS
value: "--max-old-space-size={{ .Values.proverNode.maxOldSpaceSize}}"
- name: AZTEC_PORT
value: "{{ .Values.proverNode.service.nodePort }}"
- name: LOG_LEVEL
Expand Down Expand Up @@ -171,6 +188,12 @@ spec:
value: "{{ .Values.aztec.epochProofClaimWindow }}"
- name: PROVER_VIEM_POLLING_INTERVAL_MS
value: {{ .Values.proverNode.viemPollingInterval | quote }}
- name: DATA_DIRECTORY
value: "{{ .Values.proverNode.dataDir }}"
- name: DATA_STORE_MAP_SIZE_KB
value: "{{ .Values.storage.dataStoreMapSize }}"
- name: WS_DB_MAP_SIZE_KB
value: "{{ .Values.storage.worldStateMapSize }}"
ports:
- containerPort: {{ .Values.proverNode.service.nodePort }}
- containerPort: {{ .Values.proverNode.service.p2pTcpPort }}
Expand All @@ -188,16 +211,14 @@ spec:
emptyDir: {}
- name: config
emptyDir: {}
volumeClaimTemplates:
- metadata:
name: shared-volume
labels:
{{- include "aztec-network.labels" . | nindent 8 }}
spec:
accessModes: ["ReadWriteOnce"]
resources:
requests:
storage: {{ .Values.proverNode.storage }}
{{- if .Values.storage.localSsd }}
- name: prover-node-data
emptyDir: {}
{{ else }}
- name: prover-node-data
persistentVolumeClaim:
claimName: prover-node-data
{{- end }}
{{if not .Values.network.public }}
---
apiVersion: v1
Expand Down
2 changes: 1 addition & 1 deletion spartan/aztec-network/templates/reth.yaml
Original file line number Diff line number Diff line change
Expand Up @@ -143,7 +143,7 @@ spec:
accessModes: ["ReadWriteOnce"]
resources:
requests:
storage: {{ .Values.ethereum.storage }}
storage: {{ .Values.ethereum.storageSize }}
{{- end }}
---
{{ end }}
Loading
Loading