-
Notifications
You must be signed in to change notification settings - Fork 81
Plugin fails on big(?) files in diff with "Unable to get Stash differential report from Stash" #151
Description
Hi,
we have encountered a problem with the plugin in version 1.3. When it tries to receive the diff from Stash, it fails with an exception:
[ERROR] 16:12:39.722 Unable to get Stash differential report from Stash
org.sonar.plugins.stash.exceptions.StashClientException: java.util.concurrent.ExecutionException: java.util.zip.DataFormatException: invalid stored block lengths
at org.sonar.plugins.stash.client.StashClient.performRequest(StashClient.java:299)
at org.sonar.plugins.stash.client.StashClient.get(StashClient.java:258)
at org.sonar.plugins.stash.client.StashClient.getPullRequestDiffs(StashClient.java:142)
at org.sonar.plugins.stash.StashRequestFacade.getPullRequestDiffReport(StashRequestFacade.java:345)
We assume this is due to a big file in the diff. The file is ~ 5000 lines and is reformatted so in sum we are talking about ~10000 lines. Also when we try to get the pull request via browser it does not work.
As such we are unsure what the problem is, so we decided to report this issue in case somebody has a clue here.
Some more details:
The failure itself comes from netty: "Unexpected I/O exception on channel" as one can see when adding -X to the command line.
It might just be a timeout happeing here. But we are not so familiar with netty:
(removed hostnames/IPs/etc ..)
[DEBUG] 16:12:39.715 Unexpected I/O exception on channel [..]
java.util.zip.DataFormatException: invalid stored block lengths
at java.util.zip.Inflater.inflateBytes(Native Method)
at java.util.zip.Inflater.inflate(Inflater.java:259)
at io.netty.handler.codec.compression.JdkZlibDecoder.decode(JdkZlibDecoder.java:188)
at io.netty.handler.codec.ByteToMessageDecoder.callDecode(ByteToMessageDecoder.java:411)
at io.netty.handler.codec.ByteToMessageDecoder.channelRead(ByteToMessageDecoder.java:248)
at io.netty.channel.AbstractChannelHandlerContext.invokeChannelRead(AbstractChannelHandlerContext.java:357)
..
[DEBUG] 16:12:39.716 Closing Channel [..]
[DEBUG] 16:12:39.718 Aborting Future NettyResponseFuture{currentRetry=0,
isDone=0,
isCancelled=0,
asyncHandler=org.asynchttpclient.AsyncCompletionHandlerBase@c9069ae,
nettyRequest=org.asynchttpclient.netty.request.NettyRequest@3c1d273a,
future=java.util.concurrent.CompletableFuture@7434f9b7[Not completed, 1 dependents],
uri=https://../stash/rest/api/1.0/projects/../repos/../pull-requests/29/diff?withComments=true,
keepAlive=true,
redirectCount=0,
timeoutsHolder=org.asynchttpclient.netty.timeout.TimeoutsHolder@2aa24c9,
inAuth=0,
statusReceived=1,
touch=1506348759715}