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 JCenter support #41

Open
jameswald opened this issue Apr 23, 2016 · 3 comments
Open

Add JCenter support #41

jameswald opened this issue Apr 23, 2016 · 3 comments

Comments

@jameswald
Copy link

jameswald commented Apr 23, 2016

https://www.artifact-listener.org currently only monitors Maven Central. Are there any plans or thoughts about adding JCenter as well? Some projects such as https://github.com/google/agera are only available on JCenter.

@lalmeras
Copy link
Member

Current version may be easily customized to use JCentral by providing an alternative to MavenCentralSearchApiServiceImpl based on JCentral service : https://bintray.com/docs/api/#_maven_package_search

More work is needed to provide multi-repository (simultaneous maven central & jcenter) as it implies deep modification (configuration, database model, repository selection ui).

However, this is a good idea. I don't know if I'll get time to work on it.

@spyhunter99
Copy link

This would also be awesome for me too. Specifically, I have a use case where i'd like to use artifact listeners capabilities while connected to a private nexus server that requires authentication. How does the sync job actually work? Is it a periodic cron job that hits the search api and scans for deltas? Or does it screen scrape via directory browsing to build an index then compare for deltas?

@lalmeras
Copy link
Member

Currently, we use search.maven.org APIs and periodically scan the artifacts marked as followed in the database by the users. This is done in MavenCentralSearchApiArtifactVersionProviderServiceImpl and MavenCentralSearchApiServiceImpl.

There is an alternate implementation relying on raw maven repositories in MavenRepositoryArtifactVersionProviderServiceImpl (not currenlty used).

As Nexus provides REST API, I think a dedicated implementation should be easy to write. For the authentication part, if it is basic authentication, it should be easy to add this functionnality to the HTTP connection layer.

I think that it is easy to build a working prototype and I can help, but I won't be able to do it myself in the short term.

A simple thing to try is to modify the repository.sync.*.url properties in configuration.properties file (see value examples in development.properties; you should try http://user:password@host syntax for authentication), comment @service in MavenCentralSearchApiArtifactVersionProviderServiceImpl and uncomment @service in MavenRepositoryArtifactVersionProviderServiceImpl. If authentication is correctly handled by HTTP layer, it should work for artifact version checking.

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

3 participants