devonfw-forge / composited-keys-poc Goto Github PK
View Code? Open in Web Editor NEWComposited Keys PoC for devon4j and CobiGen
Composited Keys PoC for devon4j and CobiGen
Hi @trivesc
thanks for your contribution to make devon4j better. I appreciate this a lot and will try to support you.
Do you have customer demands that define requirements on the technical data model and force you to do so? (do not tell details and customer names here in OSS space)
This is adding quite some complexity that can be avoided by having a technical primary key and maintaining the business key as additional attributes instead.
However, in some cases I can see your need and am willing to extend devonfw with your feature. But if we know your use-case and demands more detailed, we can better design and plan changes.
public class NameEntity extends ApplicationPersistenceEntity<Long> implements Name<Long>
I do not understand why NameEntity is already bound to Long while the entity interface Name still carries the generic type. IMHO this does not make sense and as generics are sometimes nasty for developers (esp. beginners) we should avoid them where possible. So IMHO it should be just Name here and that interface can then have the in its extends declaration.
Further we need to think about compatibility. ApplicationPersistenceEntity
already exists in hunders of devonfw projects. Chaning this and the cobigen templates in an incompatible way is IMHO a very bad idea. Instead you can introduce a new super type ApplicationGenericPersistenceEntity<ID>
and existing projects can modify ApplicationPersistenceEntity
to extends ApplicationGenericPersistenceEntity<Long>
and their code will still work and they can continue to use CobiGen with the same templates.
Do you agree and keeping compatibility for existing projects even if it leads to somewhat more artifical names?
A declarative, efficient, and flexible JavaScript library for building user interfaces.
๐ Vue.js is a progressive, incrementally-adoptable JavaScript framework for building UI on the web.
TypeScript is a superset of JavaScript that compiles to clean JavaScript output.
An Open Source Machine Learning Framework for Everyone
The Web framework for perfectionists with deadlines.
A PHP framework for web artisans
Bring data to life with SVG, Canvas and HTML. ๐๐๐
JavaScript (JS) is a lightweight interpreted programming language with first-class functions.
Some thing interesting about web. New door for the world.
A server is a program made to process requests and deliver data to clients.
Machine learning is a way of modeling and interpreting data that allows a piece of software to respond intelligently.
Some thing interesting about visualization, use data art
Some thing interesting about game, make everyone happy.
We are working to build community through open source technology. NB: members must have two-factor auth.
Open source projects and samples from Microsoft.
Google โค๏ธ Open Source for everyone.
Alibaba Open Source for everyone
Data-Driven Documents codes.
China tencent open source team.