[jira] [Commented] (RATIS-750) Ratis server fails with "java.lang.ClassNotFoundException: com.codahale.metrics.jvm.GarbageCollectorMetricSet"

2019-11-12 Thread Marton Elek (Jira)


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

Marton Elek commented on RATIS-750:
---

Thanks the update [~clayb]Yes, I think it gives us more flexibility as ratis 
can be used without metrics-jvm. It's optional.

Tested and worked well. Committed to the master...

> Ratis server fails with "java.lang.ClassNotFoundException: 
> com.codahale.metrics.jvm.GarbageCollectorMetricSet"
> --
>
> Key: RATIS-750
> URL: https://issues.apache.org/jira/browse/RATIS-750
> Project: Ratis
>  Issue Type: Bug
>  Components: build
>Reporter: Clay B.
>Assignee: Clay B.
>Priority: Major
> Attachments: 
> 0001-RATIS-750.-Ratis-server-fails-with-java.lang.ClassNo.patch, 
> 0002-RATIS-750.-Ratis-server-fails-with-java.lang.ClassNo.patch
>
>
> In testing the current master, starting the Ratis server via 
> {{./ratis-examples/src/main/bin/server.sh filestore server --storage $storage 
> --id $id --peers $peers 2>&1 | \}} I end up with the following failure to 
> start:
> {code:java}
> Found 
> /home/vagrant/incubator-ratis/ratis-examples/target/ratis-examples-0.5.0-SNAPSHOT.jar
> 2019-11-11 03:27:52 INFO  MetricRegistries:64 - Loaded MetricRegistries class 
> org.apache.ratis.metrics.impl.MetricRegistriesImpl
> 2019-11-11 03:27:52 WARN  MetricRegistriesImpl:61 - First MetricRegistry has 
> been created without registering reporters. You may need to call 
> MetricRegistries.global().addReportRegistration(...) before.
> Exception in thread "main" java.lang.NoClassDefFoundError: 
> com/codahale/metrics/jvm/GarbageCollectorMetricSet
> at 
> org.apache.ratis.metrics.JVMMetrics.addJvmMetrics(JVMMetrics.java:42)
> at 
> org.apache.ratis.metrics.JVMMetrics.initJvmMetrics(JVMMetrics.java:32)
> at org.apache.ratis.examples.filestore.cli.Server.run(Server.java:60)
> at org.apache.ratis.examples.common.Runner.main(Runner.java:58)
> Caused by: java.lang.ClassNotFoundException: 
> com.codahale.metrics.jvm.GarbageCollectorMetricSet
> at java.net.URLClassLoader.findClass(URLClassLoader.java:382)
> at java.lang.ClassLoader.loadClass(ClassLoader.java:424)
> at sun.misc.Launcher$AppClassLoader.loadClass(Launcher.java:349)
> at java.lang.ClassLoader.loadClass(ClassLoader.java:357)
> ... 4 more
> === Command terminated normally (Mon Nov 11 03:27:52 2019) === {code}
>  



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


[jira] [Commented] (RATIS-750) Ratis server fails with "java.lang.ClassNotFoundException: com.codahale.metrics.jvm.GarbageCollectorMetricSet"

2019-11-12 Thread Hadoop QA (Jira)


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

Hadoop QA commented on RATIS-750:
-

| (x) *{color:red}-1 overall{color}* |
\\
\\
|| Vote || Subsystem || Runtime || Comment ||
| {color:blue}0{color} | {color:blue} reexec {color} | {color:blue}  0m 
17s{color} | {color:blue} Docker mode activated. {color} |
|| || || || {color:brown} Prechecks {color} ||
| {color:green}+1{color} | {color:green} @author {color} | {color:green}  0m  
0s{color} | {color:green} The patch does not contain any @author tags. {color} |
| {color:red}-1{color} | {color:red} test4tests {color} | {color:red}  0m  
0s{color} | {color:red} The patch doesn't appear to include any new or modified 
tests. Please justify why no new tests are needed for this patch. Also please 
list what manual steps were performed to verify this patch. {color} |
|| || || || {color:brown} master Compile Tests {color} ||
| {color:green}+1{color} | {color:green} mvninstall {color} | {color:green}  2m 
56s{color} | {color:green} master passed {color} |
| {color:green}+1{color} | {color:green} compile {color} | {color:green}  0m 
50s{color} | {color:green} master passed {color} |
| {color:green}+1{color} | {color:green} javadoc {color} | {color:green}  0m 
44s{color} | {color:green} master passed {color} |
|| || || || {color:brown} Patch Compile Tests {color} ||
| {color:green}+1{color} | {color:green} mvninstall {color} | {color:green}  0m 
55s{color} | {color:green} the patch passed {color} |
| {color:green}+1{color} | {color:green} compile {color} | {color:green}  0m 
51s{color} | {color:green} the patch passed {color} |
| {color:green}+1{color} | {color:green} javac {color} | {color:green}  0m 
51s{color} | {color:green} the patch passed {color} |
| {color:green}+1{color} | {color:green} whitespace {color} | {color:green}  0m 
 0s{color} | {color:green} The patch has no whitespace issues. {color} |
| {color:green}+1{color} | {color:green} xml {color} | {color:green}  0m  
1s{color} | {color:green} The patch has no ill-formed XML file. {color} |
| {color:green}+1{color} | {color:green} javadoc {color} | {color:green}  0m 
34s{color} | {color:green} the patch passed {color} |
|| || || || {color:brown} Other Tests {color} ||
| {color:red}-1{color} | {color:red} unit {color} | {color:red} 17m 29s{color} 
| {color:red} root in the patch failed. {color} |
| {color:green}+1{color} | {color:green} asflicense {color} | {color:green}  0m 
22s{color} | {color:green} The patch does not generate ASF License warnings. 
{color} |
| {color:black}{color} | {color:black} {color} | {color:black} 25m 12s{color} | 
{color:black} {color} |
\\
\\
|| Reason || Tests ||
| Failed junit tests | ratis.logservice.server.TestMetaServer |
|   | ratis.grpc.TestServerRestartWithGrpc |
|   | ratis.grpc.TestRaftWithGrpc |
|   | ratis.grpc.TestStateMachineShutdownWithGrpc |
|   | ratis.server.simulation.TestServerRestartWithSimulatedRpc |
|   | ratis.examples.filestore.TestFileStoreWithGrpc |
|   | ratis.TestMultiRaftGroup |
\\
\\
|| Subsystem || Report/Notes ||
| Docker | Client=19.03.4 Server=19.03.4 Image:yetus/ratis:date2019-11-12 |
| JIRA Issue | RATIS-750 |
| JIRA Patch URL | 
https://issues.apache.org/jira/secure/attachment/12985595/0002-RATIS-750.-Ratis-server-fails-with-java.lang.ClassNo.patch
 |
| Optional Tests |  dupname  asflicense  javac  javadoc  unit  xml  compile  |
| uname | Linux e3abbf38f656 4.15.0-66-generic #75-Ubuntu SMP Tue Oct 1 
05:24:09 UTC 2019 x86_64 x86_64 x86_64 GNU/Linux |
| Build tool | maven |
| Personality | 
/home/jenkins/jenkins-slave/workspace/PreCommit-RATIS-Build/yetus-personality.sh
 |
| git revision | master / 0731376 |
| maven | version: Apache Maven 3.6.2 
(40f52333136460af0dc0d7232c0dc0bcf0d9e117; 2019-08-27T15:06:16Z) |
| Default Java | 1.8.0_222 |
| unit | 
https://builds.apache.org/job/PreCommit-RATIS-Build/1149/artifact/out/patch-unit-root.txt
 |
|  Test Results | 
https://builds.apache.org/job/PreCommit-RATIS-Build/1149/testReport/ |
| Max. process+thread count | 1445 (vs. ulimit of 5000) |
| modules | C: ratis-examples U: ratis-examples |
| Console output | 
https://builds.apache.org/job/PreCommit-RATIS-Build/1149/console |
| Powered by | Apache Yetus 0.8.0   http://yetus.apache.org |


This message was automatically generated.



> Ratis server fails with "java.lang.ClassNotFoundException: 
> com.codahale.metrics.jvm.GarbageCollectorMetricSet"
> --
>
> Key: RATIS-750
> URL: https://issues.apache.org/jira/browse/RATIS-750
> Project: Ratis
>  Issue Type: Bug
>  Components: build
>Reporter: Clay B.
>Assignee: Clay B.
>Priority: Major
> Attachments: 
> 0001-RATIS-750.-Ratis-server-fai

[jira] [Commented] (RATIS-750) Ratis server fails with "java.lang.ClassNotFoundException: com.codahale.metrics.jvm.GarbageCollectorMetricSet"

2019-11-11 Thread Clay B. (Jira)


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

Clay B. commented on RATIS-750:
---

Thanks for the suggestion and direction [~elek]. Does this look better for 
addressing the solution for the example server?

> Ratis server fails with "java.lang.ClassNotFoundException: 
> com.codahale.metrics.jvm.GarbageCollectorMetricSet"
> --
>
> Key: RATIS-750
> URL: https://issues.apache.org/jira/browse/RATIS-750
> Project: Ratis
>  Issue Type: Bug
>  Components: build
>Reporter: Clay B.
>Assignee: Clay B.
>Priority: Major
> Attachments: 
> 0001-RATIS-750.-Ratis-server-fails-with-java.lang.ClassNo.patch, 
> 0002-RATIS-750.-Ratis-server-fails-with-java.lang.ClassNo.patch
>
>
> In testing the current master, starting the Ratis server via 
> {{./ratis-examples/src/main/bin/server.sh filestore server --storage $storage 
> --id $id --peers $peers 2>&1 | \}} I end up with the following failure to 
> start:
> {code:java}
> Found 
> /home/vagrant/incubator-ratis/ratis-examples/target/ratis-examples-0.5.0-SNAPSHOT.jar
> 2019-11-11 03:27:52 INFO  MetricRegistries:64 - Loaded MetricRegistries class 
> org.apache.ratis.metrics.impl.MetricRegistriesImpl
> 2019-11-11 03:27:52 WARN  MetricRegistriesImpl:61 - First MetricRegistry has 
> been created without registering reporters. You may need to call 
> MetricRegistries.global().addReportRegistration(...) before.
> Exception in thread "main" java.lang.NoClassDefFoundError: 
> com/codahale/metrics/jvm/GarbageCollectorMetricSet
> at 
> org.apache.ratis.metrics.JVMMetrics.addJvmMetrics(JVMMetrics.java:42)
> at 
> org.apache.ratis.metrics.JVMMetrics.initJvmMetrics(JVMMetrics.java:32)
> at org.apache.ratis.examples.filestore.cli.Server.run(Server.java:60)
> at org.apache.ratis.examples.common.Runner.main(Runner.java:58)
> Caused by: java.lang.ClassNotFoundException: 
> com.codahale.metrics.jvm.GarbageCollectorMetricSet
> at java.net.URLClassLoader.findClass(URLClassLoader.java:382)
> at java.lang.ClassLoader.loadClass(ClassLoader.java:424)
> at sun.misc.Launcher$AppClassLoader.loadClass(Launcher.java:349)
> at java.lang.ClassLoader.loadClass(ClassLoader.java:357)
> ... 4 more
> === Command terminated normally (Mon Nov 11 03:27:52 2019) === {code}
>  



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


[jira] [Commented] (RATIS-750) Ratis server fails with "java.lang.ClassNotFoundException: com.codahale.metrics.jvm.GarbageCollectorMetricSet"

2019-11-11 Thread Marton Elek (Jira)


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

Marton Elek commented on RATIS-750:
---

Optional used intentionally as metrics may or may not be used by the apps. It's 
the responsibility of the user of ratis to put a specific version to the 
classpath. I think a better fix is to add it as a real compile dependency only 
where it is required (eg. add it to the logService and to the example server).

> Ratis server fails with "java.lang.ClassNotFoundException: 
> com.codahale.metrics.jvm.GarbageCollectorMetricSet"
> --
>
> Key: RATIS-750
> URL: https://issues.apache.org/jira/browse/RATIS-750
> Project: Ratis
>  Issue Type: Bug
>  Components: build
>Reporter: Clay B.
>Assignee: Clay B.
>Priority: Major
> Attachments: 
> 0001-RATIS-750.-Ratis-server-fails-with-java.lang.ClassNo.patch
>
>
> In testing the current master, starting the Ratis server via 
> {{./ratis-examples/src/main/bin/server.sh filestore server --storage $storage 
> --id $id --peers $peers 2>&1 | \}} I end up with the following failure to 
> start:
> {code:java}
> Found 
> /home/vagrant/incubator-ratis/ratis-examples/target/ratis-examples-0.5.0-SNAPSHOT.jar
> 2019-11-11 03:27:52 INFO  MetricRegistries:64 - Loaded MetricRegistries class 
> org.apache.ratis.metrics.impl.MetricRegistriesImpl
> 2019-11-11 03:27:52 WARN  MetricRegistriesImpl:61 - First MetricRegistry has 
> been created without registering reporters. You may need to call 
> MetricRegistries.global().addReportRegistration(...) before.
> Exception in thread "main" java.lang.NoClassDefFoundError: 
> com/codahale/metrics/jvm/GarbageCollectorMetricSet
> at 
> org.apache.ratis.metrics.JVMMetrics.addJvmMetrics(JVMMetrics.java:42)
> at 
> org.apache.ratis.metrics.JVMMetrics.initJvmMetrics(JVMMetrics.java:32)
> at org.apache.ratis.examples.filestore.cli.Server.run(Server.java:60)
> at org.apache.ratis.examples.common.Runner.main(Runner.java:58)
> Caused by: java.lang.ClassNotFoundException: 
> com.codahale.metrics.jvm.GarbageCollectorMetricSet
> at java.net.URLClassLoader.findClass(URLClassLoader.java:382)
> at java.lang.ClassLoader.loadClass(ClassLoader.java:424)
> at sun.misc.Launcher$AppClassLoader.loadClass(Launcher.java:349)
> at java.lang.ClassLoader.loadClass(ClassLoader.java:357)
> ... 4 more
> === Command terminated normally (Mon Nov 11 03:27:52 2019) === {code}
>  



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


[jira] [Commented] (RATIS-750) Ratis server fails with "java.lang.ClassNotFoundException: com.codahale.metrics.jvm.GarbageCollectorMetricSet"

2019-11-10 Thread Hadoop QA (Jira)


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

Hadoop QA commented on RATIS-750:
-

| (x) *{color:red}-1 overall{color}* |
\\
\\
|| Vote || Subsystem || Runtime || Comment ||
| {color:blue}0{color} | {color:blue} reexec {color} | {color:blue}  0m 
18s{color} | {color:blue} Docker mode activated. {color} |
|| || || || {color:brown} Prechecks {color} ||
| {color:green}+1{color} | {color:green} @author {color} | {color:green}  0m  
0s{color} | {color:green} The patch does not contain any @author tags. {color} |
| {color:red}-1{color} | {color:red} test4tests {color} | {color:red}  0m  
0s{color} | {color:red} The patch doesn't appear to include any new or modified 
tests. Please justify why no new tests are needed for this patch. Also please 
list what manual steps were performed to verify this patch. {color} |
|| || || || {color:brown} master Compile Tests {color} ||
| {color:green}+1{color} | {color:green} mvninstall {color} | {color:green}  3m 
 0s{color} | {color:green} master passed {color} |
| {color:green}+1{color} | {color:green} compile {color} | {color:green}  0m 
52s{color} | {color:green} master passed {color} |
| {color:green}+1{color} | {color:green} javadoc {color} | {color:green}  0m 
45s{color} | {color:green} master passed {color} |
|| || || || {color:brown} Patch Compile Tests {color} ||
| {color:green}+1{color} | {color:green} mvninstall {color} | {color:green}  0m 
55s{color} | {color:green} the patch passed {color} |
| {color:green}+1{color} | {color:green} compile {color} | {color:green}  0m 
50s{color} | {color:green} the patch passed {color} |
| {color:green}+1{color} | {color:green} javac {color} | {color:green}  0m 
50s{color} | {color:green} the patch passed {color} |
| {color:green}+1{color} | {color:green} whitespace {color} | {color:green}  0m 
 0s{color} | {color:green} The patch has no whitespace issues. {color} |
| {color:green}+1{color} | {color:green} xml {color} | {color:green}  0m  
1s{color} | {color:green} The patch has no ill-formed XML file. {color} |
| {color:green}+1{color} | {color:green} javadoc {color} | {color:green}  0m 
34s{color} | {color:green} the patch passed {color} |
|| || || || {color:brown} Other Tests {color} ||
| {color:red}-1{color} | {color:red} unit {color} | {color:red} 17m 23s{color} 
| {color:red} root in the patch failed. {color} |
| {color:green}+1{color} | {color:green} asflicense {color} | {color:green}  0m 
19s{color} | {color:green} The patch does not generate ASF License warnings. 
{color} |
| {color:black}{color} | {color:black} {color} | {color:black} 25m 14s{color} | 
{color:black} {color} |
\\
\\
|| Reason || Tests ||
| Failed junit tests | ratis.logservice.server.TestMetaServer |
|   | ratis.grpc.TestStateMachineShutdownWithGrpc |
\\
\\
|| Subsystem || Report/Notes ||
| Docker | Client=19.03.4 Server=19.03.4 Image:yetus/ratis:date2019-11-11 |
| JIRA Issue | RATIS-750 |
| JIRA Patch URL | 
https://issues.apache.org/jira/secure/attachment/12985488/0001-RATIS-750.-Ratis-server-fails-with-java.lang.ClassNo.patch
 |
| Optional Tests |  dupname  asflicense  javac  javadoc  unit  xml  compile  |
| uname | Linux 2447728ecf49 4.15.0-66-generic #75-Ubuntu SMP Tue Oct 1 
05:24:09 UTC 2019 x86_64 x86_64 x86_64 GNU/Linux |
| Build tool | maven |
| Personality | 
/home/jenkins/jenkins-slave/workspace/PreCommit-RATIS-Build/yetus-personality.sh
 |
| git revision | master / 0731376 |
| maven | version: Apache Maven 3.6.2 
(40f52333136460af0dc0d7232c0dc0bcf0d9e117; 2019-08-27T15:06:16Z) |
| Default Java | 1.8.0_222 |
| unit | 
https://builds.apache.org/job/PreCommit-RATIS-Build/1144/artifact/out/patch-unit-root.txt
 |
|  Test Results | 
https://builds.apache.org/job/PreCommit-RATIS-Build/1144/testReport/ |
| Max. process+thread count | 2155 (vs. ulimit of 5000) |
| modules | C: ratis-metrics U: ratis-metrics |
| Console output | 
https://builds.apache.org/job/PreCommit-RATIS-Build/1144/console |
| Powered by | Apache Yetus 0.8.0   http://yetus.apache.org |


This message was automatically generated.



> Ratis server fails with "java.lang.ClassNotFoundException: 
> com.codahale.metrics.jvm.GarbageCollectorMetricSet"
> --
>
> Key: RATIS-750
> URL: https://issues.apache.org/jira/browse/RATIS-750
> Project: Ratis
>  Issue Type: Bug
>  Components: build
>Reporter: Clay B.
>Assignee: Clay B.
>Priority: Major
> Attachments: 
> 0001-RATIS-750.-Ratis-server-fails-with-java.lang.ClassNo.patch
>
>
> In testing the current master, starting the Ratis server via 
> {{./ratis-examples/src/main/bin/server.sh filestore server --storage $storage 
> --id $id --peers $peers 2>&1 | \}} I end up with the f

[jira] [Commented] (RATIS-750) Ratis server fails with "java.lang.ClassNotFoundException: com.codahale.metrics.jvm.GarbageCollectorMetricSet"

2019-11-10 Thread Clay B. (Jira)


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

Clay B. commented on RATIS-750:
---

It seems the import came in from RATIS-720. I see that 
{{io.dropwizard.metrics}} artifact {{metrics-jvm}} is marked as {{optional}} in 
the {{ratis-metrics}} {{pom.xml}}. Removing the optional allows the server to 
start. It seems {{ratis-test}} and {{ratis-logservice}} may be similarly 
impacted as they have the dependency marked for scope {{test}}.

> Ratis server fails with "java.lang.ClassNotFoundException: 
> com.codahale.metrics.jvm.GarbageCollectorMetricSet"
> --
>
> Key: RATIS-750
> URL: https://issues.apache.org/jira/browse/RATIS-750
> Project: Ratis
>  Issue Type: Bug
>  Components: build
>Reporter: Clay B.
>Assignee: Clay B.
>Priority: Major
>
> In testing the current master, starting the Ratis server via 
> {{./ratis-examples/src/main/bin/server.sh filestore server --storage $storage 
> --id $id --peers $peers 2>&1 | \}} I end up with the following failure to 
> start:
> {code:java}
> Found 
> /home/vagrant/incubator-ratis/ratis-examples/target/ratis-examples-0.5.0-SNAPSHOT.jar
> 2019-11-11 03:27:52 INFO  MetricRegistries:64 - Loaded MetricRegistries class 
> org.apache.ratis.metrics.impl.MetricRegistriesImpl
> 2019-11-11 03:27:52 WARN  MetricRegistriesImpl:61 - First MetricRegistry has 
> been created without registering reporters. You may need to call 
> MetricRegistries.global().addReportRegistration(...) before.
> Exception in thread "main" java.lang.NoClassDefFoundError: 
> com/codahale/metrics/jvm/GarbageCollectorMetricSet
> at 
> org.apache.ratis.metrics.JVMMetrics.addJvmMetrics(JVMMetrics.java:42)
> at 
> org.apache.ratis.metrics.JVMMetrics.initJvmMetrics(JVMMetrics.java:32)
> at org.apache.ratis.examples.filestore.cli.Server.run(Server.java:60)
> at org.apache.ratis.examples.common.Runner.main(Runner.java:58)
> Caused by: java.lang.ClassNotFoundException: 
> com.codahale.metrics.jvm.GarbageCollectorMetricSet
> at java.net.URLClassLoader.findClass(URLClassLoader.java:382)
> at java.lang.ClassLoader.loadClass(ClassLoader.java:424)
> at sun.misc.Launcher$AppClassLoader.loadClass(Launcher.java:349)
> at java.lang.ClassLoader.loadClass(ClassLoader.java:357)
> ... 4 more
> === Command terminated normally (Mon Nov 11 03:27:52 2019) === {code}
>  



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