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

Investigate package cycles in lending #19

Closed
pilloPl opened this issue Apr 6, 2019 · 3 comments
Closed

Investigate package cycles in lending #19

pilloPl opened this issue Apr 6, 2019 · 3 comments

Comments

@pilloPl
Copy link
Member

pilloPl commented Apr 6, 2019

No description provided.

@bslota
Copy link
Collaborator

bslota commented Apr 18, 2019

55835239-effb9e00-5b1b-11e9-870d-6af17b2efab7
Problematic dependencies include: events, PatronId, book types

@bslota
Copy link
Collaborator

bslota commented Apr 18, 2019

Answering your question @dosdebug regarding the cycles, it is true that conceptually a patron can hold (among others) a book, and a book can be held by a patron. What event storming sessions has uncovered, though, is that it is the patron that we're interacting with directly in order to place a book on hold, collect it, etc. It means that there is a relation: patron -> book which is unidirectional. In other words, a patron depends on a book, and this dependency should be reflected in the code as well.

Considering it further, having bidirectional dependencies, including PatronEvents, PatronId, BookType, we introduce coupling, loosing orthogonal package structure, components' autonomy, etc.

Does this sound reasonable?

I already started analysis with ArchUnit test (actually, I could put in into some branch to share with you - will do it soon) which shows all cycle-related issues. There are a couple of ways of solving them, and we need to align it with our model to keep arch-code gap minimized.

As soon as I push the branch with mentioned test, we can continue with it.

@ghost
Copy link

ghost commented Apr 18, 2019

@bslota Sure. I got it, so we need to maintain uni-directional communication.

@pilloPl pilloPl closed this as completed Sep 28, 2019
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
None yet
Projects
None yet
Development

No branches or pull requests

2 participants