79751213

Date: 2025-08-30 14:33:03
Score: 2
Natty:
Report link

But first -> why just don't remove old Entity in microservice when You have it in SDK?

If You want disable/enable sdk for concrete microservices, configure it per microservice with @EnableJpaRepositories, @ComponentScan, @EntityScan (just dont specify SDK package there).

If You don't want remove entity from microservice, maybe pack this "shared logic" with "shared fields" into @Embeddable class and add it in microservice entity as @Embedded object => but if You can do this, i would recommend to reengineer this structure into f.e inheritence ORM (@MappedSuperclass, @Inheritance) or interface inheritance in plain Java.

Reasons:
  • Long answer (-0.5):
  • No code block (0.5):
  • Contains question mark (0.5):
  • User mentioned (1): @EnableJpaRepositories
  • User mentioned (0): @ComponentScan
  • User mentioned (0): @EntityScan
  • User mentioned (0): @Embeddable
  • User mentioned (0): @Embedded
  • User mentioned (0): @Inheritance
  • Low reputation (0.5):
Posted by: ECHU