How would an Elixir implementation be organized that provides the main features of SQS?
The queue is persistent if the system shuts down
Can accept new items quickly
Makes it easy to check or be notified when a new item is ready to pop.
I’m about to use SQS (and maybe Broadway to read from it, and connect to the next stage), but thinking there might be some Elixir / OTP components that could provide this functionality.
You could build something similar with Mnesia and regular messages, or with custom storage. See RabbitMQ for example. However it will be more troublesome and maintenance-needed solution than just using SQS. However if you for example already use PostgreSQL and you will not have large volume of messages then you can check out PostgreSQL NOTIFY mechanism, maybe it will be enough for you.
I would advise against using Mnesia because in fact Mnesia doesn’t give the ACID guarantees it advertises in the docs, as its not durable and you can loose data with netsplits, due to unexpected failures(it has a delay to write to disk) or when you start it(my case).