Ash Community Updates

That’s an excellent post @dblack and really shows how the tagline of Ash is realized.

With the new Ash liveview generator, even the index, form and show components will be drafted. The index/lists are also fully streamed with pagination supported in the domain model.

But what was most amazing is the Ash Phoenix integration also ensures every liveview state is truely live with what’s committed in the data layer using pubsub notifications based on successful transaction notifications. This leverages another Ash domain model feature to only send notifications on transaction completion so you avoid half baked state in your views with complex transactions which may fail, including transactions that occur across multiple data layer types (think a mix of ETS, Postgres and some external API).

Then we get into the Ash query engine that plans out and pushes queries down to heterogeneous data layers including joining across these layers and doing so in a smart way to preserve observability constraints defined by access policy using it’s SAT solver to make it efficient. e.g. it wouldn’t make sense to query all items on an external API and then join those IDs against a local Postgres table, return the results and only then restrict to what you’re allowed to do. For one, aggregates and calculations will be wrong also and we want those pushed down to the datalayer where possible. For example, if you have an access policy rule that limits observability to only items you created or have contributor role for the Ash SAT solver will determine an efficient means to answer the question.

Most of the drudgery taken care of for ambitious applications.

Ash is truely is on a another level of thoughtful and purposeful design, @zachdaniel has really done some amazing work the Ash Framework.

5 Likes