0

I have many packages within one group id.

my main group id is: com.github.kondaurovdev

i've subgroups: com.github.kondaurovdev.snippets com.github.kondaurovdev.akka_http ...

I don't want to create many packages in bintray, because i will have to wait approve to link package to jcenter.

So i found a "solution". There is a merge button in Bintray UI, you can select all packages with the same group id and have one package with many subpackages. You can link this package only once and your packages will be downloadable with JCenter repo. That's cool!

But i don't want to merge everytime. I would like to publish my subpackages right into parent package. Is this possible?

I'm using sbt-bintray to upload artifacts, but it always create new package and uploads content.

Alexander Kondaurov
  • 3,677
  • 5
  • 42
  • 64

1 Answers1

7

The rule of thumb for deciding whether some artifact_ids should be merged into a single package is:

  1. The projects are submodules of a single project, and
  2. The projects are released together

Let me give you couple of examples that will show what I mean. I'll use Spring Framework projects, that are fairly known and diverse.

  1. spring-context and spring-beans artifact ids are merged to the same Bintray package. They are related (part of the core Spring DI project) and they are released together (4.3.6.RELEASE for example). They are part of the same Bintray project - spring.framework.
  2. spring-batch-core has very little to do with the Spring DI project, so despite they share the group-id org.springframework they are in different packages in Bintray.
  3. Different sub-projects of Spring Data are, of course, related, but they have different release versions and different release schedule. For example, while Spring Data Commons is version 1.11.4, Spring Data JPA is version 1.9.4. So, although those projects are related, they can't possibly be in the same package, because if they share the same package, by the time Data JPA will reach 1.11, the version will be already read-only, because Data Commons 1.11 was released long time ago.

I hope that makes sense.

Now, to your practical issues. I apologize you have to wait for a long time to inclusion requests. Feel free to contact me personally (@jbaruch) if you feel it's been too long, and I'll be happy to check what's going on. Saying that, the inclusion request is one-time procedure per package. How often do you introduce a new package?

As I mentioned, it is very likely, that you have artifact ids that should be merged to the same package (but please play by the rules, explained above). In that case, you can specify the broader package in your 'build.sbt' publishTo setting, as in this example.

JBaruch
  • 22,610
  • 5
  • 62
  • 90