Commit Graph

243 Commits

Author SHA1 Message Date
Tony Garnock-Jones 768fdd6448 Release independent packages
syndicate@0.28.3
syndicate-macros@0.23.2
syndicate-server@0.32.2
syndicate-tools@0.7.1

Generated by cargo-workspaces
2023-10-05 09:57:24 +02:00
Tony Garnock-Jones 1f7b7a02b1 Enable jemalloc feature for simple benchmarking 2023-10-05 09:53:27 +02:00
Tony Garnock-Jones 24b6217897 Make jemalloc optional 2023-10-05 09:47:22 +02:00
Tony Garnock-Jones fc420d1a86 Bump to pick up macro version bump 2023-10-04 23:24:12 +02:00
Tony Garnock-Jones f3e5652eee New release of syndicate-macros to pick up syn feature flag changes 2023-10-04 22:41:17 +02:00
Tony Garnock-Jones 1cb2eba0e4 Release independent packages
syndicate-server@0.32.0

Generated by cargo-workspaces
2023-10-04 21:48:35 +02:00
Tony Garnock-Jones 8dead81cef 50% performance boost from jemalloc! 2023-10-04 21:28:47 +02:00
Tony Garnock-Jones 7d7b3135ba Release independent packages
syndicate@0.28.0
syndicate-macros@0.23.0
syndicate-server@0.31.0
syndicate-tools@0.6.0

Generated by cargo-workspaces
2023-02-10 16:44:38 +01:00
Tony Garnock-Jones 4dca1b1615 More updates to gatekeeper protocol 2023-02-09 00:17:12 +01:00
Tony Garnock-Jones 6ec6bbaf41 Incorporate Step, Description 2023-02-08 22:27:41 +01:00
Tony Garnock-Jones 7e8dcef0e2 Refactor gatekeeper implementation for new protocols. 2023-02-08 18:01:51 +01:00
Tony Garnock-Jones a2013287db Release independent packages
syndicate@0.27.0
syndicate-macros@0.22.0
syndicate-server@0.30.0
syndicate-tools@0.5.0

Generated by cargo-workspaces
2023-02-06 18:15:03 +01:00
Tony Garnock-Jones 7de2752068 Switch to HMAC-BLAKE2s 2023-02-06 17:09:17 +01:00
Tony Garnock-Jones 833be7b293 Update attenuations 2023-02-06 14:48:18 +01:00
Tony Garnock-Jones 9f88765cf7 Release independent packages
syndicate@0.26.2
syndicate-server@0.29.2

Generated by cargo-workspaces
2023-01-31 15:12:12 +01:00
Tony Garnock-Jones 2a11bc6bbb Use bundled bundle, rather than external file, which isn't found in published crate build 2023-01-31 15:11:50 +01:00
Tony Garnock-Jones 1dac3e5a19 Release independent packages
syndicate@0.26.1
syndicate-server@0.29.1

Generated by cargo-workspaces
2023-01-31 14:21:29 +01:00
Tony Garnock-Jones 2382157039 Oops. Wrong dep on preserves-schema 2023-01-31 14:21:18 +01:00
Tony Garnock-Jones 69c526436f Release independent packages
syndicate@0.26.0
syndicate-macros@0.21.0
syndicate-server@0.29.0
syndicate-tools@0.4.0

Generated by cargo-workspaces
2023-01-31 14:13:06 +01:00
Tony Garnock-Jones 4becf23caa Switch from snow to noise-protocol; Noise responder implementation 2023-01-30 17:30:44 +01:00
Tony Garnock-Jones 94040ae566 More ergonomic guard api 2023-01-30 17:29:25 +01:00
Tony Garnock-Jones dbbbc8c1c6 Breaking change: much improved error API 2023-01-30 14:25:58 +01:00
Tony Garnock-Jones f3424c160d Groundwork for handling noise connects 2023-01-28 22:45:48 +01:00
Tony Garnock-Jones fce32a589c Release independent packages
syndicate@0.25.0
syndicate-macros@0.20.0
syndicate-server@0.28.0
syndicate-tools@0.3.0

Generated by cargo-workspaces
2023-01-16 15:05:48 +01:00
Tony Garnock-Jones 25ef92f78e Include syndicate package version in syndicate-server version display 2023-01-09 09:30:46 +01:00
Tony Garnock-Jones eb2bd3cf8e Release independent packages
syndicate@0.24.1
syndicate-macros@0.19.1
syndicate-server@0.27.1
syndicate-tools@0.2.1

Generated by cargo-workspaces
2022-10-26 13:46:28 +02:00
Tony Garnock-Jones 451a298f94 Oops, want independent versioning 2022-10-26 13:45:48 +02:00
Tony Garnock-Jones 2f3b186262 Switch to cargo-workspaces 2022-10-26 13:41:46 +02:00
Tony Garnock-Jones 86347412e7 (cargo-release) version 0.19.0 2022-10-24 15:14:07 +02:00
Tony Garnock-Jones 2d46d87f58 (cargo-release) version 0.27.0 2022-10-24 15:14:07 +02:00
Tony Garnock-Jones 54103f87eb (cargo-release) version 0.24.0 2022-10-24 15:14:06 +02:00
Tony Garnock-Jones 4a6bb3e143 Bump preserves-schema 2022-10-24 15:10:37 +02:00
Tony Garnock-Jones bcaf08c602 (cargo-release) version 0.26.0 2022-07-22 18:14:08 +02:00
Tony Garnock-Jones 9293bd3904 (cargo-release) version 0.25.0 2022-07-22 18:13:24 +02:00
Tony Garnock-Jones ec8ba36d6a Add `stringify` quasi-function 2022-03-01 10:02:30 +01:00
Tony Garnock-Jones ec453b7db7 (cargo-release) version 0.24.0 2022-02-06 23:03:51 +01:00
Tony Garnock-Jones efb76bfe91 Add "never" restart policy 2022-02-06 23:03:21 +01:00
Tony Garnock-Jones d75bfe4e35 (cargo-release) version 0.18.0 2022-02-04 17:00:18 +01:00
Tony Garnock-Jones 393514fb3a (cargo-release) version 0.23.0 2022-02-04 17:00:18 +01:00
Tony Garnock-Jones 406f22703b (cargo-release) version 0.23.0 2022-02-04 17:00:18 +01:00
Tony Garnock-Jones 4f0145e161 Sort directory entries in config scan 2022-02-04 16:59:29 +01:00
Tony Garnock-Jones b09fbdceec Remove hardcoded milestones and system-layer notions 2022-02-04 16:00:15 +01:00
Tony Garnock-Jones 8a0675d8ee (cargo-release) version 0.22.0 2022-02-04 14:02:10 +01:00
Tony Garnock-Jones af2578f887 (cargo-release) version 0.17.0 2022-02-04 14:02:10 +01:00
Tony Garnock-Jones 84ebf530d3 (cargo-release) version 0.22.0 2022-02-04 14:02:10 +01:00
Tony Garnock-Jones f88592282d MAJOR REFACTORING OF CORE ASSERTION-TRACKING STRUCTURES. Little impact on API. Read on for details.
2022-02-01 15:22:30 Two problems.

 - If a stop action panics (in `_terminate_facet`), the Facet is dropped before its outbound
   handles are removed. With the code as it stands, this leaks assertions (!!).

 - The logic for removing an outbound handle seems to be running in the wrong facet context???
   (See `f.outbound_handles.remove(&handle)` in the cleanup actions
    - I think I need to remove the for_myself mechanism
    - and add some callbacks to run only on successful commit

2022-02-02 12:12:33 This is hard.

Here's the current implementation:

 - assert
    - inserts into outbound_handles of active facet
    - adds cleanup action describing how to do the retraction
    - enqueues the assert action, which
       - calls e.assert()

 - retract
    - looks up & removes the cleanup action, which
       - enqueues the retract action, which
          - removes from outbound_handles of the WRONG facet in the WRONG actor
          - calls e.retract()

 - _terminate_facet
    - uses outbound_handles to retract the facet's assertions
    - doesn't directly touch cleanup actions, relying on retract to do that
    - if one of a facet's stop actions panics, will drop the facet, leaking its assertions
    - actually, even if a stop action yields `Err`, it will drop the facet and leak assertions
    - yikes

 - facet drop
    - panics if outbound_handles is nonempty

 - actor cleanup
    - relies on facet tree to find assertions to retract

Revised plan:

 - ✓ revise Activation/PendingEvents structures
    - rename `cleanup_actions` to `outbound_assertions`
    - remove `for_myself` queues and `final_actions`
    - add `pre_commit_actions`, `rollback_actions` and `commit_actions`

 - ✓ assert
    - as before
    - but on rollback, removes from `outbound_handles` (if the facet still exists) and
      `outbound_assertions` (always)
    - marks the new assertion as "established" on commit

 - ✓ retract
    - lookup in `outbound_assertions` by handle, using presence as indication it hasn't been
      scheduled in this turn
    - on rollback, put it back in `outbound_assertions` ONLY IF IT IS MARKED ESTABLISHED -
      otherwise it is a retraction of an `assert` that has *also* been rolled back in this turn
    - on commit, remove it from `outbound_handles`
    - enqueue the retract action, which just calls e.retract()

 - ✓ _terminate_facet
    - revised quite a bit now we rely on `RunningActor::cleanup` to use `outbound_assertions`
      rather than the facet tree.
    - still drops Facets on panic, but this is now mostly harmless (reorders retractions a bit)
    - handles `Err` from a stop action more gracefully
    - slightly cleverer tracking of what needs doing based on a `TerminationDirection`
    - now ONLY applies to ORDERLY cleanup of the facet tree. Disorderly cleanup ignores the
      facet tree and just retracts the assertions willy-nilly.

 - ✓ facet drop
    - warn if outbound_handles is nonempty, but don't do anything about it

 - ✓ actor cleanup
    - doesn't use the facet tree at all.
    - cleanly shutting down is done elsewhere
    - uses the remaining entries in `outbound_assertions` (previously `cleanup_actions`) to
      deal with retractions for dropped facets as well as any other facets that haven't been
      cleanly shut down

 - ✓ activate
    - now has a panic_guard::PanicGuard RAII for conveying a crash to an actor in case the
      activation is happening from a linked task or another thread (this wasn't the case in the
      examples that provoked this work, though)
    - simplified
    - explicit commit/rollback decision

 - ✓ Actor::run
    - no longer uses the same path for crash-termination and success-termination
    - instead, for success-termination, takes a turn that calls Activation::stop_root
       - this cleans up the facet tree using _terminate_facet
       - when the turn ends, it notices that the root facet is gone and shuts down the actor
       - so in principle there will be nothing for actor cleanup to do

2022-02-04 13:52:34 This took days. :-(
2022-02-04 13:59:37 +01:00
Tony Garnock-Jones d820601eea Better trace messages from dependency tracking 2022-02-03 22:57:21 +01:00
Tony Garnock-Jones 28b0c5b4d5 One-shot daemons shouldn't be considered ready at all, just complete 2022-02-03 22:56:20 +01:00
Tony Garnock-Jones 7e4654c8f7 Simplify and repair stdout/stderr logging in daemons 2022-01-26 23:37:04 +01:00
Tony Garnock-Jones e600d59f6e Conditional match expressions. I can't help but feel I'm committing some kind of crime against programming language design here. 2022-01-20 10:17:15 +01:00
Tony Garnock-Jones 9080dc6f1e Fill in the rest of the jolly owl 2022-01-20 10:12:04 +01:00
Tony Garnock-Jones 4dc613a091 Foundations for causal tracing 2022-01-19 14:40:50 +01:00
Tony Garnock-Jones 45f9abfd97 (cargo-release) version 0.21.0 2022-01-16 15:15:51 +01:00
Tony Garnock-Jones 894f0a648a (cargo-release) version 0.16.0 2022-01-16 15:15:51 +01:00
Tony Garnock-Jones e6a2a25f62 (cargo-release) version 0.21.0 2022-01-16 15:15:51 +01:00
Tony Garnock-Jones 3d3c1ebf70 Better handling of activation after termination, which repairs a scary-looking-but-harmless panic in config_watcher's private thread 2022-01-16 00:02:33 +01:00
Tony Garnock-Jones a37a2739a0 Log compiled instructions in config_watcher 2022-01-15 23:23:48 +01:00
Tony Garnock-Jones b810784750 Script `+=` operator; sketch of `=~` operator 2022-01-15 23:22:51 +01:00
Tony Garnock-Jones 9453408e42 Propagate script compilation errors properly. 2022-01-15 23:22:13 +01:00
Tony Garnock-Jones 2b296d79c7 Repair error in dataspace assertion idempotency.
If a facet, during X, asserts X, for all X, then X includes all
`Observe` assertions. Assertion of X should be a no-op (though
subsequent retractions of X will have no effect!) since duplicates are
ignored. However, the implementation had been ignoring whether it had
seen `Observe` assertions before, and was *always* (re)placing them
into the index, leading to runaway growth.

The repair is to only process `Observe` records on first assertion and
last retraction.

As part of this change, Dataspaces have been given names, and some
cruft from the previous implementation has been removed.
2022-01-15 23:18:29 +01:00
Tony Garnock-Jones af4af8b048 Bump deps 2022-01-14 15:55:30 +01:00
Tony Garnock-Jones 78ef7c07db documentation.prs 2022-01-14 15:36:41 +01:00
Tony Garnock-Jones 6325538ea6 (cargo-release) version 0.20.1 2022-01-12 12:28:38 +01:00
Tony Garnock-Jones 7fbe6360e7 Support patterns like <?r <Something _ _ _>> 2022-01-12 12:28:03 +01:00
Tony Garnock-Jones d007da2e94 (cargo-release) version 0.20.0 2022-01-10 13:39:48 +01:00
Tony Garnock-Jones 08c7bd3808 (cargo-release) version 0.15.0 2022-01-10 13:39:48 +01:00
Tony Garnock-Jones 96cfb1d4e7 (cargo-release) version 0.20.0 2022-01-10 13:39:48 +01:00
Tony Garnock-Jones c3a9525ef1 Track enough information to allow piecing-together of parent/child relationships among actors 2022-01-10 12:52:12 +01:00
Tony Garnock-Jones 58bde1e29d Add Activation::stop_root 2022-01-10 11:23:02 +01:00
Tony Garnock-Jones 76d4ffd8a2 (cargo-release) version 0.14.0 2022-01-08 16:05:47 +01:00
Tony Garnock-Jones 9f560b4dd0 (cargo-release) version 0.19.0 2022-01-08 16:05:47 +01:00
Tony Garnock-Jones fcb345dbaf (cargo-release) version 0.19.0 2022-01-08 16:05:47 +01:00
Tony Garnock-Jones 7524b634d3 Repair daemon service restarts 2022-01-08 13:54:25 +01:00
Tony Garnock-Jones 4eddcf7518 (cargo-release) version 0.13.0 2022-01-07 22:06:08 +01:00
Tony Garnock-Jones c29f46c117 (cargo-release) version 0.18.0 2022-01-07 22:06:08 +01:00
Tony Garnock-Jones ff827f9c38 (cargo-release) version 0.18.0 2022-01-07 22:06:08 +01:00
Tony Garnock-Jones 6f8fb014f2 Update daemon restart policy defaults to line up better with the new supervisor defaults 2022-01-07 22:05:12 +01:00
Tony Garnock-Jones 25e75324cf (cargo-release) version 0.17.0 2022-01-07 17:19:15 +01:00
Tony Garnock-Jones 02d832500f (cargo-release) version 0.12.0 2022-01-07 17:19:15 +01:00
Tony Garnock-Jones 5281da096c (cargo-release) version 0.17.0 2022-01-07 17:19:14 +01:00
Tony Garnock-Jones 41b1708cea Append a [] to config .pr files, for ergonomics of commenting (!) 2022-01-07 17:18:16 +01:00
Tony Garnock-Jones 895a2f676c lifecycle::terminate_on_service_restart; make debt reporter accept a parameter 2022-01-07 17:18:00 +01:00
Tony Garnock-Jones 1744a0a99a Update Makefile for latest preserves-schemac command line interface changes 2022-01-07 17:15:30 +01:00
Tony Garnock-Jones b465036773 (cargo-release) version 0.16.0 2021-12-13 20:35:43 +01:00
Tony Garnock-Jones 458c2795f9 (cargo-release) version 0.11.0 2021-12-13 20:35:43 +01:00
Tony Garnock-Jones 760314ee5e (cargo-release) version 0.16.0 2021-12-13 20:35:43 +01:00
Tony Garnock-Jones f5b1fec90f Follow simplifications to sturdy caveats 2021-12-13 16:00:25 +01:00
Tony Garnock-Jones a831b02ca5 Accommodate changes to dataspacePatterns 2021-12-13 15:43:24 +01:00
Tony Garnock-Jones 5f7d323af6 (cargo-release) version 0.15.1 2021-12-01 11:14:48 +01:00
Tony Garnock-Jones 77a3ee4a31 Release 2021-11-17 08:49:29 +01:00
Tony Garnock-Jones f8ca9b9c89 Current-facet-handle expression 2021-11-17 08:45:56 +01:00
Tony Garnock-Jones 767c4bbe71 Bump preserves-schema dep 2021-11-17 08:45:56 +01:00
Tony Garnock-Jones 98a09f53e8 Release 0.14.1
syndicate-server@0.14.1

Generated by cargo-workspaces
2021-11-14 15:48:56 +01:00
Tony Garnock-Jones ce743fa934 Repair bug: environments should have symbol keys, not string keys 2021-11-14 15:47:12 +01:00
Tony Garnock-Jones 63e86efc38 (cargo-release) version 0.9.0 2021-11-12 12:34:21 +01:00
Tony Garnock-Jones 64ccf5c661 (cargo-release) version 0.14.0 2021-11-12 12:34:21 +01:00
Tony Garnock-Jones 212a5a11a3 (cargo-release) version 0.14.0 2021-11-12 12:34:21 +01:00
Tony Garnock-Jones 13a0100ad8 Add OnStop (though I'm not sure about it as a permanent feature! The syntax is gross) 2021-10-13 12:13:19 +02:00
Tony Garnock-Jones 1c80b183f1 (cargo-release) version 0.13.0 2021-10-08 16:40:11 +02:00
Tony Garnock-Jones 49eeb2452d (cargo-release) version 0.8.0 2021-10-08 16:40:11 +02:00