Release 0.9.0 #1293
michaelvlach
announced in
Announcements
Release 0.9.0
#1293
Replies: 0 comments
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment
-
Hi,
the release 0.9.0 is out and it contains some major improvements focused on usability and ergonomics:
agdb website
We now have dedicated website for
agdb
: https://agdb.agnesoft.com/All the documentation has been moved there as it offers more rich experience than pure markdown here on GitHub. Links from the main readme now leads to the website where you can find documentation, API references, blogs and more.
search ergonomics
Searching is the fundamental part of the querying system. Previously it was possible to use search as a nested query in
ids()
part of a query. Since0.9.0
it is possible to usesearch()
instead and seamlessly embed search queries that way. Examples:This is purely ergnomic improvement and does not change the underlying query objects in any way. I also applies to all available apis - Typescript, Rust & PHP.
value ergonomics [breaking change, Rust only]
Previously it was necessary to use exact type when passing values to queries (in Rust), i.e.
QueryBuilder::insert().values(vec![vec![("k", 1).into()]]).ids(1).query()
. This was never an issue in the dynamically typed apis (Typescript & PHP) and it is no longer needed in Rust as well:Please note that this is a breaking change in few places because the original syntax when passing keys is now ambiguous, i.e.
QueryBuilder::select().values(vec!["key".into()]).ids("a").query()
. The fix is to remove both the.into()
because the builder now accepts generic argument which cannot be inferred (previously there was a concerete type which is why.into()
worked). You can also remove thevec!
as single arguments can now be passed directly and beside vectors you can also pass arrays or slices or references.optional & vectorized user values [rust only]
The derive macro
agdb::UserValue
now supportsOption
types. If the value isNone
it is omitted when inserting to the database. Additionally there is a new empty traitDbUserValueMarker
and a derive macro for itagdb::UserValueMarker
. This is needed for vectorized user types to work in the database. Both of these changes greatly expand the usability of the user types in the database:You can now use both vectorized user values and optional values.
query ergnomics [rust only]
Another item that was never an issue in the non-Rust apis is that the queries needed to be passed to the database as a reference. It is now possible to pass them by value as well:
Full release notes can be found at: https://github.com/agnesoft/agdb/releases/tag/v0.9.0
Thank you all for your support and keep reporting any issues or experiences or requests that you have so we make
agdb
one of the greatest databases there is.@pinghe @teodosin @nerdachse
Beta Was this translation helpful? Give feedback.
All reactions