You are viewing a plain text version of this content. The canonical link for it is here.
Posted to issues@flink.apache.org by "ASF GitHub Bot (JIRA)" <ji...@apache.org> on 2018/03/22 16:12:00 UTC
[jira] [Commented] (FLINK-9057) NPE in
CreditBasedSequenceNumberingViewReader when cancelling before initilization
was complete
[ https://issues.apache.org/jira/browse/FLINK-9057?page=com.atlassian.jira.plugin.system.issuetabpanels:comment-tabpanel&focusedCommentId=16409786#comment-16409786 ]
ASF GitHub Bot commented on FLINK-9057:
---------------------------------------
GitHub user NicoK opened a pull request:
https://github.com/apache/flink/pull/5747
[FLINK-9057][network] fix an NPE when cleaning up before requesting a subpartition view
## What is the purpose of the change
In `PartitionRequestServerHandler`, the view reader is created and immediately afterwards added to the `PartitionRequestQueue` which would attempt a cleanup of the view reader's subpartition view. This view, however, is currently only created after adding the reader to the `PartitionRequestQueue` and may thus result in a `NullPointerException` if the cleanup happens very early in the initialization phase, e.g. due to failures.
## Brief change log
- call `NetworkSequenceViewReader#requestSubpartitionView` before calling `PartitionRequestQueue#notifyReaderCreated()`
## Verifying this change
This change is a trivial rework / code cleanup without any test coverage.
## Does this pull request potentially affect one of the following parts:
- Dependencies (does it add or upgrade a dependency): **no**
- The public API, i.e., is any changed class annotated with `@Public(Evolving)`: **no**
- The serializers: **no**
- The runtime per-record code paths (performance sensitive): **no**
- Anything that affects deployment or recovery: JobManager (and its components), Checkpointing, Yarn/Mesos, ZooKeeper: **no**
- The S3 file system connector: **no**
## Documentation
- Does this pull request introduce a new feature? **no**
- If yes, how is the feature documented? **not applicable**
You can merge this pull request into a Git repository by running:
$ git pull https://github.com/NicoK/flink flink-9057
Alternatively you can review and apply these changes as the patch at:
https://github.com/apache/flink/pull/5747.patch
To close this pull request, make a commit to your master/trunk branch
with (at least) the following in the commit message:
This closes #5747
----
commit 3a34531f8d5fd2c4e71102f2d9d66105e55eb697
Author: Nico Kruber <ni...@...>
Date: 2018-03-22T12:49:45Z
[hotfix][tests] add a name to the parameter of RescalingITCase
commit 2e909f085bbc90f406eeae16efda15254c296c0e
Author: Nico Kruber <ni...@...>
Date: 2018-03-22T12:50:07Z
[FLINK-9057][network] fix an NPE when cleaning up before requesting a subpartition view
----
> NPE in CreditBasedSequenceNumberingViewReader when cancelling before initilization was complete
> -----------------------------------------------------------------------------------------------
>
> Key: FLINK-9057
> URL: https://issues.apache.org/jira/browse/FLINK-9057
> Project: Flink
> Issue Type: Bug
> Components: Network
> Affects Versions: 1.5.0, 1.6.0
> Reporter: Nico Kruber
> Assignee: Nico Kruber
> Priority: Blocker
> Fix For: 1.5.0
>
>
> {{RescalingITCase}} unveiled an exception which may occur when shutting down before completely initializing the network stack:
> https://travis-ci.org/apache/flink/jobs/356612100
> {code}
> 01:08:13,458 WARN org.apache.flink.shaded.netty4.io.netty.channel.DefaultChannelPipeline - An exception was thrown by a user handler's exceptionCaught() method while handling the following exception:
> java.lang.NullPointerException
> at org.apache.flink.runtime.io.network.netty.CreditBasedSequenceNumberingViewReader.releaseAllResources(CreditBasedSequenceNumberingViewReader.java:192)
> at org.apache.flink.runtime.io.network.netty.PartitionRequestQueue.releaseAllResources(PartitionRequestQueue.java:322)
> at org.apache.flink.runtime.io.network.netty.PartitionRequestQueue.channelInactive(PartitionRequestQueue.java:298)
> at org.apache.flink.shaded.netty4.io.netty.channel.AbstractChannelHandlerContext.invokeChannelInactive(AbstractChannelHandlerContext.java:237)
> at org.apache.flink.shaded.netty4.io.netty.channel.AbstractChannelHandlerContext.fireChannelInactive(AbstractChannelHandlerContext.java:223)
> at org.apache.flink.shaded.netty4.io.netty.channel.ChannelInboundHandlerAdapter.channelInactive(ChannelInboundHandlerAdapter.java:75)
> at org.apache.flink.shaded.netty4.io.netty.channel.AbstractChannelHandlerContext.invokeChannelInactive(AbstractChannelHandlerContext.java:237)
> at org.apache.flink.shaded.netty4.io.netty.channel.AbstractChannelHandlerContext.fireChannelInactive(AbstractChannelHandlerContext.java:223)
> at org.apache.flink.shaded.netty4.io.netty.channel.ChannelInboundHandlerAdapter.channelInactive(ChannelInboundHandlerAdapter.java:75)
> at org.apache.flink.shaded.netty4.io.netty.channel.AbstractChannelHandlerContext.invokeChannelInactive(AbstractChannelHandlerContext.java:237)
> at org.apache.flink.shaded.netty4.io.netty.channel.AbstractChannelHandlerContext.fireChannelInactive(AbstractChannelHandlerContext.java:223)
> at org.apache.flink.shaded.netty4.io.netty.handler.codec.ByteToMessageDecoder.channelInactive(ByteToMessageDecoder.java:294)
> at org.apache.flink.shaded.netty4.io.netty.channel.AbstractChannelHandlerContext.invokeChannelInactive(AbstractChannelHandlerContext.java:237)
> at org.apache.flink.shaded.netty4.io.netty.channel.AbstractChannelHandlerContext.fireChannelInactive(AbstractChannelHandlerContext.java:223)
> at org.apache.flink.shaded.netty4.io.netty.channel.DefaultChannelPipeline.fireChannelInactive(DefaultChannelPipeline.java:829)
> at org.apache.flink.shaded.netty4.io.netty.channel.AbstractChannel$AbstractUnsafe$7.run(AbstractChannel.java:610)
> at org.apache.flink.shaded.netty4.io.netty.util.concurrent.SingleThreadEventExecutor.runAllTasks(SingleThreadEventExecutor.java:357)
> at org.apache.flink.shaded.netty4.io.netty.channel.nio.NioEventLoop.run(NioEventLoop.java:357)
> at org.apache.flink.shaded.netty4.io.netty.util.concurrent.SingleThreadEventExecutor$2.run(SingleThreadEventExecutor.java:111)
> at java.lang.Thread.run(Thread.java:748)
> {code}
--
This message was sent by Atlassian JIRA
(v7.6.3#76005)