Skip to content

8.3.7.06

Choose a tag to compare

@jcschaff jcschaff released this 02 Dec 08:25
ce78e40

Highlights. A desktop client built from this release, connected to a server that lists the matching feature
groups, uses /api/v2 for sharing, archiving, the documents that use a geometry or field data, and a model's
geometries. Its permissions dialog applies the whole setting in one request, or nothing, and does not overwrite a
change made elsewhere. Publish no longer publishes a model on any server: it explains the curator workflow (make
the version public, archive it, then contact VCell support). DbDriver binds caller-supplied values as parameters in
its user lookup, the rest of the DbDriver family, the model and geometry save path and the legacy /api/v0 BioModel
query, so names containing an apostrophe now save and match correctly. The local viewer server requires a per-session
token, and the installer ships every module of the viewer page. On the server side, /api/v2 gains the plumbing for
Arrow IPC streams and the field-value and mesh DTOs; no data endpoint uses them yet. The desktop now resyncs its event
feed at most once a minute. Legacy API (/api/v0): authorization hardening for the guest account and admin
endpoints; guest tokens are reused (7-day lifetime) instead of issued per request. Two decisions are
recorded: the guest account is to be retired in favour of anonymous access, and the desktop has no RPC fallback for
/api/v2 (D-25; the code follows later). Before deploying, see Notes for API consumers: vcell-rest now refuses to
start outside the dev and test profiles without VCELL_API_CURSOR_KEY, and the desktop installer carries new jars
and a new JVM option.

Added

  • Desktop client, /api/v2 document families (DocumentFamiliesV2Facade, DocumentsClient). Each switch is behind
    its feature group in GET /api/v2/capabilities, read once per session; with no answer, no core area or no group,
    the desktop uses RPC as before. -Dvcell.api.v2.documents=v2|rpc overrides the check. (#2377)
    • documents.access: the permissions dialog reads the access with its ETag when it opens and sends one
      PUT …/access with If-Match; a v2 PUT is never sent without a tag (an untagged setting is read again
      first). 412 is re-read once: a version already as requested is reported as done, otherwise "changed
      elsewhere", nothing changed, and the dialog reopens on a fresh read. 409 document-published, 503 (busy, try
      again), 400/413 (one line per refused name; the dialog reopens) and an unknown outcome (transport failure,
      timeout, other 5xx: "may or may not have been made") each get their own message. A failed access read is
      reported and the dialog does not open. Nothing changed sends nothing, and a shared version becoming private is
      confirmed first. Users hidden from the owner are kept by a shared change, not sent back as members, and not
      compared when checking whether the setting changed (#2384).
    • documents.curation: Archive is PUT …/curation-status archived.
    • documents.references: both reference dialogs (geometry, field data) read every page of
      listGeometryReferencingDocuments / listFieldDataReferencingDocuments (500 a page) as one flat list, and say
      how many versions the owner cannot open. On older servers RPC's graph is flattened the same way
      (ReferencingDocuments).
    • documents.geometries: listBioModelGeometries / listMathModelGeometries replace ModelGeometryOP.
    • Reads fall back to RPC per call only on a transport failure, 5xx or 401; 403 and 404 are final. Sharing
      and archive writes are never repeated over RPC. After a v2 write the v1 summary is read again and replaces the
      cached one; if that read fails, the user is told the change was made and to reconnect. Reads time out after
      15 s, writes after 30 s.
    • UserMetaDbServer gains default methods for the whole-setting access and the flat references, so the server's
      LocalUserMetaDbServer is unchanged. vcell-rest gains vcell-apiclient as a test-scoped dependency only.
  • /api/v2 Arrow plumbing (#2379): Apache Arrow 19.0.0 (arrow-vector, arrow-memory-unsafe), declared by
    vcell-api-mapping, which holds the encoder org.vcell.api.mapping.arrow.ArrowStream (each record batch flushed as
    written, no Arrow buffer compression, end-of-stream marker only after success). In vcell-rest:
    ArrowStreamBodyWriter, BulkRepresentations (Accept negotiation between JSON and Arrow; JSON over
    vcell.api.data.json-max-values, default 100,000, is 413 too-large) and ArrowSettings, which applies the
    off-heap limit vcell.api.data.arrow-max-bytes (default 256 MiB) and logs at startup whether Arrow works in the
    JVM. Arrow memory exhausted before anything is written answers 503 with Retry-After: 10. The Arrow media type
    is added to quarkus.http.compress-media-types (JSON is still not compressed). New problem type too-large (413),
    for a result over a limit, distinct from request-too-large. Two Spectral rules, vcell-arrow-also-offers-json
    and vcell-arrow-is-binary. Only a test resource streams Arrow so far.
  • /api/v2 field values and mesh, DTOs and mappers (#2380): records Mesh, MeshSummary, MeshKind,
    MeshSubdomain, VolumeRegion, MembraneRegion, ElementCenters, MeshVolumeElements, MeshMembraneElements,
    FieldValues, FieldValuesQuery, FunctionDefinition, Particles and ParticleSpecies; mappers MeshMapper
    (a Chombo mesh is refused; a moving-boundary mesh maps as its structure), FieldValuesMapper (the outside-domain and
    Chombo masks, subdomain selection), ParticlesMapper and DatasetInfoMapper.withMesh. DatasetInfo gains
    dimension, origin, extent, lengthUnit and meshes, absent for non-spatial results. JSON element tables are
    column-major. In vcell-core: CartesianMeshFactory (takes a finite-volume CartesianMesh apart and builds it
    back), getters on SubdomainInfo, CartesianMeshMovingBoundary.create and a ParticleDataBlock constructor. No
    endpoint and no data store yet.
  • Hosted field viewer, step V1 (#2378): webapp-viewer/data.js, the page's one data-access module (data origin,
    credential providers, Arrow and JSON by Content-Type, ETag caching, RFC 9457 problems as DataProblem, one
    retry of 503/429 after Retry-After, a legacy route set for today's loopback routes and a v2 route set for
    /api/v2/data/…). viewer.js no longer builds URLs or calls fetch. The data origin may now be the page's own
    origin or an http: loopback origin (&api=, older name &base=). webapp-viewer/grid.js, a port of
    CartesianMeshMapping.fromMeshData that builds today's /grid answer from the mesh tables, not yet called at
    run time. Vendored apache-arrow 21.2.0 (esnext build, Apache-2.0), loaded only when the first Arrow response
    arrives. The viewer keeps using the legacy routes.

Changed

  • Desktop client, Publish: the menu item (database window and listed-model menus) no longer sends RPC's
    owner-publish (B2 PUBLISH), whatever the server. It shows the steps for the selected version: make it public,
    archive it, then contact VCell support (vcell_support@uchc.edu, or Help > Contact VCell Support) with the
    publication's reference and the model's ID. A curator publishes it. The help pages VCellDatabase.md and
    Permissions.md describe the new behaviour. (#2377)
  • Desktop client, permissions dialog on older servers (no documents.access): users added and removed are still
    changed one at a time. A permission refusal before anything changed says "Who may read this version was not
    changed." with the server's reason; one after some changes were made says that not all of the changes were made,
    and the cached summary is read again. (#2384)
  • Desktop client, messages: a refused curation shows the server's message, without a Java class name. The "Make
    private?" confirmation and the Permissions help page say that others lose access within a minute. (#2384)
  • Desktop client, /api/v2 event feed: a resync (reading every cached simulation status again after 410 cursor-expired or 400 invalid-cursor) happens at most once per 60 s (system property
    vcell.api.v2.events.minResyncIntervalSeconds, at most one day). Within the interval the feed still continues from
    the problem's head cursor (or the head) and owes one resync, done at the first poll after the interval; an owed
    resync is carried to a new feed after a reconnect. (#2384)
  • Desktop client, paged /api/v2 lists (referencing documents, listMyJobs / getSimpleJobStatus): on 400 invalid-cursor the list drops the rows read so far and restarts from the first page once; a second refusal fails
    as before. (#2384)
  • vcell-rest, sharing: AccessPolicy.accessChanged, called after a PUT …/access that changed the setting commits,
    forgets this pod's cached decisions about the version and every decision that can reach through another object's
    access (results, geometries, images), so a revoked share takes effect at once on that pod. Other pods can serve the
    old decision for up to 60 s. A decision loaded across such a change is answered but not kept. (#2384)
  • vcell-rest: CursorKeyCheck (@Startup, in the build with vcell.exporter=false only) refuses to start without
    VCELL_API_CURSOR_KEY outside the dev and test profiles, with a message naming the variable. The exporter build
    and the dev and test profiles keep the logged random-key fallback. (#2384)
  • DbDriver binds caller-supplied values as parameters (#2382):
    • user lookup (DbDriver.getUserFromUserid, used by groupAddUser / groupRemoveUser): userid = ?, the same
      exact, case-sensitive match;
    • savePublicationRep (insert and update) and deletePublicationRep: text bound as strings, year, endnote id and
      wittid as typed numbers, the date as text into the same TO_DATE. A non-numeric endnote id is now refused with
      DataAccessException, as a non-numeric wittid already was;
    • isNameUsed and DictionaryDbDriver's alias searches and removes, binding the escaped form that is stored;
    • ModelGeometryOP: the application name is escaped as stored, and bound;
    • the model and geometry save path's insert value lists (getSQLValueList(..., bindValues), run with
      DbDriver.updateBoundSQL): diagram, species context name and SBML name, membrane voltage name, the SpringSaLaD
      strings of a species context spec, surface class, pixel class, stimulus, geometric region name and size unit,
      filament, subvolume, data symbol and its field data variable. These columns store the raw text as before; a
      missing name is still stored as the text null. The diagram goes through a varchar2_CLOB_update overload that
      takes the bind values;
    • the legacy /api/v0 BioModel query (RestDatabaseService): the owner, the user's own name, the name pattern and
      the saved-date bounds, through a new getBioModelReps(user, conditions, conditionValues, …) overload. Dates are
      parsed strictly (the whole text must be a yyyy/MM/dd date) and a bad one is a 400; the BioModel id from the
      request path is parsed into a KeyValue.
      Stored values and matches are unchanged for ordinary input.
  • The local viewer server (FieldViewerServer) requires a per-session token (#2375):
    • each start draws a new 256-bit token (LoopbackAccess); the URL the desktop opens carries it in the fragment,
      #token=…, and the page sends it as Authorization: Bearer on every data request;
    • the data routes (/health, /info, /grid, /field, /timeseries, /stats, /kymograph, /particles)
      answer 401 without the right token; the page's own files need none;
    • every request must name the server by a loopback Host, or gets 403;
    • Access-Control-Allow-Origin echoes only the server's own loopback origins and, when vcell.fieldViewer.url is
      set, that viewer's origin (no wildcard; Vary: Origin). There is no longer a default developer viewer URL: with
      no page served and no URL set, the results window says the viewer page is missing from the installation;
    • the page stores the token for the API origin it arrived with and sends it only there (#2383);
    • data routes answer only their exact path, so the page's module /grid.js is served as a file, not as /grid
      (#2383).
  • The sampling classes (FvLineSampler, FvMembraneCurve, BodyFittedKymograph, PointSeries, MembraneArc,
    FenicsBundleViews, FenicsFunctions, with KymographLimits and SamplingJson) move from vcell-client's
    org.vcell.client.viz to vcell-core's org.vcell.vis.sampling, so vcell-rest can run them later. Behaviour is
    unchanged. (#2375)
  • Local viewer server: /field and /grid log the time of each stage (StageTimer: source, domain, times, variable,
    mesh, field, encode for /field; source, domain, mesh, encode for /grid; source and vtu on the VTU paths) at
    debug level, or at warn level above 5 s, as /kymograph already does. (#2374)
  • Legacy API (/api/v0): authorization hardening for the guest account and admin endpoints. Browsing is unchanged
    for the guest and for anonymous callers. (#2388)
  • Guest tokens (POST /api/v1/users/guestBearerToken, GuestTokenService): one shared guest token is reused instead
    of a new 30-day vc_apiaccesstoken row per call. New tokens live 7 days and are handed out while more than 3 days
    remain. On a miss, up to 10 stored guest tokens are read, newest expiry first, and the first whose JWT verifies with
    this site's key is reused (UserDbDriver.getReusableApiAccessTokens); a new row is written only when none fits, at
    most once a minute per process. The token in hand is checked against its row every minute. Calls that must read the
    database are limited to vcell.guest-token.max-lookups-per-minute (default 60; over it, 429 with
    Retry-After); calls served from memory are never limited. Existing guest rows are kept; no DDL. (#2388)
  • docker/README.md's /api/v0/admin/jobs example passes an administrator's token. (#2388)

Fixed

  • Names containing an apostrophe: sharing with a user whose name contains one now resolves the user; an application
    name containing one now finds its geometry (ModelGeometryOP, whose lookup compared the raw name with the escaped
    stored one); and model and geometry elements whose names contain one (diagram, SBML name, region, filament,
    stimulus, data symbol and the others listed above) now save. (#2382)
  • BioModel listing on PostgreSQL (getBioModelReps): a page was bound as LIMIT startRow+numRows-1 OFFSET startRow.
    It is now rows startRow to startRow+numRows-1 (1-based, inclusive), as on Oracle. (#2382)
  • Local viewer server: a request path containing a NUL character dropped the connection; it is now a 404. (#2383)

Changed (build and CI)

  • Desktop installer: five new jars on the classpath, arrow-vector-19.0.0, arrow-format-19.0.0,
    arrow-memory-core-19.0.0, arrow-memory-unsafe-19.0.0 and flatbuffers-java-25.2.10, and the JVM option
    --add-opens java.base/java.nio=ALL-UNNAMED in the macOS, Windows64, Linux64 and Linux64-sbmltovcml launchers
    (VCell.install4j), vcell.sh, vcell.bat (which also gains the two --add-exports java.desktop/… options the
    launchers have) and the debug-bridge launcher. The desktop does not use Arrow yet. (#2379)
  • vcell-rest image: --add-opens=java.base/java.nio=ALL-UNNAMED in Dockerfile.jvm's JAVA_DEFAULT_OPTS (the
    deployments replace JAVA_OPTS); also in surefire for vcell-api-mapping and vcell-rest and in quarkus:dev.
    Arrow's newer Jackson, commons-codec and slf4j-api are excluded, so dependencyConvergence holds. (#2379)
  • Installer image: docker/build/Dockerfile-clientgen-dev copies the viewer page's modules data.js and grid.js
    into /vcellclient/webviewer; tests, scripts and package.json stay out. webapp-viewer/scripts/check-installer-files.mjs
    walks the page from index.html and fails when the image would leave out a file the page loads, or ship tests or
    Node files. (#2383)
  • CI: a new webapp-viewer job in ci.yml (not a required check) runs the installer check, npm test (Node 22) and
    the grid parity test against goldens written by vcell-client's GridGoldenWriter, and fails if any test is
    skipped. The browser tests stay a manual step. (#2383)
  • Tests: FieldViewerServerAccessTest and test_session_token.py (#2375, #2383); GridGoldenWriter,
    grid-parity.test.mjs, grid.test.mjs, data.test.mjs and test_data_layer.py (#2378); installer-files.test.mjs
    (#2383); ArrowStreamTest, ArrowStreamResponseTest, BulkRepresentationsTest, RestImageJvmOptionsTest and
    ApiV2ArchitectureTest rule 7 (vcell-rest does not write Arrow streams itself) (#2379); the mapper, JSON and
    desktop-equivalence tests in vcell-api-mapping and CartesianMeshFactoryTest (#2380); DocumentFamiliesV2FacadeTest,
    DocumentFamiliesV2FacadeHttpTest, ReplaceAccessTest, AccessPermissionsChangeTest, PublicationWorkflowTest,
    ListedModelActionsTest and DocumentFamiliesDesktopClientTest (PostgreSQL) (#2377); CallerValueBindingSqlTest,
    ModelSaveBindingSqlTest and BioModelRepsConditionBindingTest (Oracle_IT, Oracle and PostgreSQL),
    RestDatabaseServiceDateTest and a quoted-names round trip in BioModelApiTest (#2382); CursorCodecTest
    startup cases, AccessPolicySqlTest.accessChangedForgetsTheDecisionsItCanChange,
    DocumentAccessResourceTest.aRevokedShareTakesEffectAtOnceOnThisPod, and new cases in V2EventFeedTest,
    V2EventsAndJobsHttpTest, DocumentFamiliesV2FacadeTest and SimulationControllerV2FacadeTest (#2384);
    the legacy API's guest and admin authorization tests, GuestTokenServiceTest, a token-reuse case in
    UsersApiTest, and GuestTokenReuseSqlTest (Oracle_IT, Oracle and PostgreSQL) (#2388).
  • Field values and mesh, step 1, characterization (#2374; tests and fixtures only, no endpoint):
    • FieldAnswers extends DataServerAnswers to D5, D13, D14, D15, D21, D22 and D23, recorded per fixture and job
      under field-answers/ and compared by FieldAnswersTest (Fast; re-record with
      -Dvcell.dataServerAnswers.record=true);
    • new fixtures under cbit/vcell/simdata/fields/: field data (fielddata_1004), a spatial parameter scan
      (scan_1002, two jobs) and a 3D finite-volume run with two membranes, 126,025 volume elements and post-processing
      variables (fv3d_1003); two existing fixtures are also installed on secondary storage;
    • the payload harness FieldPayloadHarness (RPC reply against raw float64, gzip, shuffled gzip and JSON, with
      server and encode times), with FieldPayloadHarnessTest (Fast) and FieldPayloadMeasurementTest (tag
      measurement, selected by no CI group);
    • DevFieldDataMeasurementTest, gated like DevDatabaseCountsTest (tag live-database, selected by no CI group):
      dataset counts by family and element-count distributions on dev, read-only, as vcell_dev only. Not yet run
      against dev. DevDatabaseCountsTest also refuses proxy accounts and a URL that carries credentials;
    • FieldViewerServerStageTimingTest.
  • Docs: round 8 corrections: plan status lines, what is on v2 and what is still RPC-only, the database-families
    design's read-fallback rule and Publish row, the RPC inventory's B2, the hosted viewer and 3D renderer status and
    packaging, field values §6.2, the style guide's feature-group list, three manifest rows, and two RELEASING.md
    prod items: VCELL_SWAGGER_UI_AUDIENCE and the Auth0 callback URLs (#2381). RELEASING.md release-cut step 4,
    check prod's cursor key (#2384). The style guide §2.1, §2.5, §4.1 and §9.3 (too-large vs request-too-large)
    (#2379). database-design-patterns.md "Caller-supplied values in SQL" and INSERT conventions (#2382),
    AccessPolicy's cache limits (#2384), and the guest-token lookup and v0's token checks (#2388). The field values
    and mesh design records step 1's findings (#2374).
  • Decided design (docs only): docs/api-v2-anonymous-access-design.md, retiring the desktop's guest account
    (vcellguest) and its server-issued legacy token in favour of anonymous access. A desktop that is not signed in
    sends no token, uses only endpoints that admit anonymous callers, and makes no /api/v0 calls. The lead architect
    accepted every recommended default (AA-1 to AA-12) on 2026-12-02. The vcellguest row and its data are kept; the
    guest token endpoint is to retire with v0's legacy tokens in Phase 8. Plan D-18 is now partly decided. (#2387)
  • Decision recorded (docs only), plan D-25, 2026-12-02: the desktop has no RPC fallback for /api/v2. It never
    retries a failed v2 call over RPC (transport errors, 5xx or 401, signed in or not), and it does not read
    GET /api/v2/capabilities to choose between v2 and RPC: it uses v2 for every feature that has a v2 endpoint, and
    RPC only for features with no v2 endpoint yet. pyvcell keeps its own capability check, and the capabilities endpoint
    stays on the server. Recorded across the plan, the designs, the style guide §6.3, the RPC inventory and the
    manifest. The desktop code lands later: the desktop in this build still checks capabilities and falls back as
    described above. (#2389)

Notes for API consumers

  • Deployment: the cursor key is now mandatory. vcell-rest (the build with vcell.exporter=false; not the
    exporter) refuses to start without VCELL_API_CURSOR_KEY outside the dev and test profiles. Every site that
    deploys this release on the prod profile needs a sealed key in its rest-secrets, the same on every replica
    (openssl rand -base64 32). dev has one (vcell-fluxcd #72). Stage and prod need one first: stage's is
    committed but not applied, and prod has none. Prod's rest deployment is Recreate with one replica, so a missing
    key is an outage. The remote-instances overlays (prod profile) have no key either; island runs the dev
    profile. See docs/RELEASING.md, release-cut step 4.
  • Arrow (application/vnd.apache.arrow.stream): a /api/v2 bulk-array resource will offer one 200 with both
    application/json and application/vnd.apache.arrow.stream (type: string, format: binary), chosen by Accept.
    JSON is the default (no Accept, a wildcard, or JSON named first, as the generated clients send it); Arrow only
    when asked for with a higher quality, or named before JSON. Neither acceptable is 406. The JSON form over
    100,000 values is 413 too-large, whose detail names the Arrow media type to ask for instead. too-large is
    new in the Problem catalogue: a result or computation over a limit, distinct from request-too-large (a request
    body over the limit). The generated clients read the JSON form; read Arrow raw. No endpoint serves Arrow in this
    build. The desktop maps too-large to DataAccessException.
  • Desktop installer: five new Arrow jars (above) and --add-opens java.base/java.nio=ALL-UNNAMED in every
    launcher. A desktop started by other means (a custom script, an IDE) needs that option once it uses Arrow; the
    vcell-rest image has it in JAVA_DEFAULT_OPTS, and logs at startup when Arrow is not available.
  • Desktop sharing and curation over /api/v2: against a server that lists documents.access,
    documents.curation, documents.references or documents.geometries, the desktop uses GET/PUT …/access
    (with If-Match), PUT …/curation-status, the referencing-documents listings and the document-geometry listings
    instead of RPC; against older servers it behaves as before. Publish now points to VCell support on every
    server: the desktop never sends the owner-publish RPC (B2 PUBLISH); a curator publishes. Ship this desktop to prod
    only with the server release that carries #2351, #2353, #2357 and #2366.
  • Resync rate limit: the desktop's event feed resyncs at most once per 60 s
    (-Dvcell.api.v2.events.minResyncIntervalSeconds), so a server that keeps answering 410 or 400 invalid-cursor
    (replicas with different cursor keys, say) no longer makes every poll re-read every cached status.
  • Spec: DatasetInfo gains the optional dimension, origin, extent, lengthUnit and meshes, with new schemas
    MeshSummary and MeshKind (cartesian, moving-boundary, chombo; accept unknown values) in the Java, Python
    and Angular clients. The served info does not fill them yet. The Problem catalogue text lists too-large. Both
    changes are additive; no /api/v1/ schema changes, and no new endpoint or feature group.
  • Legacy /api/v0 BioModel query: a saved-date bound that is not a whole yyyy/MM/dd date is now a 400.
  • Legacy API and the guest account (#2388): legacy API (/api/v0): authorization hardening for the guest account
    and admin endpoints. Guest tokens are reused (7-day lifetime) instead of issued per request.
    POST /api/v1/users/guestBearerToken can answer 429 with Retry-After when calls that must read the database
    exceed vcell.guest-token.max-lookups-per-minute (default 60); this response is not in tools/openapi.yaml, and
    ordinary use never reaches it. Desktop guests see no change, and older desktops keep working.
  • Configuration (#2388): vcell.guest-token.max-lookups-per-minute (default 60) and
    vcell.guest-token.min-seconds-between-new (default 60), vcell-rest.
  • Deployment (#2387, #2389, in docs/RELEASING.md): desktops must not be deployed against a server older than their
    own version (D-25), and prod's rest.env needs QUARKUS_OIDC_APPLICATION_TYPE=service with its first /api/v2
    release, so an anonymous request to an authenticated /api/v2 endpoint gets 401, not a 302 (dev switched in
    vcell-fluxcd #74).