Bug 1018220 - A deployment unit for uploaded kjar is not created due to negative number of transferred bytes
Summary: A deployment unit for uploaded kjar is not created due to negative number of ...
Keywords:
Status: CLOSED NOTABUG
Alias: None
Product: JBoss BRMS Platform 6
Classification: Retired
Component: Business Central
Version: 6.0.0
Hardware: Unspecified
OS: Unspecified
high
high
Target Milestone: ER5
: 6.0.0
Assignee: Toni Rikkola
QA Contact: Ivo Bek
URL:
Whiteboard:
Depends On:
Blocks: 1019854
TreeView+ depends on / blocked
 
Reported: 2013-10-11 13:38 UTC by Ivo Bek
Modified: 2013-12-13 12:02 UTC (History)
2 users (show)

Fixed In Version:
Doc Type: Bug Fix
Doc Text:
Clone Of:
Environment:
Last Closed: 2013-12-13 12:02:20 UTC
Type: Bug
Embargoed:


Attachments (Terms of Use)
reproducer, the kjar (8.95 KB, application/x-java-archive)
2013-10-11 13:38 UTC, Ivo Bek
no flags Details
server log containing the exceptions (11.20 KB, text/x-log)
2013-10-11 13:40 UTC, Ivo Bek
no flags Details

Description Ivo Bek 2013-10-11 13:38:08 UTC
Created attachment 811112 [details]
reproducer, the kjar

Description of problem:

It's not possible to create a deployment unit for the attached kjar. Any attempt causes "java.lang.IllegalArgumentException: number of transferred bytes cannot be negative".

How reproducible:

configuration: install bpms-6.0.ER3 with eap 6.1.0.

Steps to Reproduce:
1. upload the attached kjar
2. notice following output in server log:

14:42:29,854 INFO  [stdout] (http-localhost/127.0.0.1:8080-2) GROUP_ID:
14:42:29,854 INFO  [stdout] (http-localhost/127.0.0.1:8080-2) ARTIFACT_ID:
14:42:29,854 INFO  [stdout] (http-localhost/127.0.0.1:8080-2) VERSION_ID:

3. create the deployment unit because it's probably not created during the upload of kjar:

groupId = org.jboss
artifactId = test-remote-file-deployment
version = 1.0-SNAPSHOT

4. see exceptions in server log

Comment 1 Ivo Bek 2013-10-11 13:40:00 UTC
Created attachment 811113 [details]
server log containing the exceptions

Comment 3 Ivo Bek 2013-12-05 13:54:22 UTC
I figured out that this issue is met when the dependencies cannot be found. This part will need some improvements for which I'll file new BZs. I had to do the changes in dependencies because I had the same issue also in BPMS 6.0.0.ER5 and some other kjars worked and the difference was just in the dependencies.

Toni, do you agree to close this BZ as not a bug? or did you make any important changes because of this bug? The changes for this BZ 1018209 worked well but I'm not sure whether they should also influence this issue as well.

Comment 4 Toni Rikkola 2013-12-10 10:58:32 UTC
(In reply to Ivo Bek from comment #3)
> I figured out that this issue is met when the dependencies cannot be found.
> This part will need some improvements for which I'll file new BZs. I had to
> do the changes in dependencies because I had the same issue also in BPMS
> 6.0.0.ER5 and some other kjars worked and the difference was just in the
> dependencies.
> 
> Toni, do you agree to close this BZ as not a bug? or did you make any
> important changes because of this bug? The changes for this BZ 1018209
> worked well but I'm not sure whether they should also influence this issue
> as well.

I just did a small change for the InputStream and got this to work. I think this didn't actually fix this BZ, just at that point it allowed us to cheat a jar that had no dependencies into the repository.

After talking with Mario Fusco, I think you are right. This is not a bug, we should just inform the user in a smarter way that a jar that can not find it's dependencies can not be uploaded.


Commit for this BZ was this:
https://github.com/droolsjbpm/guvnor/commit/6ad803cb7d3faa4b9496e63a74d107a05ad68c8e

Comment 5 Ivo Bek 2013-12-13 12:02:20 UTC
Toni, thank you .. I have created this BZ 1042789 for the change how to inform a user more clearly about the missing dependencies. So, I'm closing this bug as a not bug then.


Note You need to log in before you can comment on or make changes to this bug.