zachdaniel
Hey folks! I’ll be teasing some interesting bits going into Ash 3.0 while I work on it, and this is post #1!
You can follow along with the changes, if you are interested in the 3.0 branch of Ash. Please do not use this branch
. If you find issues, I will not help you with them until an actual release candidate is published.
So, on to teaser #1!
Timeline
The current plan is to have a release candidate ready in March, so we are not far off from 3.0!
picosat_elixir Installation Issues
Some of our users (especially those on windows) experience installation issues with picosat_elixir. picosat_elixir is an excellent package, and we suggest that everyone starts there, we have published an alternative, called simple_sat. You can now select one of the two when following the getting started guide, and Ash will use whichever one is present.
We strongly suggest that folks eventually figure out their installation issues with picosat_elixir (our experience is that this is primarily isolated to windows users, and that folks eventually find a workaround). However, we didn’t want that to get in the way of people trying out Ash!
Registries are no more
Registries are no longer necessary, and as such are being removed for 3.0. This simplifies set up overall, and helps avoid a point of confusion that existed in 2.0, as registries were still supported but provided no tangible benefit.
Thats it!
There is tons more already done for 3.0, and more to come, but I’ll talk more about those in upcoming posts.
I hope you’re all as excited as I am!
Teaser #2: Ash 3.0 Teasers! - #9 by zachdaniel
Teaser #3: Ash 3.0 Teasers! - #23 by zachdaniel
Teaser #4: Ash 3.0 Teasers! - #28 by zachdaniel
Teaser #5: Ash 3.0 Teasers! - #30 by zachdaniel
Teaser #6: Ash 3.0 Teasers! - #36 by zachdaniel
Trending in News & Updates
Other Trending Topics
Categories:
Sub Categories:
Forums
Popular Tags
- #ecto
- #liveview
- #troubleshooting
- #learning-elixir
- #deployment
- #library
- #erlang
- #testing
- #genserver
- #mix
- #absinthe
- #remote-other
- #otp
- #plug
- #how-to-question
- #macros
- #postgres
- #elixirconf
- #channels
- #exunit
- #discussion
- #code-sync
- #javascript
- #podcasts
- #onsite
- #dialyzer
- #docker
- #authentication
- #umbrella
- #full-time-contract
- #podcasts-by-brainlid
- #ecto-query
- #blog-post
- #elixir-ls
- #ai
- #elixirconf-us
- #phoenix_html
- #iex
- #graphql
- #genstage
- #websockets
- #supervisor
- #advent-of-code
- #distillery
- #processes
- #api
- #forms
- #hex
- #security
- #metaprogramming










Showing Posts 1 to 10- Show Best Posts
- Show All (oldest first)
- Show All (newest first)
cvkmohan
Thanks @zachdaniel. I will be watching all the teasers. Probably the best teaser #1 would have been the timeline that you have in mind regarding 3.0 release. A specific date is not expected but, 1week/1month/1quarter/1year level of timeline also would make it interesting.
BryanJBryce
Yay, no more Registries!
zachdaniel
Hey @cvkmohan, I think I’ve said it elsewhere but yes I think but it makes sense to put it in the post. I’ll edit the post, but the timeline is for a release candidate to be available in march
zachdaniel
Just to be clear, we do still need a list of resources, but we don’t need them to be in a separate module from your api
kingdomcoder
Hey, Zach!
Always excited to see Ash’s progress
I have experienced the
picosat_elixirproblem so I’m curious if there are tradeoffs between it and thesimple_satalternativeExplaining the function these libraries serve in Ash might be a nice extra
zachdaniel
simple_satis essentially just much slowerBryanJBryce
Yeah, I’ve already switched over
zachdaniel
Hey everyone, time for Teaser #2!
If you missed teaser #1, check out out here: Ash 3.0 Teasers!
This is a big one
Ash.Api → Ash.Domain
Ash.Apias a name has caused users lots of confusion in the past. It is an overloaded term. Also, while we considered it the “API to a given bounded context” as in, you always interacted with a resource through an API, we’ve ultimately decided to change the conceptual role of what we call anAPI. With that change, comes a name that is more representative of its function. Shoutout to @lukasender for the suggestion that stuck.Ash.Domainrepresents the configuration of a domain, which includes things like “what resources are available to this domain”, as well as other high level configurations. Instead of calling to an API module, we provide one standard interface, but that interface must always be able to determine whatDomainit is interacting with, in addition to whatResourceit is working with. Keep reading for more on what this looks like.domainoption touse Ash.ResourceWhen creating a resource, you pass the
domainoption. For example:This static configuration can be used in various places where you would have previously had to specify an
api. For example, you no longer need to specifydefine_forin thecode_interfaceblock.You will get a warning if you don’t pass the
domainoption, as well as if the configured domain doesn’t know about the resource.Which leads us to one of the more significant changes of 3.0:
Using
Ashinstead ofMyApp.MyApiWe will be deprecating the functions that we typically on
MyApp.MyApi, in favor of those same functions defined in theAshmodule. This allows us to refactor resources and move them from one domain to another without having to hunt down the calling code that interacts with it. It also helps reduce the cognitive overhead of having to remember what Api you’re working with for any given resource in order to call an action on it.For example:
Would become
How to make this change
Good news! You can make this change before upgrading to 3.0. You can do everything stated above by configuring the
apioption when callinguse Ash.Resource, and switching your calls to the api to callAsh! The difference between 2.0 and 3.0 is that in 3.0 the functions defined on the api module will be deprecated, andapihas been renamed todomain.Teaser #3: Ash 3.0 Teasers! - #23 by zachdaniel
TwistingTwists
I like the byte size releases. I can read them. Digest them.
One question - How to move to
domainfromapiin Ash 2.0 ? A link / migation guide?zachdaniel
There will be a guide for upgrading that will include the steps, but it essentially boils down to a big find and replace for
it will likely be the most inconvenient part of the upgrade for users.
Ash.Apiand thenapito find variables and options that should be renamed, followed by looking for calls to each api and replacing them withAsh