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

fix: servicetalk-data-jackson dependency scopes #2198

Merged
merged 1 commit into from
Apr 19, 2022

Conversation

eddie4941
Copy link
Contributor

@eddie4941 eddie4941 commented Apr 19, 2022

Motivation:

The servicetalk-data-jackson-jersey module exposes types that are
located in the servicetalk-data-jackson module. Similarly, the
servicetalk-data-jackson module exposes types that are in the
servicetalk-serializer-api and servicetalk-serialization-api modules.
Dependencies that contain types exposed in a module's API should be imported using api scope but currently these dependencies are imported using only implementation scope. Attempting to use the types results in a ClassNotFoundException.

Modifications:

  • Change servicetalk-data-jackson to an api dependency of servicetalk-data-jackson-jersey
  • Change servicetalk-serializer-api and servicetalk-serialization-api to api dependencies of servicetalk-data-jackson

Result:

Consumers of the servicetalk-data-jackson-jersey and servicetalk-data-jackson modules will be able to reference all types exposed in these modules' APIs without class not found errors or the need to explicitly import servicetalk-data-jackson, servicetalk-serializer-api or servicetalk-serialization-api modules.

Motivation:

The servicetalk-data-jackson-jersey module exposes types that are
located in the servicetalk-data-jackson module. Similarly, the
servertalk-data-jackson exposes types that are in the
servicetalk-serializer-api and servicetalk-serialization-api module.
Both of these should be moved to apiscope for each module since they
are exported by their apis.

Modifications:

- make servicetalk-data-jackson and api dependency of servicetalk-data-jackson-jersey
- make servicetalk-serializer-api servicetalk-serialization-api and and
api dependency of servicetalk-data-jackson

Result:

Consumers of these modules will get proper transitive dependency
behaviors instead of getting class not found issue if they don't
manually add the proper dependencies.
@bondolo bondolo added the bug Something isn't working label Apr 19, 2022
@bondolo bondolo self-requested a review April 19, 2022 18:23
@bondolo bondolo merged commit dc03468 into apple:main Apr 19, 2022
@eddie4941 eddie4941 deleted the fix-dep branch April 19, 2022 22:57
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
bug Something isn't working
Projects
None yet
Development

Successfully merging this pull request may close these issues.

2 participants