dubbo-notifications mailing list archives

Site index · List index
Message view « Date » · « Thread »
Top « Date » · « Thread »
From khanimteyaz (GitHub) <git...@apache.org>
Subject [GitHub] [incubator-dubbo] khanimteyaz commented on pull request #2809: [Dubbo-2795] add a config to enable or disable telnet
Date Sat, 08 Dec 2018 17:16:25 GMT
Constants.TELNET value and config value which user will provide is "enable.telnet" and in code
we are using the variable name 'enableTelnet' which more aligned with value (eventually which
user will be providing). Should we consider renaming the constant name to the same e.g. 
Constants.ENABLE_TELNET="enable.telnet" ?

Another thought, should we refactor the this method instead of directly using 'channel.getUrl().getParameter(Constants.TELNET,
true);' can create a method named isTenletEnabled()

private Boolean isTenletEnabled(Channel channel) {
   return channel.getUrl().getParameter(Constants.TELNET, true);

In this way I think in future even we change constant name of add more parameter to conclude
telnet is configured not it will be a single place change. This is just an my thought I could
be over thinking here 😄 

[ Full content available at: https://github.com/apache/incubator-dubbo/pull/2809 ]
This message was relayed via gitbox.apache.org for notifications@dubbo.apache.org
View raw message