jmtd opened a new issue, #3845:
URL: https://github.com/apache/incubator-heron/issues/3845

   **Describe the bug**
   
   The very first example topology is broken with the latest version of the 
docker container (which, interestingly, is a micro version ahead of GitHub):  
0.20.5-incubating 
   
   (the example used in 
https://github.com/apache/incubator-heron/blob/master/website2/docs/getting-started-docker.md)
   
   **To Reproduce**
   Steps to reproduce the behavior:
   1. `docker run -it  --rm -d -p 8889:8889 -p 8888:8888 --name local-heron 
apache/heron:0.20.5-incubating supervisord --nodaemon` (note version: 
0.20.5-incubating)
   2. `docker exec -it    local-heron    bash -c "heron submit sandbox  
/heron/examples/heron-eco-examples.jar org.apache.heron.eco.Eco 
--eco-config-file /heron/examples/heron_wordcount.yaml"`
   3. See error
   
   **Expected behavior**
   
   ```
   …
   [2022-07-07 14:33:02 +0000] [INFO]: Successfully launched topology 
'heron-simple-wordcount-topology' 
   ```
   **Actual behavior**
   
   ```
   ;docker exec -it    local-heron    bash -c "heron submit sandbox  
/heron/examples/heron-eco-examples.jar org.apache.heron.eco.Eco 
--eco-config-file /heron/examples/heron_wordcount.yaml"
   [2022-07-07 14:38:15 +0000] [INFO]: Using cluster definition in 
/usr/local/heron/conf/sandbox
   Exception in thread "main" Cannot create property=spouts for 
JavaBean=org.apache.heron.eco.definition.EcoTopologyDefinition@45b9a632
    in 'string', line 22, column 1:
       name: "heron-simple-wordcount-to ... 
       ^
   Can not set java.util.Map field 
org.apache.heron.eco.definition.EcoTopologyDefinition.spouts to 
java.util.ArrayList
    in 'string', line 49, column 3:
         - id: "spout-1"
         ^
   
        at 
org.yaml.snakeyaml.constructor.Constructor$ConstructMapping.constructJavaBean2ndStep(Constructor.java:291)
        at 
org.yaml.snakeyaml.constructor.Constructor$ConstructMapping.construct(Constructor.java:172)
        at 
org.yaml.snakeyaml.constructor.Constructor$ConstructYamlObject.construct(Constructor.java:332)
        at 
org.yaml.snakeyaml.constructor.BaseConstructor.constructObjectNoCheck(BaseConstructor.java:230)
        at 
org.yaml.snakeyaml.constructor.BaseConstructor.constructObject(BaseConstructor.java:220)
        at 
org.yaml.snakeyaml.constructor.BaseConstructor.constructDocument(BaseConstructor.java:174)
        at 
org.yaml.snakeyaml.constructor.BaseConstructor.getSingleData(BaseConstructor.java:158)
        at org.yaml.snakeyaml.Yaml.loadFromReader(Yaml.java:491)
        at org.yaml.snakeyaml.Yaml.load(Yaml.java:416)
        at 
org.apache.heron.eco.parser.EcoParser.loadTopologyFromYaml(EcoParser.java:87)
        at 
org.apache.heron.eco.parser.EcoParser.parseFromInputStream(EcoParser.java:50)
        at org.apache.heron.eco.Eco.submit(Eco.java:75)
        at org.apache.heron.eco.Eco.main(Eco.java:163)
   Caused by: java.lang.IllegalArgumentException: Can not set java.util.Map 
field org.apache.heron.eco.definition.EcoTopologyDefinition.spouts to 
java.util.ArrayList
        at 
java.base/jdk.internal.reflect.UnsafeFieldAccessorImpl.throwSetIllegalArgumentException(UnsafeFieldAccessorImpl.java:167)
        at 
java.base/jdk.internal.reflect.UnsafeFieldAccessorImpl.throwSetIllegalArgumentException(UnsafeFieldAccessorImpl.java:171)
        at 
java.base/jdk.internal.reflect.UnsafeObjectFieldAccessorImpl.set(UnsafeObjectFieldAccessorImpl.java:81)
        at java.base/java.lang.reflect.Field.set(Field.java:780)
        at 
org.yaml.snakeyaml.introspector.PropertySubstitute.set(PropertySubstitute.java:105)
        at 
org.yaml.snakeyaml.constructor.Constructor$ConstructMapping.constructJavaBean2ndStep(Constructor.java:286)
        ... 12 more
   2022-07-07 14:38:15.450 INFO - o.a.heron.eco.parser.EcoParser -              
   main - Parsing eco config file
   2022-07-07 14:38:15.453 INFO - o.a.heron.eco.parser.EcoParser -              
   main - Not performing property substitution.
   2022-07-07 14:38:15.453 INFO - o.a.heron.eco.parser.EcoParser -              
   main - Not performing environment variable substitution.
   2022-07-07 14:38:15.450 INFO - o.a.heron.eco.parser.EcoParser -              
   main - Parsing eco config file
   2022-07-07 14:38:15.453 INFO - o.a.heron.eco.parser.EcoParser -              
   main - Not performing property substitution.
   2022-07-07 14:38:15.453 INFO - o.a.heron.eco.parser.EcoParser -              
   main - Not performing environment variable substitution.
   [2022-07-07 14:38:15 +0000] [ERROR]: Failed to create topology definition 
file when executing class 'org.apache.heron.eco.Eco' of file 
'/heron/examples/heron-eco-examples.jar'
   ```
   
   **Operating System**
    - OS: Docker version 20.10.5+dfsg1, build 55c4c88 on Debian 11.3
    - Version 0.20.5-incubating 
   
   **Additional context**
   
   Version  0.20.4-incubating works!
   
   The file `/heron/examples/heron_wordcount.yaml` is unchanged between the 
versions.


-- 
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: [email protected]

For queries about this service, please contact Infrastructure at:
[email protected]

Reply via email to