New article is out! 🎉
➡️ https://t.co/few6OhKsrT
A deep dive into using Value Objects as Doctrine entity IDs — with insights from real DDD experience.
Something I discovered and learned at @YousignEU 😘
This demonstrates implementing realistic and safe in-memory mechanisms for testing and for official reference. I prefer in-memory implementations over mocks. I use persistence as the example, but it applies to other types of mechanisms.
When an object is persisted in a disk-based database, it is always serialized. The serialization is separted from the original object; it's a representation such as a byte array or a string. You must do the same for thoughtful in-memory implementations. If you don't and you change the object that was persisted, those changes are also in the persistence mechanism because it holds the same object. It's a concern both when writing and reading objects.
I generally do this, assuming some type of repository, such as InMemoryBlahRepository:
void save(blah) {
// create deep copy
val serialized = serialize(blah)
val copy = deserialize(serialized)
map.put(https://t.co/JmaljScdmr(), copy)
}
Blah blahOf(id) {
val blah = map.get(id) // assumes existing
// create deep copy
val serialized = serialize(blah)
val copy = deserialize(serialized)
return copy
}
You have similar considerations for messaging mechanisms and others.
If one #DDDesign aggregate's operations are based on the state of another aggregate, such as a child dependent on its parent, doesn't that point to the need for the child to be composed inside the parent?
Take, for example, forums, discussions, and posts. The parent relationships are logically like this:
forum(1)->(*)discussion(1)->(*)posts
First, consider the practicality of composing potentially hundreds, thousands, or even millions of discussions under one parent forum. Bad idea. The same goes for posts within a discussion.
Now, there's a business rule: new discussions can't be started when its would-be parent forum is closed. Uh, oh! That's a business invariants that must be managed by a transactional consistency constraint! Or is it?
If you think this is a case for aggregate composition, you are thinking too technically. Forum owners don't sit around, constantly toggling a forum closed, open, closed, open, ... When a forum is closed, it's closed, and it's rarely reopened. It's okay if there's a slight window of inconsistency. Eventual consistency handles handles this situation just fine.
But, wait!
What if a new discussion is started just before its parent forum is closed?
The true answer: Who cares? It's not as if an insane dictator pressed The Red Button (tm).
There are categories of business rules where a child's behavior must be absolutely consistent with its parent. (Think health and financial.) Even so, forum, discussion, and post are not in that category.
With Symfony 7.2, you will be able to lint your translations, especially useful to prevent your app from crashing if an ICU translation is malformed :)
https://t.co/0hRu1nk2ix
We will have more stuff to share pretty soon; but in the mean time, if you're looking for a super fun 2 players co-op game you should definitely checkout Xion Leak's demo on Steam
😀 Je viens de publier les slides de mon talk "DDD !== Archi hexagonale" que j'ai donné vendredi dernier à l'#AFUPDay Lyon 2024
Encore merci à l'@AFUP_lyon pour cette super organisation : tout était nickel !
https://t.co/pXBBNXkF29
Avant son talk "DDD !== Archi hexagonale", @B_galati nous explique son approche de l'archi hexagonale et sa vision pour l'implémenter au sein d'une équipe. De quoi mettre en appétit pour l'AFUP Day 2024 Lyon: prenez vos places pour le 24 mai !
https://t.co/dX36Eb7mF3
@e3d5_fr@nnayya Non, pas nécessairement. C'est à la direction technique de donner la vision la dessus. Le livre "Software engineering at Google" en parle aussi. Le manager sera hands-off dans les grandes équipes avec des personnes peu autonomes et inversement.
Je cherche 1 Dev senior pour me rejoindre
🧮 Stack à jour
🛑 0 TMA
🌟 Features innovante
💰 Bonne rémunération
✅ Process de release industrialisé
🏔️ Des gens compétents pour Level Up
🌿 Environnement sain et Fun🤡
🚗 Autonomie
🏠 CDI Full remote
(je poste la fiche de poste ASAP)
Gentle reminder that you can use PostgreSQL's advanced queries with Doctrine. Results are even hydrated!
In the following example, I want the 4 previous and the 4 next crawl for a given crawl
Symfony 6.4 will be able to profile Symfony commands 🎉🎉🎉
https://t.co/7bDB9hvmnn
Big thanks to @julespietri for the hard work (see the last comments and add your ♥)
👋🏽 Avec ma super team @Yousignfr ça fais quelques mois qu'on bosse sur 1 version Freemium et depuis today vous pouvez signez vous-même en illimité, c'est pratique si on a des docs à signer sois-même, plus besoin de les imprimer ♻️
Go Essayer ! ✍🏿🔥
➡️ https://t.co/6hqExTlhIl
Yousign sera au Forum #PHP de l’@AFUP 🚀
N’hésitez pas à venir nous voir sur le stand n°5 🤩
Et ne ratez pas notre conférence exclusive :
⚡️ You Build It, You Run it, l’observabilité pour les devs
avec @SmaineDev, le 13 oct. à 14:45 ⏰
Il reste encore des places pour le Forum PHP 2023 au tarif de 100€ pour les étudiant·e·s : devs de demain, profitez du partage de connaissances et découvrez l'ambiance unique propre à la communauté PHP. Ecrivez à bonjour[at]https://t.co/IlTWH51I4j pour en bénéficier.