You are viewing a plain text version of this content. The canonical link for it is here.
Posted to notifications@shardingsphere.apache.org by GitBox <gi...@apache.org> on 2022/07/14 02:53:18 UTC

[GitHub] [shardingsphere-elasticjob] jbgzz opened a new issue, #2105: An operation to delete a job configuration reported a null pointer error,

jbgzz opened a new issue, #2105:
URL: https://github.com/apache/shardingsphere-elasticjob/issues/2105

   
   //The operation of deleting a job configuration
   jobConfigurationAPI.removeJobConfiguration(taskId);
   
   ---------------------------------------------------------------------------------------------------------------------------------------------------
   
   Error message:
   java.lang.NullPointerException: null
   	at java.io.StringReader.<init>(StringReader.java:50) ~[na:1.8.0_301]
   	at org.yaml.snakeyaml.reader.StreamReader.<init>(StreamReader.java:63) ~[snakeyaml-1.26.jar:na]
   	at org.yaml.snakeyaml.Yaml.loadAs(Yaml.java:452) ~[snakeyaml-1.26.jar:na]
   	at org.apache.shardingsphere.elasticjob.infra.yaml.YamlEngine.unmarshal(YamlEngine.java:50) ~[elasticjob-infra-common-3.0.1.jar:3.0.1]
   	at org.apache.shardingsphere.elasticjob.lite.internal.config.ConfigurationService.load(ConfigurationService.java:59) ~[elasticjob-lite-core-3.0.1.jar:3.0.1]
   	at org.apache.shardingsphere.elasticjob.lite.internal.failover.FailoverListenerManager.isFailoverEnabled(FailoverListenerManager.java:67) ~[elasticjob-lite-core-3.0.1.jar:3.0.1]
   	at org.apache.shardingsphere.elasticjob.lite.internal.failover.FailoverListenerManager.access$100(FailoverListenerManager.java:36) ~[elasticjob-lite-core-3.0.1.jar:3.0.1]
   	at org.apache.shardingsphere.elasticjob.lite.internal.failover.FailoverListenerManager$JobCrashedJobListener.dataChanged(FailoverListenerManager.java:74) ~[elasticjob-lite-core-3.0.1.jar:3.0.1]
   	at org.apache.shardingsphere.elasticjob.lite.internal.listener.AbstractJobListener.event(AbstractJobListener.java:40) ~[elasticjob-lite-core-3.0.1.jar:3.0.1]
   	at org.apache.curator.framework.recipes.cache.CuratorCacheImpl.lambda$removeStorage$8(CuratorCacheImpl.java:286) ~[curator-recipes-5.0.0.jar:5.0.0]
   	at org.apache.curator.framework.listen.MappingListenerManager.lambda$forEach$0(MappingListenerManager.java:92) ~[curator-framework-5.0.0.jar:5.0.0]
   	at org.apache.curator.framework.listen.MappingListenerManager.forEach(MappingListenerManager.java:89) ~[curator-framework-5.0.0.jar:5.0.0]
   	at org.apache.curator.framework.listen.StandardListenerManager.forEach(StandardListenerManager.java:89) ~[curator-framework-5.0.0.jar:5.0.0]
   	at org.apache.curator.framework.recipes.cache.CuratorCacheImpl.lambda$callListeners$10(CuratorCacheImpl.java:293) ~[curator-recipes-5.0.0.jar:5.0.0]
   	at java.util.concurrent.CompletableFuture$AsyncRun.run$$$capture(CompletableFuture.java:1640) ~[na:1.8.0_301]
   	at java.util.concurrent.CompletableFuture$AsyncRun.run(CompletableFuture.java) ~[na:1.8.0_301]
   	at java.util.concurrent.ThreadPoolExecutor.runWorker(ThreadPoolExecutor.java:1149) ~[na:1.8.0_301]
   	at java.util.concurrent.ThreadPoolExecutor$Worker.run(ThreadPoolExecutor.java:624) ~[na:1.8.0_301]
   	at java.lang.Thread.run(Thread.java:748) ~[na:1.8.0_301]
   
   
   ---------------------------------------------------------------------------------------------------------------------------------------------------
   The source code to track:
   
    public JobConfiguration load(final boolean fromCache) {
           String result;
           if (fromCache) {
               result = jobNodeStorage.getJobNodeData(ConfigurationNode.ROOT);
               if (null == result) {
                   result = jobNodeStorage.getJobNodeDataDirectly(ConfigurationNode.ROOT);
               }
           } else {
               result = jobNodeStorage.getJobNodeDataDirectly(ConfigurationNode.ROOT);
           }
           return YamlEngine.unmarshal(result, JobConfigurationPOJO.class).toJobConfiguration();
       }
   
   The result is null,Cause a null pointer
   
   Eventually the configuration in ZK can be removed, but many null pointer errors are reported
   
   
   


-- 
This is an automated message from the Apache Git Service.
To respond to the message, please log on to GitHub and use the
URL above to go to the specific comment.

To unsubscribe, e-mail: notifications-unsubscribe@shardingsphere.apache.org.apache.org

For queries about this service, please contact Infrastructure at:
users@infra.apache.org


[GitHub] [shardingsphere-elasticjob] TeslaCN closed issue #2105: An operation to delete a job configuration reported a null pointer error,

Posted by GitBox <gi...@apache.org>.
TeslaCN closed issue #2105: An operation to delete a job configuration reported a null pointer error,
URL: https://github.com/apache/shardingsphere-elasticjob/issues/2105


-- 
This is an automated message from the Apache Git Service.
To respond to the message, please log on to GitHub and use the
URL above to go to the specific comment.

To unsubscribe, e-mail: notifications-unsubscribe@shardingsphere.apache.org

For queries about this service, please contact Infrastructure at:
users@infra.apache.org