Github user mike-jumper commented on a diff in the pull request:

    
https://github.com/apache/incubator-guacamole-client/pull/69#discussion_r77475564
  
    --- Diff: 
extensions/guacamole-auth-jdbc/modules/guacamole-auth-jdbc-base/src/main/java/org/apache/guacamole/auth/jdbc/tunnel/AbstractGuacamoleTunnelService.java
 ---
    @@ -714,4 +714,15 @@ public GuacamoleTunnel 
getGuacamoleTunnel(RemoteAuthenticatedUser user,
     
         }
     
    +
    +    public Integer getIdleConnections(Connection connection) {
    +           Integer idle = 999999;
    --- End diff --
    
    I expect this will not be done when the approach is revisited. That said, 
please beware:
    
    1. As written, this is an unnecessary use of `Integer`. Why not `int`? Same 
for the return value of the function as a whole. The way things are being used 
here, `Integer` does nothing.
    2. `999999` is a magic number - avoid these. It would make more sense for 
such a function to return `null` if the value is unset, rather than an 
arbitrarily large number. Perhaps that's why you initially went with `Integer`? 
Either way, it really should be done differently.


---
If your project is set up for it, you can reply to this email and have your
reply appear on GitHub as well. If your project does not have this feature
enabled and wishes so, or if the feature is enabled but not working, please
contact infrastructure at [email protected] or file a JIRA ticket
with INFRA.
---

Reply via email to