Skip to main content

Notebook execution

Notebook execution lets an authenticated Workspace user edit a notebook, start a personal Jupyter Server, run cells on a remote Spark kernel, inspect output, save the document, and manage compute lifecycle.

See Architecture for state and component boundaries, Live evidence for reproducible scenarios, and Notebook execution components for implementation references.

Assessment scope​

FieldValue
ActorsAuthenticated notebook user, workspace administrator, and platform operator
Product validationNot yet recorded
Components assessedsparqd/oqullus, sparqd/bff-api, sparqd/workspace-file-management-backend, sparqd/platform-stacks, JupyterHub, Jupyter Server, Enterprise Gateway, Spark Operator, and Kubernetes
Assessed environmentRealm gj76anadpsc; workspace w-t5e2kcxjd; Kubernetes context dev-north-alicloud
Source baselineOqullus 363355f968fe; BFF API 93ea18e72414; Workspace file backend a6c5eb793e6b; platform-stacks a71390d12463
Focused credential baselineBFF API 0ac008a4c581; platform-stacks 0904a8417f05
Last verifiedGeneral assessment: 4 September 2026; credential path: 8 September 2026; Maven cache and internal database reachability: 9 September 2026
Trackingplatform-docs #39; component validation is not recorded

This assessment covers server, session, kernel, connection, Spark runtime, cell execution, refresh, multiple tabs, kernel operations, cancellation, output, save, history, conflict, idle culling, gateway recovery, authorization, credential propagation, Maven dependency resolution, internal-service network reachability, observability, and performance boundaries.

The separate JupyterLab interface, local Python kernels, providers other than the reviewed AliCloud Enterprise Gateway path, and unauthorized production-data testing are excluded. This assessment did not execute destructive kernel or cluster fault injection and did not benchmark Spark.

Current capability boundary​

CapabilitySource-backed stateDeployment evidence
Open and edit a notebookWorkspace restores tab and file metadata and loads the notebook documentAvailable in the assessed workspace; refresh can lose live runtime association
Start and stop the personal serverUI and BFF route JupyterHub server lifecycleDeployed; detailed start, stop, failure, and unreachable states are not preserved end to end
Create or reuse a notebook sessionUI lists Jupyter sessions and matches the notebook path before creating oneSource-verified; canonical identity and concurrent recovery remain open
Direct kernel pathSource can create a kernel without a persisted notebook sessionSource-backed; it has no durable notebook-session identity and must not be presented as notebook recovery
Run Spark cellsPer-user Jupyter Server delegates to Enterprise Gateway, which launches a SparkApplicationDeployed AliCloud path; one approved Spark kernel type is configured
Resolve Maven packagesSpark Operator resolves requested coordinates before creating the driverOne PostgreSQL JDBC coordinate live-verified; controller-local cache operations remain conditional
Reach platform data servicesGoverned service interfaces are the intended pathA Spark driver could directly reach an internal PostgreSQL service; default-deny egress is not established
Interrupt executionCell cancellation invokes kernel interrupt with a bounded local fallbackSource-verified; deployed completion and retained-state evidence pending
Restart or shut down one kernelUnderlying lifecycle operations existIncomplete UI: visible toolbar controls are inert and the full Kernel menu is disabled
Render outputBasic stream, result, display, error, reply, and status messages are handledAdvanced message compatibility and output limits are not established
Save and recover document contentCode and output changes mark the notebook dirty; accepted saves create object versions and historyHappy paths exist; tab targeting, failure truthfulness, conflict detection, size, and retention are open
Recover after refresh or disconnectLazy exact-path session lookup runs when another execution needs a kernelDeployed refresh state loss observed; deterministic reattachment is incomplete
Recover JupyterHubHub replacement preserved the personal server and SparkApplication and restored the server recordOqullus falsely changed to stopped after two temporary 503s and required refresh; kernel-memory, proxy, and database checks remain
Recover Enterprise GatewayStandalone availability persists remote-kernel connection metadata across gateway replacementOne-replica topology deployed; controlled replacement and client recovery pending
Release idle computeJupyterHub and Enterprise Gateway use a shared 1,800-second idle policyCurrent configuration source-verified; full idle and orphan-cleanup evidence pending

Critical journeys​

JourneyRequired result
Start and executeCreate one authorized server, session, kernel, and Spark runtime and correlate their identities end to end
Refresh and reconnectReattach to the same live kernel or explicitly report replacement and lost in-memory state
Invalid code and retryShow the exception, return the same kernel to idle, and execute the corrected cell
Unauthorized accessDeny notebook, data, and kernel access without leaking identities, content, or credentials
Interrupt and cancelStop upstream work, preserve prior kernel state, and reach a truthful terminal cell state
Timeout and cullingDistinguish launch timeout, execution duration, idle expiry, and cleanup
Kernel or engine failureSeparate reconnecting, dead, restarted, and replaced states without automatically rerunning code
Large or partial outputStay responsive, enforce limits, and label incomplete output truthfully
Multiple cells and tabsShare one runtime state, queue deterministically, and prevent one tab from destroying another's work
Save and recoverSave the correct document once, retain errors, reject stale writes, and restore through history
Hub control-plane interruptionKeep existing servers and kernels alive, preserve healthy proxy routes, report unavailable controls, and reconcile state without duplicates
Gateway replacementPermit a visible interruption, then reconnect to the same surviving remote kernel without duplicates or orphans
Package-bearing kernel startResolve approved coordinates through a bounded controller cache and surface repository or capacity failures
Internal data-service accessPermit governed APIs and approved external data targets while denying direct platform-database connections

Findings​

Use this table as the assessment register. Components identifies involved repositories and runtime systems, not people or teams. Each linked finding contains the observed case, expected condition, alternatives, component work, reproduction, closure conditions, and blockers.

IDFindingComponentsEvidenceImpact
ARCH-NB-001Recover notebooks by canonical session identitysparqd/oqullus, Jupyter ServerSource-verifiedMedium
ARCH-NB-002Model kernel and Spark readiness once per runtimesparqd/oqullus, Jupyter Server, Enterprise Gateway, SparkDeployed inconsistency + sourceHigh
GOV-NB-001Enforce and observe connected-idle kernel cullingsparqd/platform-stacks, JupyterHub, Enterprise Gateway, SparkSource configuration + prior operational observationHigh cost exposure
PERF-NB-001Bound notebook save size, rate, and retentionsparqd/oqullus, sparqd/bff-api, sparqd/workspace-file-management-backendSource-verified; scale pendingMedium
PROD-NB-001Expose complete notebook kernel controlssparqd/oqullus, Jupyter kernel APIsSource-verifiedMedium
REL-NB-001Restore the active kernel after refreshsparqd/oqullus, Jupyter runtime dependenciesDeployed observation + sourceHigh
REL-NB-002Define the supported Jupyter message contractsparqd/oqullus, sparqd/bff-api, Jupyter protocolSource-verifiedMedium
REL-NB-003Surface kernel death and state losssparqd/oqullus, sparqd/bff-api, Jupyter Server, Enterprise GatewaySource-verified; controlled crash pendingHigh
REL-NB-004Scope autosave state to each notebooksparqd/oqullusSource-verifiedCritical
REL-NB-005Keep failed saves visible and retryablesparqd/oqullus, Workspace file APISource-verifiedCritical
REL-NB-006Reject stale concurrent notebook savessparqd/workspace-file-management-backend, sparqd/oqullus, BFF APISource-verifiedHigh
REL-NB-007Preserve authoritative user-server statesparqd/bff-api, sparqd/oqullus, JupyterHubSource-verifiedHigh
REL-NB-008Guarantee terminal state for every cell executionsparqd/oqullus, sparqd/bff-apiSource-verified; fault injection pendingHigh
REL-NB-009Validate standalone Enterprise Gateway recoverysparqd/platform-stacks, Enterprise Gateway, sparqd/bff-api, sparqd/oqullusSource + deployed topology; recovery pendingOperational boundary
REL-NB-010Recover truthfully across JupyterHub control-plane interruptionsparqd/platform-stacks, JupyterHub, proxy, PostgreSQL, sparqd/bff-api, sparqd/oqullusLive Hub replacement: runtime survived; Oqullus false-stopped and required refreshOperational boundary + high client reliability impact
REL-NB-011Operate bounded Maven dependency resolutionsparqd/platform-stacks, Spark Operator, Enterprise Gateway, Maven repositoriesPostgreSQL JDBC coordinate and controller cache live-verifiedHigh
SEC-NB-001Verify identity and kernel ownership on WebSocket upgradesparqd/bff-api, JupyterHub, Jupyter ServerSource-verified; security validation pendingCritical
SEC-NB-002Notebook code can read injected credentials through os.getenv() or printenvsparqd/bff-api, sparqd/platform-stacks, JupyterHub, Enterprise Gateway, Keycloak, OpenBaoCredential propagation source-verified; safe deployed presence check pendingCritical
SEC-NB-003Restrict notebook workloads from platform-owned databasessparqd/platform-stacks, Kubernetes networking, JupyterHub, Enterprise Gateway, Spark workloadsDriver-to-internal-PostgreSQL TCP connection live-verified; JDBC result user-reportedHigh
UX-NB-001Separate closing a view from shutting down computesparqd/oqullus, Jupyter ServerSource-verifiedHigh
UX-NB-002Make Save, Discard, and Cancel truthfulsparqd/oqullusSource-verifiedHigh

Findings are observations, not accepted remediation commitments. Missing evidence remains open, and severity and disposition require review.

Implementation subissues​

FindingIssueFindingIssue
ARCH-NB-001, REL-NB-001oqullus #519ARCH-NB-002oqullus #520
SEC-NB-001bff-api #229REL-NB-007bff-api #228, then oqullus #516
REL-NB-002oqullus #521REL-NB-003, REL-NB-008oqullus #517
PROD-NB-001, UX-NB-001oqullus #522REL-NB-004, REL-NB-005, UX-NB-002oqullus #518
REL-NB-006workspace-file-management-backend #18, then oqullus #523GOV-NB-001project-management #1349
PERF-NB-001bff-api #230, workspace-file-management-backend #19, oqullus #524REL-NB-009Evidence only; open remediation only after failed gateway continuity or an approved availability objective
REL-NB-010oqullus #516 for confirmed false-stopped recoveryREL-NB-010 proxy/database exercisesEvidence only until a failed exercise or approved availability objective
REL-NB-011platform-stacks #692, implemented by platform-stacks #693SEC-NB-003Evidence recorded; remediation issue not opened

Boundaries and interim workarounds​

  • Save notebook content before refresh and expect to rerun initialization cells until canonical runtime restoration is implemented.
  • Do not interpret an open tab, connected channel, or visible kernel indicator as proof that the original kernel and namespace remain alive.
  • Avoid simultaneous editing from multiple contexts; history can recover an overwrite only after it is discovered.
  • Stay on the notebook that changed until save completes, and verify persistence after any network or service error.
  • Avoid unbounded stream or rich output and clear unnecessary output before saving.
  • Use cell interrupt for a running cell. Treat Stop Server as affecting every notebook on the personal server.
  • Do not use inert restart controls. Hide them until their operation, scope, confirmation, and failure state are complete.
  • Treat closing the final tab as potentially destructive until Close and Close and Shut Down are separate actions.
  • Retain the current standalone Enterprise Gateway design for the expected workspace size unless a capacity measurement or availability objective requires replication. A controlled restart must still prove recovery.
  • Retain the current single Hub and proxy while workspace capacity remains within a measured envelope. Existing servers are configured to survive Hub shutdown, but login, spawn, proxy, and database continuity still require a controlled exercise.
  • Detect idle and orphan Spark workloads through server-side metrics and alerts, not browser polling.
  • Treat the controller Ivy cache as bounded pod-local state. Monitor it and expect a cold cache after controller replacement.
  • Use governed data services rather than direct platform-database endpoints from notebooks until default-deny egress is verified.

Assessment maturity​

Scale: 0 absent, 1 ad hoc, 2 partly documented or automated, 3 routinely verified, 4 measured and improving.

LensScoreEvidence-backed assessment
Product and UX1Core execution is available, but refresh, kernel controls, close semantics, and failure feedback remain incomplete.
Architecture and data2Routing and state authorities are mapped; canonical recovery and conflict-safe save identity are incomplete.
Security and privacy1HTTP identity routing exists; kernel-channel token and ownership enforcement needs security validation.
Infrastructure and operations2Idle policy and standalone gateway recovery are configured; replacement, cleanup, telemetry, and recovery are not exercised end to end.
Reliability and performance1Interrupt and save happy paths exist; terminal execution, output, concurrency, reconnect, and scale boundaries lack deployed proof.
Delivery, cost, and lifecycle1Source baselines and idle controls exist; capacity, retained storage, budgets, recovery objectives, and reviewer decisions remain open.