Maven SCM
  1. Maven SCM
  2. SCM-483

Update SCM Perforce Provider to use P4Java

    Details

    • Type: Improvement Improvement
    • Status: Open Open
    • Priority: Major Major
    • Resolution: Unresolved
    • Affects Version/s: 1.2
    • Fix Version/s: future
    • Labels:
      None
    • Complexity:
      Intermediate
    • Number of attachments :
      1

      Description

      Perforce has developed a new Java Native API for access to perforce called P4Java. You can access it here: ftp://ftp.perforce.com/perforce/r09.1/bin.java/p4java.zip. This completely reworked API does not require that the p4 client be installed on the system. The SCM Perforce Provider should be modified to use this new native java API to eliminate the many issues involved with depending on the p4 executable.

        Issue Links

          Activity

          Hide
          Aaron Johnson added a comment -

          I have implemented an SCM Provider using the p4java APIs. Not everything is implemented but I have been able to prepare/preform releases from Continuum and the Release Plugin.

          Show
          Aaron Johnson added a comment - I have implemented an SCM Provider using the p4java APIs. Not everything is implemented but I have been able to prepare/preform releases from Continuum and the Release Plugin.
          Hide
          Olivier Lamy added a comment -

          is the p4java available in central repo ? If not it will be difficult to add this in ASF code base.
          Thanks

          Show
          Olivier Lamy added a comment - is the p4java available in central repo ? If not it will be difficult to add this in ASF code base. Thanks
          Hide
          Evgeny Mandrikov added a comment -

          As I know p4java not available in central repo. But why not upload it?

          Show
          Evgeny Mandrikov added a comment - As I know p4java not available in central repo. But why not upload it?
          Hide
          Aaron Johnson added a comment -

          Because you can't just "upload it". Read: http://maven.apache.org/guides/mini/guide-central-repository-upload.html.

          There are also other issues with the p4java implementation that may not be acceptable to the Maven SCM project. These are listed in the "Known Limitations" section of the p4java release notes: http://www.perforce.com/perforce/doc.093/user/p4javanotes.txt

          Show
          Aaron Johnson added a comment - Because you can't just "upload it". Read: http://maven.apache.org/guides/mini/guide-central-repository-upload.html . There are also other issues with the p4java implementation that may not be acceptable to the Maven SCM project. These are listed in the "Known Limitations" section of the p4java release notes: http://www.perforce.com/perforce/doc.093/user/p4javanotes.txt
          Hide
          Brian Jackson added a comment -

          Aaron, the Sonatype guys have simplified the process of getting artifacts into Central and Tim O'Brien wrote a great post on the process:

          http://www.sonatype.com/people/2010/04/uploading-artifacts-to-the-central-maven-repository-diy/

          I'll be glad to take the time to follow this post to get p4java in Central, unless you want to do it.

          Show
          Brian Jackson added a comment - Aaron, the Sonatype guys have simplified the process of getting artifacts into Central and Tim O'Brien wrote a great post on the process: http://www.sonatype.com/people/2010/04/uploading-artifacts-to-the-central-maven-repository-diy/ I'll be glad to take the time to follow this post to get p4java in Central, unless you want to do it.
          Hide
          Aaron Johnson added a comment -

          If you are willing to do it, go for it. I don't have an account for that repository.

          Show
          Aaron Johnson added a comment - If you are willing to do it, go for it. I don't have an account for that repository.
          Hide
          Brian Jackson added a comment -

          I've got the p4java jar staged. Aaron can you take a look and sanity check that everything is in order before I release it to Central?

          https://oss.sonatype.org/content/repositories/comperforce-362/

          Since its closed source, but the sources jar is a requirement, I've staged an empty sources jar on purpose. I spoke with Jason van Zyl and he state that as long as the license allows for redistribution of binaries then its not a problem.

          The conversation ended here:
          http://twitter.com/jaxzin/status/20516410745

          Show
          Brian Jackson added a comment - I've got the p4java jar staged. Aaron can you take a look and sanity check that everything is in order before I release it to Central? https://oss.sonatype.org/content/repositories/comperforce-362/ Since its closed source, but the sources jar is a requirement, I've staged an empty sources jar on purpose. I spoke with Jason van Zyl and he state that as long as the license allows for redistribution of binaries then its not a problem. The conversation ended here: http://twitter.com/jaxzin/status/20516410745
          Hide
          Brian Jackson added a comment -

          Actually, I had to release it so Sonatype could review it before they turn on the auto-sync to Central. Its now available at the following link before its on its way to Central.

          https://oss.sonatype.org/content/groups/public/com/perforce/p4java/2009.3/

          Show
          Brian Jackson added a comment - Actually, I had to release it so Sonatype could review it before they turn on the auto-sync to Central. Its now available at the following link before its on its way to Central. https://oss.sonatype.org/content/groups/public/com/perforce/p4java/2009.3/
          Hide
          Brian Jackson added a comment -

          P4Java jar is now available in Maven Central: http://repo1.maven.org/maven2/com/perforce/p4java/2009.3/

          <dependency>
            <groupId>com.perforce</groupId>
            <artifactId>p4java</artifactId>
            <version>2009.3</version>
          </dependency>
          
          Show
          Brian Jackson added a comment - P4Java jar is now available in Maven Central: http://repo1.maven.org/maven2/com/perforce/p4java/2009.3/ <dependency> <groupId>com.perforce</groupId> <artifactId>p4java</artifactId> <version>2009.3</version> </dependency>
          Hide
          Aaron Johnson added a comment -

          Is there anything else that needs to be done before someone can be assigned this to work?

          Show
          Aaron Johnson added a comment - Is there anything else that needs to be done before someone can be assigned this to work?
          Hide
          Evgeny Mandrikov added a comment - - edited

          Aaron, I've looked a bit on your patch and I think that this patch requires a lot of refactoring.
          Brian, Thank you for your effort.

          Show
          Evgeny Mandrikov added a comment - - edited Aaron, I've looked a bit on your patch and I think that this patch requires a lot of refactoring. Brian, Thank you for your effort.
          Hide
          Aaron Johnson added a comment -

          I'm not an expert in the design of the Maven SCM Provider project. I still think that using the Java API that Perforce has developed is a good change for the project. What refactoring is required for this to fit into the current provider design?

          Show
          Aaron Johnson added a comment - I'm not an expert in the design of the Maven SCM Provider project. I still think that using the Java API that Perforce has developed is a good change for the project. What refactoring is required for this to fit into the current provider design?
          Hide
          Brian Jackson added a comment -

          I've just found out that Perforce has implemented a Maven SCM provider for Perforce on top of their p4java API. But they only offer it as a download you need to manually install into your own Maven repository.

          http://www.perforce.com/perforce/doc.current/manuals/p4maven/index.html

          Show
          Brian Jackson added a comment - I've just found out that Perforce has implemented a Maven SCM provider for Perforce on top of their p4java API. But they only offer it as a download you need to manually install into your own Maven repository. http://www.perforce.com/perforce/doc.current/manuals/p4maven/index.html
          Hide
          Evgeny Mandrikov added a comment -

          Hi Brian,
          Indeed - this is an interesting info.
          BTW, do you know reasons why it can't be uploaded to Maven Central repository?

          Show
          Evgeny Mandrikov added a comment - Hi Brian, Indeed - this is an interesting info. BTW, do you know reasons why it can't be uploaded to Maven Central repository?
          Hide
          Brian Jackson added a comment -

          Done. Waiting for Sonatype admins to approve it and promote it to Maven Central. Should be within 24 hours.

          Show
          Brian Jackson added a comment - Done. Waiting for Sonatype admins to approve it and promote it to Maven Central. Should be within 24 hours.
          Hide
          Evgeny Mandrikov added a comment -

          Cool! Thank you.

          Show
          Evgeny Mandrikov added a comment - Cool! Thank you.
          Hide
          Brian Jackson added a comment -

          Sorry for the long delay, I missed a step with releasing this. It is now available in Maven Central.

          Show
          Brian Jackson added a comment - Sorry for the long delay, I missed a step with releasing this. It is now available in Maven Central.
          Hide
          Olivier Lamy added a comment -

          what is the license ? the pom http://repo1.maven.org/maven2/com/perforce/p4java/2011.1.297684/p4java-2011.1.297684.pom has a strange value for the licence url.

          Show
          Olivier Lamy added a comment - what is the license ? the pom http://repo1.maven.org/maven2/com/perforce/p4java/2011.1.297684/p4java-2011.1.297684.pom has a strange value for the licence url.
          Hide
          Brian Jackson added a comment -

          It's deployed together with the artifact (aka. the URL is relative):

          http://repo1.maven.org/maven2/com/perforce/p4java/2011.1.297684/p4java-2011.1.297684-license.txt

          Show
          Brian Jackson added a comment - It's deployed together with the artifact (aka. the URL is relative): http://repo1.maven.org/maven2/com/perforce/p4java/2011.1.297684/p4java-2011.1.297684-license.txt

            People

            • Assignee:
              Unassigned
              Reporter:
              Tom Rodriguez
            • Votes:
              7 Vote for this issue
              Watchers:
              8 Start watching this issue

              Dates

              • Created:
                Updated: