5 Replies Latest reply on Jan 19, 2015 1:36 AM by sanjay05222

    Not able to "Build and Deploy" a project from the cloned repository

    waghvikrant

      Hi,

      I have cloned a project inside jBPM Web Designer. I am able to access the project files in the Project Authoring but whenever I try to Build and Deploy, the operation fails popping up a message "Unable to complete your request. The following exception occurred: number of transferred bytes cannot be negative."

      In the server log, this error is shown as Exception in thread "FileRepositoryConnector-1" java.lang.IllegalArgumentException: number of transferred bytes cannot be negative. This is followed by many errors.

      I have also copied the required settings.xml at location C:\Users\Administrator\.m2 which is the maven repo location for jbpm.

      I am attaching the complete server log.

      Any help would be appreciated.

        • 1. Re: Not able to "Build and Deploy" a project from the cloned repository
          salaboy21

          That should only happen with the Customer Relationship Project and that's due the fact that you need to compile and install into your maven repository the customer-services-workitem project first, so maven can resolve that dependency when it's building the project. You shouldn't experience any issue with the other two projects hosted in the jbpm playground repository.

          • 2. Re: Not able to "Build and Deploy" a project from the cloned repository
            waghvikrant

            Thanks for you reply.

            I am not trying to build the projects from jbpm-playground repository. I have cloned the repository from my company's server. We are switching to jBPM 6. I am trying to build and deploy those bpmn processes inside the kie-wb Web designer.

            • 3. Re: Not able to "Build and Deploy" a project from the cloned repository
              swiderski.maciej

              most likely the issues are caused by not being able to find the artifacts defined as dependencies in pom.xml. Maybe you don't have repositories configured in pom.xml of the project you're trying to deploy and thus maven resolution is failing.

               

              HTH

              • 4. Re: Not able to "Build and Deploy" a project from the cloned repository
                salaboy21

                You can try imitating the project structure that we are proposing in the jbpm-playground repository for your projects.

                We have the following:

                1) Kjar, for example: customer-relationship/ project

                2) Workitems and services: customer-relationship-workitems/ project

                3) Tests: test the process with CDI and No CDI. -> This allows us to remove all the test dependencies from the KJar so it build and deploy faster without much dependency resolution for the project itself.

                Take a look at the refactored projects:

                 

                https://github.com/droolsjbpm/jbpm-playground

                • 5. Re: Not able to "Build and Deploy" a project from the cloned repository
                  sanjay05222

                  Mauricio Salatino wrote:

                   

                  You can try imitating the project structure that we are proposing in the jbpm-playground repository for your projects.

                  We have the following:

                  1) Kjar, for example: customer-relationship/ project

                  2) Workitems and services: customer-relationship-workitems/ project

                  3) Tests: test the process with CDI and No CDI. -> This allows us to remove all the test dependencies from the KJar so it build and deploy faster without much dependency resolution for the project itself.

                  Take a look at the refactored projects:

                   

                  https://github.com/droolsjbpm/jbpm-playground

                  Hi @Mauricio Salatino Please let me know if there was any update on this JIRA issue [JBPM-4202] Unable to deploy a project (kjar) with dependencies in the pom to jbpm 6-console - JBoss Issue Tracker

                  I dont think so that it is solved yet . is this a valid JIRA ? or it is just lying there ? I am also facing similar issue

                  Steps to reproduce are as below .

                  1. Got to Artifacts Repository and then upload the pojos.jar for which your process will need the pojos let say for data transfer between the various tasks like Data Model.

                  2. Open the project in kie work bench and then go to project editor select from the drop down the add dependencies and then select the polos.jar as dependencies.

                  3. Save the Project and then Try to build you will get the same error .

                  Work around had been that now I pack pojos along with the kie project side by side the data modeler.


                  22:13:32,717 ERROR [stderr] (FileRepositoryConnector-1) Exception in thread "FileRepositoryConnector-1" java.lang.IllegalArgumentException: number of transferred bytes cannot be negative

                  22:13:32,718 ERROR [stderr] (FileRepositoryConnector-1)         at org.sonatype.aether.util.listener.DefaultTransferEvent.setTransferredBytes(DefaultTransferEvent.java:123)

                  22:13:32,719 ERROR [stderr] (FileRepositoryConnector-1)         at org.sonatype.aether.connector.file.FileRepositoryWorker.run(FileRepositoryWorker.java:299)

                  22:13:32,714 ERROR [org.guvnor.common.services.builder.BuildServiceImpl] (default task-24) number of transferred bytes cannot be negative: java.lang.IllegalArgumentException: number of transferred byt

                  es cannot be negative

                          at org.sonatype.aether.util.listener.DefaultTransferEvent.setTransferredBytes(DefaultTransferEvent.java:123) [aether-util-1.13.1.jar:]

                          at org.sonatype.aether.connector.file.FileRepositoryWorker.run(FileRepositoryWorker.java:299) [aether-connector-file-1.13.1.jar:]

                          at org.sonatype.aether.util.concurrency.RunnableErrorForwarder$1.run(RunnableErrorForwarder.java:60) [aether-util-1.13.1.jar:]

                          at java.util.concurrent.ThreadPoolExecutor.runWorker(ThreadPoolExecutor.java:1145) [rt.jar:1.7.0_71]

                          at java.util.concurrent.ThreadPoolExecutor$Worker.run(ThreadPoolExecutor.java:615) [rt.jar:1.7.0_71]

                          at java.lang.Thread.run(Thread.java:745) [rt.jar:1.7.0_71]

                   

                   

                  Thanks

                  Sanjay Gautam