KamoCRM

Remove memberType field entirely to prevent Hibernate duplicate column

Fixkamo-shared-library
Ya
16 Aprili 2026, 05:29 UTC
Mwandishi
Kamo
Ahadi ya
283eb0e

The previous fixes (@Transient on field, @Access(AccessType.FIELD) on class) were insufficient. Bytecode inspection revealed Lombok's @Setter generated a public setMemberType() method. Paired with the manual getMemberType() getter, Hibernate 6 treated memberType as a full persistent property (getter+setter pair), mapping it to column member_type — duplicating the @DiscriminatorColumn and pushing security_level into the member_team_member projection. Removing the field entirely eliminates the Lombok-generated setter. Only the @Transient getMemberType() computation method remains.

Mabadiliko yote

Je, unaona nini kuhusu usafiri?

Kila kitu kinaingia kwenye tovuti yako mwenyewe. Anza kwenye mpango wa bure na usome ukurasa huu tena katika mwezi mmoja.

Kuwa Huru MileleMtazamo wa bei