apex-dev mailing list archives

Site index · List index
Message view « Date » · « Thread »
Top « Date » · « Thread »
From "ASF GitHub Bot (JIRA)" <j...@apache.org>
Subject [jira] [Commented] (APEXMALHAR-2136) Null pointer exception in AbstractManagedStateImpl
Date Thu, 07 Jul 2016 07:12:11 GMT

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

ASF GitHub Bot commented on APEXMALHAR-2136:
--------------------------------------------

Github user chaithu14 commented on a diff in the pull request:

    https://github.com/apache/apex-malhar/pull/334#discussion_r69860038
  
    --- Diff: library/src/main/java/org/apache/apex/malhar/lib/state/managed/AbstractManagedStateImpl.java
---
    @@ -203,7 +203,12 @@ public void setup(OperatorContext context)
           //delete all the wal files with windows > activationWindow.
           //All the wal files with windows <= activationWindow are loaded and kept separately
as recovered data.
           try {
    -        for (long recoveredWindow : checkpointManager.getWindowIds(operatorContext.getId()))
{
    +        long[] recoveredWindows = checkpointManager.getWindowIds(operatorContext.getId());
    +        if (recoveredWindows == null) {
    +          readerService = Executors.newFixedThreadPool(numReaders, new NameableThreadFactory("managedStateReaders"));
    +          return;
    +        }
    +        for (long recoveredWindow : recoveredWindows) {
    --- End diff --
    
    Done


> Null pointer exception in AbstractManagedStateImpl
> --------------------------------------------------
>
>                 Key: APEXMALHAR-2136
>                 URL: https://issues.apache.org/jira/browse/APEXMALHAR-2136
>             Project: Apache Apex Malhar
>          Issue Type: Bug
>            Reporter: Chaitanya
>            Assignee: Chaitanya
>
> Null pointed exception in AbstractManagedStateImpl during recovering the state:
> java.lang.NullPointerException
>         at org.apache.apex.malhar.lib.state.managed.AbstractManagedStateImpl.setup(AbstractManagedStateImpl.java:206)
>         at com.examples.app.ManagedTimeStateMImpl.setup(ManagedTimeStateMImpl.java:15)
>         at com.examples.app.ManagedStateIntOperator.setup(ManagedStateIntOperator.java:138)
>         at com.examples.app.ManagedStateIntOperator.setup(ManagedStateIntOperator.java:26)
>         at com.datatorrent.stram.engine.Node.setup(Node.java:187)
>         at com.datatorrent.stram.engine.StreamingContainer.setupNode(StreamingContainer.java:1309)
>         at com.datatorrent.stram.engine.StreamingContainer.access$100(StreamingContainer.java:130)
>         at com.datatorrent.stram.engine.StreamingContainer$2.run(StreamingContainer.java:1388)



--
This message was sent by Atlassian JIRA
(v6.3.4#6332)

Mime
View raw message