j2objc-contrib / j2objc-common-libs-e2e-test

End-to-end tests for translating, compiling, and linking common Java libraries into Objective C using j2objc
https://github.com/j2objc-contrib
Apache License 2.0
12 stars 5 forks source link

org.apache.commons:commons-lang3 - J2ObjC continuous build #10

Closed brunobowden closed 8 years ago

brunobowden commented 8 years ago

Java utility classes for the classes that are in java.lang's hierarchy.

@britter, @joehni - FYI for you both. This is to support translation of your Java library to Objective-C such that it can be used on iOS. This bug is specifically for testing this as part of a continuous build using Google's J2ObjC conversion tool.

@advayDev1 FYI

britter commented 8 years ago

@brunobowden Thanks for the heads up. Just to make this clear: Apache Commons Lang is not owned by @joehni or me. It's a product of the Apache Software Foundation. If you want to get in touch with the community about this, you can post to the dev mailing list.

brunobowden commented 8 years ago

@britter - fair point. I think the Apache Foundation does a lot of great work. I didn't mean to imply this was somehow "your library". Thanks for all your contributions to it though.

britter commented 8 years ago

@brunobowden just wanted to make that clear. Awesome that you chose some of the commons libraries for this project. Thank you!

brunobowden commented 8 years ago

@britter - I had two questions if I may. I realize that this doesn't concern commons-lang3 specifically but I'd appreciate any insights from you. I've been searching around online for both questions and haven't found any

Package Naming Do you know why there are two commons-io packages? That is: commons-io:commons-io (up to version 2.4) and also org.apache.commons:commons-io (no longer updated, limited to version 1.3.2)? It's confusing to say the least.

https://bintray.com/bintray/jcenter/commons-io:commons-io https://bintray.com/bintray/jcenter/org.apache.commons:commons-io

test-sources.jar Some of the packages distributed test source, e.g. commons-io-2.4-test-sources.jar. It seems that the Apache packages are fairly consistent about having a test-sources jar but other packages not so much. Do you know how common this is for Apache packages? Are there any evolving standards on this? We need the test sources to build and run all the unit tests, which are an important part of having confidence that the translated code works correctly.

britter commented 8 years ago

@britter - I had two questions if I may.

Sure! :-)

Do you know why there are two commons-io packages? That is: commons-io:commons-io (up to version 2.4) and also org.apache.commons:commons-io (no longer updated, limited to version 1.3.2)? It's confusing to say the least.

That's probably for historical reasons. Usually most of the older Apache Commons components started with a schema like commons-name:commons-name for version 1.x. After the move to version 2.0 we started to use the org.apache.commons group ID. Further more we add the major version number to the artifact ID so that you can have two versions of the same component pulled in via maven. That's why Apache Commons Lang's coordinates are org.apache.commons:commons-lang3:3.x I don't know why it's the other way around for commons-io...

Some of the packages distributed test source, e.g. commons-io-2.4-test-sources.jar. It seems that the Apache packages are fairly consistent about having a test-sources jar but other packages not so much.

The test sources jar contains the test source code. We have that configured somewhere in our parent pom.

Do you know how common this is for Apache packages? Are there any evolving standards on this?

I don't know how common that is among all java based Apache projects. At least we do it for all Apache Commons components. There is no standard for this. I think the default for maven is to just deploy the jar and some meta data files.

We need the test sources to build and run all the unit tests, which are an important part of having confidence that the translated code works correctly.

All Apache projects are open source. If a project does not deploy test sources to maven central, you can always check out the latest code and build everything from scratch. A list of all Apache projects can be found here. Most of them are also mirrored to github.

HTH, Benedikt

joehni commented 8 years ago

The publishing of org.apache.commons:commons-io:1.3.2 was by accident. Look at the pom of that version and you'll detect that even that one refers commons-io as groupId.

brunobowden commented 8 years ago

Thanks, that's helpful to understand.