Skip to content
This repository has been archived by the owner on Oct 13, 2021. It is now read-only.

Extract cargo/handling.go to its own package. #5

Open
marcusolsson opened this issue Nov 10, 2014 · 3 comments
Open

Extract cargo/handling.go to its own package. #5

marcusolsson opened this issue Nov 10, 2014 · 3 comments

Comments

@marcusolsson
Copy link
Owner

Make

cargo.HandlingActivity
cargo.HandlingEvent
cargo.HandlingHistory

into

handling.Activity
handling.Event
handling.History
@marcusolsson
Copy link
Owner Author

This is probably more of a nice-to-have. It will probably result bigger consequences on the domain model than what's warranted.

@marcusolsson
Copy link
Owner Author

This is an answer to this tweet:

In the original sample app, there's a separate handling package but due to circular dependencies (Delivery -> HandlingEvent -> Cargo), I have merged the handling package into the cargo one.

This is most likely impossible to resolve without a non-trivial redesign. The best way would obviously be to avoid circular deps from the start. So far, I've wanted to keep as much of the original design as possible, but this issue might deserve diverging a bit from that design.

@seanpianka
Copy link

Hi @marcusolsson, is this not possible by replacing the "TrackingID" type with just "ID" type? I don't see why maintaining this dependency is worthwhile (or if it should be emulated in other projects) purely to more specifically describe what kind of ID an ID is.

Sign up for free to subscribe to this conversation on GitHub. Already have an account? Sign in.
Projects
None yet
Development

No branches or pull requests

2 participants