[ 
https://issues.apache.org/jira/browse/FLINK-19331?page=com.atlassian.jira.plugin.system.issuetabpanels:comment-tabpanel&focusedCommentId=17207836#comment-17207836
 ] 

Robert Metzger commented on FLINK-19331:
----------------------------------------

This has been merged to master in 
https://github.com/apache/flink/commit/dad729752ee43d95d47ba079b5ea2cfb6f6ca22c.
Closing ticket.

> State processor api has native resouce leak when working with RocksDB
> ---------------------------------------------------------------------
>
>                 Key: FLINK-19331
>                 URL: https://issues.apache.org/jira/browse/FLINK-19331
>             Project: Flink
>          Issue Type: Bug
>          Components: API / State Processor
>    Affects Versions: 1.12.0
>            Reporter: Seth Wiesman
>            Assignee: Seth Wiesman
>            Priority: Major
>              Labels: pull-request-available
>
> State processor api uses AbstractStateBackend#getKeys and 
> AbstractStateBackend#getKeysAndNamespaces to iterate over keys and namespaces 
> in a savepoint. These methods return java.util.stream.Stream. The 
> RocksDBKeyedStateBackend implemention of these methods use streams onClose 
> callback to free native resources. 
> However, spa eagerly turns this stream into an iterator. This causes the 
> onClose method to be discarded leading to a native resource leak. This can 
> lead to a segmentation fault when multiple spa jobs are submitted to the same 
> session cluster. 



--
This message was sent by Atlassian Jira
(v8.3.4#803005)

Reply via email to