706 karma · joined May 20, 2012
The best lamb is young, but not too young. I'm not a fan of milk-fed lamb where I feel there is quite no taste. The right balance is slaughtered at around 90 to 150 days old. Agneau de Sisteron is a gem. You don't need to be highly skilled to cook it. For cutlets, just pan sear until pink inside. For roast and leg, oven, basted with salt olive oil, some garlic cloves inserted inside the meat. It's truly magnificent.
The older the animal, the bolder the recipes it needs. The best lamb/mutton I've ever had was in Marocco, a slow roasted lamb in honey and almonds. So tender it was served from the bone with a spoon. You'll notice that mutton is always cooked in a way to counter balance the strong muttony flavour and sublime it with contrasts. Mutton curries are also delicious for the same reason.
So I started with a PHP solution ( Craft CMS + Commerce ) that was flexible so I can just focus on front end part.
But then Covid happened and our business boomed super quickly ( in a month we went: from 2 to 10 people and 2 to 450 deliveries ). I needed to build features quickly to handle our fulfillment processes and built a separate stack of tools in Elixir, initially for packaging lists, routing calculations, sticker printing , etc... I still have some very fond memories of these crazy times.
Then I needed to redo our front end. We went from like 50 products to 1000+ products. I needed great search, smarter default sorting, recommendations, etc... and I needed the whole stack to be fast. I rebuilt everything with Phoenix and Liveview, building a weird layer to map Ecto to the super complicated Craft db schema.
We are using Craft just for the cart and payment now. The only pages served by Craft are the payment details and thank you page.
But I'm working slowly on building a complete E-Commerce stack ( a very opinionated one ) that I'd like to open source once clean and proven.
The tricky part is that Elixir is compiled, and liveview templates are not "files" but functions.
From here you have two choices:
- You create a set of primitives (blocks), and the layout/arrangement of these primitives is configurable via a config map.
- Or you do a hot-code reload: Call an api, check if new code is available, fetch it, compile it (Code.compile_string), load it (:code.load_binary ), swap it for long running processes ( GenServer.code_change callback by example ), and remove old code ( :code.purge )
The first solution is safer. The second solution is a kind of black magic and you would need a way to authenticate de source code before compiling.
Why I love it:
- The mental model just clicks for me. The syntax is really simple and the semantics are consistent. There is no abstraction. It's all about processing data.
- The REPL (IEX) is way more than a REPL. It's "you inside your running program". You can poke around your code, draft it, debug it, right there. You can fire it on prod to understand a bug. Or use LiveBook, think of it like the Elixir version of Jupyter notebooks that can connect to your application.
- Real life performance is great, not because of speed but because of concurrency.
- The whole developer experience is great. Mix (the build tool, dependency manager, etc.) is simple, awesome. Dependencies are really rarely an issue.
- It's rock solid. In 3 years, I never had one downtime.
- LiveView is a god send. Not having to switch language for UI work is amazing, performance is great, and it's server side HTML which is amazing for SEO. My website is 99 on lighthouse without any crazy work.
- You need heavy computation and performance on some parts? Use rust, via rustler.
- You need to scale to multiple servers? It is distributed. Already. Just make sure to not have anti-patterns in your code.
- But the real kicker it's in its power due to the OTP platform. I think it's quite complex to grasp how much it's powerful when you haven't experienced it. Need to batch insert statements or rate limit api calls to a 3rd party service who can only accept one call per second per channel? A working simple solution is only 20 lines of code. Need to launch many different workflows running concurrently, keeping their state, recovering when crashing? 100 lines.
The exciting developments:
- Elixir NX ecosystem (NX, Bumblebee, etc): running and training AI models directly in Elixir, in a distributed way.
- Liveview Native and Elixir Desktop: two big initiative to bring Elixir to Desktop and Mobile applications.
- Gradual Typesystem. Jose Valim, the creator of Elixir, is working on that right now. I really liked the approach of set-theoretic types and the pragmatism of the approach. Hopefully it will be released in the not too distant future.
The "to improve":
I have the feeling that the platform (OTP) being the killer app per se of Elixir, the whole marketing of the ecosystem if 100% targeted towards developers. Which is good in many ways. But for the ecosystem to grow I think more initiatives towards business-type applications would be welcome. By example, there is only a few payment gateways libraries existing which is for me a sign of the lack of business audience.
Conclusion: Elixir made me a better developer, but most importantly a really productive one.
There is Petal[1] that looks like the most advanced one right now, but not yet as complete.
It's great for three reasons:
1 - it's the easiest and fastest grating device for cheese 2 - it's safe. Microplanes are great but it often happened that my cheese got a little bit of finger with it 3 - the texture and taste of the cheese is amazing. I can't explain it but it seems that the strands of cheese are thinner and longer . Whether it's on Parmigiano Reggiano or on old Comté it's just beautiful.
More on topic : never buy pre grated cheese. Or any thing pre-something.
His skills are an amazing gift to the world and would deserve to be taught and shared?
I don't see the bad faith there.
But 63% of methane production comes from Fossil fuel industry: https://en.wikipedia.org/wiki/Methane_emissions#List_of_emis...
( it's funny how biased this table is laid out, agriculture is summed, while fossil fuels is detailed, showing smaller numbers, and gas flared ( 100M tons! ) is a footnote ).
The main problem is the source of energy we are using globally.
Food is a pillar of what defines humanity, thousand of years of culture, agriculture, traditions.
1- this is junk food. It's highly processed food, the antithesis of their communication of healthy.
2- their communication is about "saving the planet" from cow farts. The issue is not cow farts. The issue is intensive agriculture and bad quality meat. Cows do not magically create CO2. They fart existing CO2 from grass, and grass capture CO2 from the atmosphere. It's a cycle. What broke the cycle are fossil fuels.
3- the ultimate goal is to put intellectual property on food. Same textbook recipe as Monsanto. And that's the major risk with all these "new protein" companies. We can't have food be an intellectual property.
I might be wrong. But this is my assessment.
The ejabberd system was great at the time but lacked flexibility. But I think we saved at least 3 months of dev thanks to it.
I see you are using 3 languages, that's a lot of things to coordinate and keep in the brain. May I ask why you use node for the rest API and not elixir ? That would simplify things a lot.
Sure you can email me at jm at producture dot com
As I was the only pianist in the family, it followed me everywhere I moved, from France to now south east Asia. After 40 years, it is still working perfectly, even if it had endured a lot.
I also have digital keyboards, make music with great VSTs, etc...
But nothing compares to a real piano in terms of inspiration and emotion. Each piano you play with will have a soul and character that will resonate with you (or not).
I love digital things, but nothing replaces the poetry of a piano. And damn, these instruments are marvels of craftmanship.
And people saying having to bring a technician to tune your piano twice a year is a chore, for me it's the opposite. I love seeing my technician optimizing the sound and the action to my playing style, discussing with him about his experience in Hamburg at Steinway, etc...
- Web -> Phoenix ( https://www.phoenixframework.org/ )
- Parallel data processing (like scrapers, ETLs, etc...) -> GenStage / Flow / Broadway ( https://hexdocs.pm/gen_stage/GenStage.html )
- IOT -> Nerves ( https://www.nerves-project.org/ )
Soon:
Mobile Apps -> Elixir Desktop ( https://github.com/elixir-desktop/desktop )
ML -> NX ( https://github.com/elixir-nx )
The third project was a complete rewrite of a really badly created dating website written in PHP that would crash at least once a day and would be unbereablly slow, built by 5 people for a full year. We rewrote everything in 3 months, with two developers, while adding features that were impossible to do otherwise. One lighting bulb moment is when we realize we could use ejabberd and the xmpp protocol for way more than messages and chats, but also to handle our news feed. Once we launched the rewrite, the website became extremely fast and stable. Since then, the BEAM has always been my go-to platform, even if now I use elixir.
There is no platform/language that makes me feel more productive and confident about the code I write. The fact I can introspect the code (the repl is way more than a repl), the crazy stability of the runtime, and the simplicity of the language makes it a no brainer.
LiveView is a game changer. We built our entire e-commerce stack on it, it runs flawlessly.
My only issue with the Elixir/Erlang ecosystem is its lack of business oriented libraries and solutions: - not many payment gateway integrations - no CMS / E-commerce platforms - quite no ready to use open source apps
Yes it's not as fast in pure performance as many other programming languages, but in practice, it's fast as hell due to concurrency and performance doesn't degrade with load.
And so many exciting things are being developed, from LiveView based native apps to ML and IOTs.
I've been using Datapacket for a year for my e-commerce company. Amazing performance, stability and service. Best dedicated hosting I've experienced in a long time.
Example:
Let's suppose I've downloaded all the Gutemberg library books.
I can feed a transformer like Bert or GPT-3 to calculate the embeddings of these books.
These embeddings will represent in vector form (an array of numbers of fixed size) the meaning of these books.
I can save these vectors in this database and this database can then calculate the distance between these vectors, so basically how closely related they are in terms of topic.
If I query this database with the embedding of a sentence like "Love story between teenagers from 2 enemy families in Italy, they die at the end", hopefully the best result will be Romeo & Juliette.
I'm no ML person so take my comment with a grain of salt in terms of how well it works. But in theory, that's the goal.
With 1TB, you have already a pretty solid base to rebuild civilization.
Then you can go deeper:
As of last year, all Library Genesis for nonfiction is 40 TB and Scientific Papers are 78.5 TB. Total Library Genesis seems to be 220TB.
Finally, you can go bigger: The total size of archive.org seems to be around 212 PetaBytes. That's some serious storage required.
If I had only one floppy disk, it would be a selection of philosophy books from Socrates, Aristotle, Marcus Aurelius, Thomas Aquinas, La Boetie, Kant, Spinoza, Descartes, Nietzsche, Wittgenstein.