News for hackers. Stuff that matters.

RedCrowbar

Re:EdgeDB is now Gel and Postgres is the future on Tuesday February 25, 2025 @10:57PM (#43180443)
You can use access policies [1] to emulate temporal data. See an example in [2]

[1] https://docs.geldata.com/reference/datamodel/access_policies

[2] https://github.com/geldata/gel/issues/4228#issuecomment-1208...

Re:EdgeDB is now Gel and Postgres is the future on Tuesday February 25, 2025 @08:39PM (#43179705)
Strictly speaking we charge for compute and storage. You can create variously-sized Gel instances and within those instances an arbitrary number of branches.
Re:EdgeDB is now Gel and Postgres is the future on Tuesday February 25, 2025 @07:55PM (#43179438)
The paper seems to mostly focus on the quality of cardinality estimation (mostly driven by statistics) which is admittedly one of the frequent sore points in Postgres. There's been some progress in that area though (CREATE STATISTICS being a highlight).
Re:EdgeDB is now Gel and Postgres is the future on Tuesday February 25, 2025 @07:10PM (#43179136)
That's already supported, you just need to set the Postgres cluster URI in the `GEL_SERVER_BACKEND_DSN` env var ([1]).

[1] https://docs.geldata.com/reference/reference/environment#gel...

Re:EdgeDB is now Gel and Postgres is the future on Tuesday February 25, 2025 @07:08PM (#43179122)
You can use Docker (and Docker Compose) with Gel for local development [1], but of course you'd miss out on most management features of the CLI, because it's not built to supplant the docker/docker-compose CLI. Are there any particular issues you have currently with the Docker image approach?

[1] https://docs.geldata.com/resources/guides/deployment/docker

Re:EdgeDB is now Gel and Postgres is the future on Tuesday February 25, 2025 @06:58PM (#43179053)
(article author here)

> If I use some other extension like timescale is that compatible with gel [...] Postgres is so powerful partly because of its ecosystem, so I want to know how much of that ecosystem is still useable if I’m using gel on top of Postgres

Playing nice with the ecosystem is the goal. We started off with more of a walled garden, but with 6.0 a lot of those walls came down with direct SQL support and support for standalone extensions [1]. There is a blog post coming about this specifically tomorrow (I think).

> And is there a story for replication

Replication/failover works out of the box.

> subscribing to queries for real time updates?

Working on it.

> so can I add gel to an existing Postgres instance and get the benefits of the nicer query language or does it rely on special tables?

Gel is built around its schema, so you will need to import your SQL schema. After that you can query things with EdgeQL (or SQL/ORM as before).

[1] https://github.com/geldata/gel-postgis

Re:EdgeDB is now Gel and Postgres is the future on Tuesday February 25, 2025 @06:45PM (#43178964)
Gel as in gif obviously! :-)
Re:Show HN: PRQL in PostgreSQL on Monday February 19, 2024 @06:19PM (#39436025)
EdgeDB is NOT an object store. It is "relational model enhanced" instead where a set is a fundamental building block [1] so not just relations are sets, but attributes can be sets also.

[1] https://www.edgedb.com/docs/edgeql/sets#ref-eql-everything-i...

Re:Jepsen: MySQL 8.0.34 on Tuesday December 19, 2023 @11:32AM (#38697731)
If your database client is any good, it should do the retries for you. EdgeDB uses serializable isolation (as the only option), and all our bindings are coded to retry on transaction serialization errors by default.

Transaction deadlocks are another common issue that is triggered by concurrent transactions even at lower levels and should be retried also.

Re:Show HN: EdgeDB Cloud and 4.0 with FTS and Auth on Thursday November 02, 2023 @03:07PM (#38118489)
Yes. Apache 2.0 licensed with lots of focus on local-first development.
Re:Show HN: EdgeDB Cloud and 4.0 with FTS and Auth on Thursday November 02, 2023 @12:25PM (#38115948)
There is a work-in-progress query builder support for .NET: https://github.com/edgedb/edgedb-net/tree/feat/querybuilder-...
Re:Show HN: EdgeDB Cloud and 4.0 with FTS and Auth on Wednesday November 01, 2023 @01:56PM (#38102148)
We wrote a blog post about this specifically: https://www.edgedb.com/blog/why-orms-are-slow-and-getting-sl...
Re:EdgeDB 3.0 on Friday June 23, 2023 @01:08AM (#36443022)
> Can EdgeDB solve the problems like `soft-delete`?

Yes, with access policy rules. E.g

   global hide_deleted: bool;

   type SoftDeletable {
     deleted: bool;

     access policy hide_deleted
       allow all
       when (global hide_deleted)
       using (not .deleted);
   }
The above will effectively "hide" objects with `.deleted` set to `true` from all queries when the `hide_deleted` global is set to true.

> How about hooks, for example, I want to trigger scripts after/before a record is added to the table.

EdgeDB supports triggers: https://www.edgedb.com/docs/changelog/3_x#triggers. Future versions will add support for causing effects outside of the database, e.g. call a WebHook or some such.

Re:EdgeDB 3.0 on Friday June 23, 2023 @12:28AM (#36442786)
Re:EdgeDB 3.0 on Thursday June 22, 2023 @11:36PM (#36442487)
No plans for that yet. We feel EdgeQL is a far superior choice for the intended use case of application development.
Re:EdgeDB 3.0 on Thursday June 22, 2023 @11:32PM (#36442466)
Yes, although rewrites are fairly minimal. Mostly limited to name mangling.
Re:EdgeDB 3.0 on Thursday June 22, 2023 @02:02PM (#36436204)
Yes, we are looking into possibly supporting in-place upgrades in future releases.
Re:EdgeDB 2.0 on Thursday July 28, 2022 @11:44PM (#32272929)
Efficient transitive closure (aka link recursion) is something we plan to tackle soon (see https://github.com/edgedb/edgedb/discussions/2634 for some discussion on the topic).
Re:EdgeDB 2.0 on Thursday July 28, 2022 @07:44PM (#32271418)
Yes: https://github.com/edgedb/edgedb-go/issues/182

Feel free to jump in with suggestions, we need feedback from experienced Go devs.

Re:EdgeDB 2.0 on Thursday July 28, 2022 @07:35PM (#32271366)
EdgeDB does not use Postgres RLS, access rules are injected into every query by the query compiler instead. This side-steps the RLS gotchas and limitations (RLS does not allow aggregates in rules, EdgeDB does), but also yields somewhat better query performance.
Re:EdgeDB 2.0 on Thursday July 28, 2022 @06:14PM (#32270705)
Alas, we have to wait until CockroachDB becomes a bit more capable SQL-wise. I gave a more elaborate answer in https://github.com/edgedb/edgedb/discussions/3403.
Re:EdgeDB 2.0 on Thursday July 28, 2022 @05:49PM (#32270510)
With the addition of `GROUP` in 2.0, EdgeDB is as suitable for OLAP as vanilla Postgres is (unless you absolutely need window functions, which we don't implement yet).
Re:EdgeDB 2.0 on Thursday July 28, 2022 @05:47PM (#32270488)
EdgeDB is very particular about how the underlying data is organized, so you can't put it in front of an existing database. Importing schemas and data is another story which we're working on.
Re:EdgeDB 2.0 on Thursday July 28, 2022 @05:35PM (#32270375)
Only the query compiler is in pure Python and you only hit that once per query, as the compilation result is trivially cached. The hot path is a combination of Cython, C and Rust. We have a suite of benchmarks [1] that show relative overhead of EdgeDB compared to raw Postgres is quite low.

[1] https://github.com/edgedb/imdbench

Re:EdgeDB 2.0 on Thursday July 28, 2022 @05:29PM (#32270340)
I think the OP meant `NOT NULL` as in nullness check in queries. EdgeQL uses `exists <foo>` to check for existence of data. We have examples in the cheatsheet and elsewhere but it's probably hard to find if you're looking for "NOT NULL" specifically. We'll see about a way to improve the discoverability of this.
Re:EdgeDB 2.0 on Thursday July 28, 2022 @05:18PM (#32270238)
Yes, we'll be adding a way to choose the index type. It's even more relevant now that we've exposed range types.
Re:EdgeDB 2.0 on Thursday July 28, 2022 @05:11PM (#32270164)
You can run the server in foreground [1] with `env EDGEDB_DEBUG_EDGEQL_COMPILE_SQL_TEXT=1` and observe emitted SQL.

[1] edgedb instance start --auto-restart --foreground -I <your instance>

Re:EdgeDB 2.0 on Thursday July 28, 2022 @04:57PM (#32270018)
Postgres does have a very elaborate extension system, but it's unsuitable for something like EdgeDB, because we are fundamentally altering the database interface: EdgeQL vs SQL and a different client/server protocol.

Older »