Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

Add convenience methods to create ArtifactContainerDescriptor for default cases #22

Open
nils-christian opened this issue Aug 11, 2021 · 4 comments
Labels
clarification-needed Needs to be discussed before implementation enhancement New feature or request

Comments

@nils-christian
Copy link
Contributor

Similar to #5, I found some presumable default cases for ArtifactContainerDescriptors. I tend to categorize my building blocks usually by the package name. Therefore one could imagine methods to create descriptors based on a partial match of the full qualified name or based on a regexp maching the full qualified name of the java class in question:

ContainerDescriptorHelper.forFQNContaining( ArtifactContainerType.of( "Module" ), ".read.", "Read Models" ) 

or

ContainerDescriptorHelper.forFQNMatching( ArtifactContainerType.of( "Layer" ), ".*\.frontend\..*", "Frontend" ) 
@OLibutzki OLibutzki added the enhancement New feature or request label Aug 11, 2021
@nils-christian
Copy link
Contributor Author

I opened a PR for this issue.

@OLibutzki
Copy link
Contributor

That's interesting as I have described my containers differently, see ModuleDescriptor.

I had business containers in mind, but you built technical containers. I am not sure if this is the same idea. As each artifact can only have one container it seems not to scale. Don't you run into issues using this appoach?

@OLibutzki OLibutzki added the clarification-needed Needs to be discussed before implementation label Aug 13, 2021
@nils-christian
Copy link
Contributor Author

Well, my example application is rather small (it is a housekeeping book) and has thus only a single "business case". So in this case I prefer the separation into technical containers. Also I always expect that one would build different Archifact applications based on the same classes to describe different point of views. Thus I don't really see a contradiction.

@nils-christian
Copy link
Contributor Author

Apart from the already mentioned descriptors relying on the FQNs, we are also using annotations on package level. This might also be a common use case. I am still wondering which of these descriptors are the most common use cases and should thus be part of the API. The definition for the building blocks was much easier.

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
clarification-needed Needs to be discussed before implementation enhancement New feature or request
Projects
None yet
Development

No branches or pull requests

2 participants