MrtnBalazs opened a new pull request, #622:
URL: https://github.com/apache/knox/pull/622

   ## What changes were proposed in this pull request?
   
   Introduced new group called `gateway.session.verification.unlimited.users` 
and  changed the behaviour of the groups and the tests that check these 
behaviours. `gateway.non.privileged.users` group is now not configurable.
   Also changed configuration names:
   ```
   gateway.privileged.users -> gateway.session.verification.privileged.users
   gateway.non.privileged.users.concurrent.session.limit -> 
gateway.session.verification.non.privileged.user.limit
   gateway.privileged.users.concurrent.session.limit -> 
gateway.session.verification.privileged.user.limit
   ```
   
   Previous behaviour:
   If someone is configured privileged -> privileged limit applies
   If someone is configured non-privileged -> non-privileged limit applies
   If someone is not configured in either of the groups -> no limit applies
   
   New behaviour:
   If someone is configured privileged -> privileged limit applies
   If someone is configured unlimited -> no limit applies
   If someone is not configured in either of the groups -> non-privileged limit 
applies
   
   ## How was this patch tested?
   
   I changed the existing unit tests to test the new behaviours.
   I also tested the new behaviours manually with the following configurataions:
   1. Nothing
   2. Empty string for implementation configuration
   ```
   <property>
           <name>gateway.service.concurrentsessionverifier.impl</name>
           <value></value>
   </property>
   ```
   3. Blank string for implementation
   ```
   <property>
           <name>gateway.service.concurrentsessionverifier.impl</name>
           <value>      </value>
   </property>
   ```
   4. Not valid implementation
   ```
   <property>
           <name>gateway.service.concurrentsessionverifier.impl</name>
           
<value>org.apache.knox.gateway.session.control.NotExistingConcurrentSessionVerifier</value>
   </property>
   ```
   5. Empty implementation configured
   ```
   <property>
           <name>gateway.service.concurrentsessionverifier.impl</name>
           
<value>org.apache.knox.gateway.session.control.EmptyConcurrentSessionVerifier</value>
   </property>
   ```
   6. InMemory implementation configured
   ```
   <property>
           <name>gateway.service.concurrentsessionverifier.impl</name>
           
<value>org.apache.knox.gateway.session.control.InMemoryConcurrentSessionVerifier</value>
   </property>
   ```
   7. Fully configured
   ```
   <property>
           <name>gateway.session.verification.unlimited.users</name>
           <value>admin</value>
   </property>
   <property>
           <name>gateway.session.verification.privileged.users</name>
           <value>tom</value>
   </property>
   <property>
           <name>gateway.session.verification.privileged.user.limit</name>
           <value>2</value>
   </property>
   <property>
           <name>gateway.session.verification.non.privileged.user.limit</name>
           <value>1</value>
   </property>
   <property>
           
<name>gateway.session.verification.expired.tokens.cleaning.period</name>
           <value>80</value>
   </property>
   <property>
           <name>gateway.service.concurrentsessionverifier.impl</name>
           
<value>org.apache.knox.gateway.session.control.InMemoryConcurrentSessionVerifier</value>
   </property>
   ```
   
   
   


-- 
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