Github user srdo commented on a diff in the pull request:
https://github.com/apache/storm/pull/2430#discussion_r152365226
--- Diff:
storm-webapp/src/main/java/org/apache/storm/daemon/logviewer/handler/LogviewerLogSearchHandler.java
---
@@ -97,8 +98,14 @@ public LogviewerLogSearchHandler(Map<String, Object>
stormConf, String logRoot,
this.logRoot = logRoot;
this.daemonLogRoot = daemonLogRoot;
this.resourceAuthorizer = resourceAuthorizer;
-
- this.logviewerPort =
ObjectReader.getInt(stormConf.get(DaemonConfig.LOGVIEWER_PORT));
+ Integer httpsPort =
ObjectReader.getInt(stormConf.get(DaemonConfig.LOGVIEWER_HTTPS_PORT), 0);
--- End diff --
You're right. I thought Logviewer was using the same validation code as
storm-client and storm-server to ensure that stormConf was valid according to
the annotations in DaemonConfig (e.g. LOGVIEWER_HTTPS_PORT is configured to use
validation for "@isInteger" and "@isPositiveNumber".
Do you know if there's a reason why we aren't using the usual validation
(this method
https://github.com/apache/storm/blob/master/storm-client/src/jvm/org/apache/storm/validation/ConfigValidation.java#L710)?
---