You are viewing a plain text version of this content. The canonical link for it is here.
Posted to dev@knox.apache.org by "hanicz (via GitHub)" <gi...@apache.org> on 2025/03/06 13:25:52 UTC

[PR] KNOX-3108: Append classpath with additional paths [knox]

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

   ## What changes were proposed in this pull request?
   
   [KNOX-3047](https://issues.apache.org/jira/projects/KNOX/issues/KNOX-3047) Extended the classpath with /usr/share/java/*.jar however it could cause issues if other data-services use the same location for their jars. This PR iterates on the changes introduced in [KNOX-3051](https://issues.apache.org/jira/projects/KNOX/issues/KNOX-3051) and makes it possible to prepend and/or append paths to the classpath dynamically using the `gateway-site.xml` configuration file.
   
   To append new path(s) to the classpath add the below property to `gateway-site.xml`:
   
   ```
   <property>
           <name>gateway.server.append.classpath</name>
           <value>/new/append/path/*.jar</value>
   </property>
   ```
   
   To prepend new path(s) to the classpath add the below property to `gateway-site.xml`:
   
   ```
   <property>
           <name>gateway.server.prepend.classpath</name>
           <value>/new/prepend/path/*.jar</value>
   </property>
   ```
   
   The different locations should be separated by ',' or ';'.
   - '*.jar': picks up all jar files in the folder.
   - '*': picks up all files in the folder.
   - '/folder': class files are picked up from various folder hierarchies (eq. put GatewayServer.class in org/apache/knox/gateway folder)
   
   ## How was this patch tested?
   
   Unit tests
   Manual tested locally
   


-- 
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: dev-unsubscribe@knox.apache.org

For queries about this service, please contact Infrastructure at:
users@infra.apache.org


Re: [PR] KNOX-3108: Append classpath with additional paths [knox]

Posted by "lmccay (via GitHub)" <gi...@apache.org>.
lmccay merged PR #1004:
URL: https://github.com/apache/knox/pull/1004


-- 
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: dev-unsubscribe@knox.apache.org

For queries about this service, please contact Infrastructure at:
users@infra.apache.org


Re: [PR] KNOX-3108: Append classpath with additional paths [knox]

Posted by "lmccay (via GitHub)" <gi...@apache.org>.
lmccay commented on PR #1004:
URL: https://github.com/apache/knox/pull/1004#issuecomment-2706636107

   Thanks, @hanicz - this has been merged and will land in the Apache Knox 2.2.0 release!


-- 
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: dev-unsubscribe@knox.apache.org

For queries about this service, please contact Infrastructure at:
users@infra.apache.org