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

Release/candidate/v0.9.1 #1233

Closed
wants to merge 52 commits into from
Closed

Conversation

bfops
Copy link
Contributor

@bfops bfops commented May 14, 2024

Description of Changes

Please describe your change, mention any related tickets, and so on here.

API and ABI breaking changes

If this is an API or ABI breaking change, please apply the
corresponding GitHub label.

Expected complexity level and risk

How complicated do you think these changes are? Grade on a scale from 1 to 5,
where 1 is a trivial change, and 5 is a deep-reaching and complex change.

This complexity rating applies not only to the complexity apparent in the diff,
but also to its interactions with existing and future code.

If you answered more than a 2, explain what is complex about the PR,
and what other components it interacts with in potentially concerning ways.

Testing

Describe any testing you've done, and any testing you'd like your reviewers to do,
so that you're confident that all the changes work as expected!

  • Write a test you've completed here.
  • Write a test you want a reviewer to do here, so they can check it off when they're satisfied.

kazimuth and others added 30 commits April 12, 2024 16:05
…1085)

* Table: skip alignment checks in eq_row_in_page and hash_row_in_page

* Whoops, those comments can stay the same.
Fix a minor bug where completely empty transactions would still be
written to the commitlog. The bug is minor because, once we start
logging inputs, all transactions will be non-empty.

The check is done in relational DB rather than the durability crate,
because in principle empty transactions are permissible, and may be used
in the future (e.g. to confirm a certain offset).
* Fix iai-callgrind rustc version mismatch

* Two spaces

* Future-proof
- Arcing `TableSchema`, and this has benefits elsewhere too.
- Arc<[_]>ing the visitor program instructions.

The data behind the Arcs very rarely change,
which is the perfect case for an Arc.
* Slow query log

* Addressing some PR comments
Prerequisite for auto-disconnect after a database crash, requested for
analytics purposes.
* slow query log: only use Instant::now when needed + refactor

* address Joshua's review
Closes #1115.

Previously subscribers were only identified by their Identity.
However the same Identity can be associated to different Addresses.
* durability: Introduce a method to obtain the max tx offset of a history

Useful for reporting replay progress.
Include note that it is somewhat similar to `std::iter::Iterator::size_hint`.

* core: Re-instantiate replay progress reporting

The percentage is calculated as starting from the zero offset, although
that may change in the future.
When a server key rotation is suspected, suggest to make the new
identity the default.

This usually happens during development using an ephemeral instance. If
one follows the instructions, the `default_identity` is not set for the
existing server, which makes the CLI generate a fresh identity every
time.

See also: #333
Traversing the commitlog without also making it available for writing
would still require upfront I/O imposed by the `open` constructor.

Avoid that by introducing free-standing functions which start traversal
right away.
Co-authored-by: John Detter <no-reply@boppygames.gg>
Avoids an unnecessary roundtrip through `Vec<u8>` in private#731.
Co-authored-by: John Detter <no-reply@boppygames.gg>
Co-authored-by: John Detter <no-reply@boppygames.gg>
…rver> (#1131)

Co-authored-by: John Detter <no-reply@boppygames.gg>
* Remove redundant field Column.col_id

* remove redundant fn Header::ty

* - move extract_table_field to only use (#1137)

- remove unused get_index_by_field
- Nix len-prefixing in `Hash for ProductValue`
- Ignore discriminants in `Hash for ArrayValue`
This adds a non-fallible `write_fmt` method to `CodeIndenter<String>` (since we know it should never fail), which allows to use `write!` and `writeln!` without `.unwrap()` everywhere, making code a lot less noisy.
While working on the new C# codegen, I accidentally noticed that those tests were passing even when they clearly should've been failing due to changed output.

After running with `--nocapture`, I found out it's because the tests are silently skipped and reported as successful when `rust_wasm_test.wasm` isn't built.

This further led to finding that `rust_wasm_test.wasm` is never built - the relevant module results in `rust_wasm_test_module.wasm` instead - so these tests have been incorrectly passing for ages.

This PR changes them to actually build the module as part of testing and updates the snapshots to latest master.
* add hash_bsatn + move proptest generators to sats crate

* add eq_bsatn
While looking through the large diffs while splitting out small PRs out of my refactor branch, I noticed that quite a lot of noise is from me working on a formatted code and using primary constructors while the one in master is not.

As such, I'm splitting out just those automated / non-functional changes into a separate PR to make subsequent functional diffs easier to read.
* [bfops/tests-use-explicit-server]: fix?

* [bfops/tests-use-explicit-server]: empty

---------

Co-authored-by: Zeke Foppa <github.com/bfops>
RReverser and others added 11 commits April 29, 2024 18:06
Const members shouldn't count as table or type fields in `[SpacetimeDB.Type]`.
* Disallow calling random lifecycle reducers

* Add lifecycle reducer smoketest
Fixes #1170.

Also updates the bucket values for the queue length histogram.
Also removes the max queue length metric, since the histogram should suffice.
Fixes #1173.

Previously we were only recording this metric for scheduled reducers.
We were also recording it before we acquired access to the module instance.
Now we record it for all reducers after we acquire access to the module instance.

This patch also removes max wait time since the histogram should suffice.
* NFC: few more C# shorthand conversions

For some reason these automated refactoring conversions didn't get included in #1149.

* Also remove unused usings

* Restore a using that was erroneously marked as unused
2. Make `RowRef::row_hash` use the above.
3. Make `Table::insert` return a `RowRef`.
4. Use less unsafe because of 1-3.
5. Use `second-stack` to reuse temporary allocations in hashing and serialization.
Reuse the `indented_block` helper more and add new `CsharpAutogen` helper structure for consistent header / footer structure and reduced boilerplate.
* redefine FieldName as (TableId, ColId)

* fix & refactor tests + move MemTable/Header test helpers test code
@bfops bfops added the Do not merge Do not merge PRs with this label without coordinating further label May 14, 2024
@bfops bfops closed this May 14, 2024
@bfops bfops reopened this May 15, 2024
@bfops bfops changed the base branch from master to release/v0.9.0-beta May 15, 2024 16:22
@bfops bfops marked this pull request as ready for review May 15, 2024 16:22
@bfops bfops changed the base branch from release/v0.9.0-beta to master May 15, 2024 16:22
@bfops bfops requested a review from cloutiertyler as a code owner May 15, 2024 16:22
@bfops bfops marked this pull request as draft May 15, 2024 16:29
coolreader18 and others added 2 commits May 15, 2024 11:08
* Add SDK test for `SELECT * FROM *`

Which doesn't pass, because we broke it.

* Fix select * from *

---------

Co-authored-by: Phoebe Goldman <phoebe@goldman-tribe.org>
…s/bump-version' into release/candidate/v0.9.1
@bfops bfops force-pushed the release/candidate/v0.9.1 branch from 750d134 to 9de3eef Compare May 15, 2024 18:08
…e lock when committing tx to prevent deadlock
@bfops bfops force-pushed the release/candidate/v0.9.1 branch from 65f571f to eb09f6e Compare May 22, 2024 14:00
Setting to v0.9.0 to match the other nuget package that was published from the SDK
@kurtismullins kurtismullins changed the base branch from master to release/v0.9.0-beta May 23, 2024 18:19
@bfops bfops closed this May 24, 2024
@bfops bfops deleted the release/candidate/v0.9.1 branch May 24, 2024 15:13
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
Do not merge Do not merge PRs with this label without coordinating further
Projects
None yet
Development

Successfully merging this pull request may close these issues.

None yet