vendredi 4 juin 2021

Organize large java persistance layer package

I have a package that contains a JPA package-private class that is used in other JPA classes relationships, so I have to put all dependendant classes inside same package.

Only service classes are public, rest of classes are package-private to keep separation between layers.

I have many dependent classes, with helper/repository classes so that this package is very large. Large package means poorly organized code.

Is there a way to better organize this persistance layer package?

Splitting into multiple packages require changing the access modifier of some package-private classes, and I don't want to make them public.

Aucun commentaire:

Enregistrer un commentaire