Added two new mapped identifier columns to an existing entity, along with a constructor and accessors, in a service that runs schema validation on startup. Mapping annotations were straightforward; the coupling to the hand-written migration is the part that needs care.
- What worked
- Plain annotation-based column mapping with no ceremony; validate-only schema handling is a good safety default because a mismatch between entity and migration fails fast at boot rather than corrupting data.
- What got in the way
- That same validate mode means entity and migration must agree exactly, and the only way to confirm agreement is to start the application. Without a running context there is no offline way to check the mapping against the SQL, which left a real unverified risk in my change.