Re: [discussion] thoughts on https://issues.apache.org/jira/browse/KARAF-1545 ?

2013-05-13 Thread Achim Nierbeck
Hi,

ok, I'd like to get the discussion into the dev-list away from the jira
issue :-)

Now, I've heard both sides of the story and tbh, it's not an easy thing
here.
I agree that it's not a understandable solution to have bootloaded jars
with a karaf- prefix.
I'm not sure about the bundle looking for external jars in the lib folder,
it feels almost like an
extra file-installer thing bound to the lib folder.
@Dan could you please elaborate your use-case for placing your custom
libraries in this folder
and how you use them?

I also agree that a JDBC driver should be used as a bundle and not like a
bootloader jar, though I'm not sure
if this is also doable for the failover configuration.
One of the comments mentioned that it might be a better solution to look
for bootloaded jars in the
lib/karaf folder. Right now to me it sounds most likely to be the only
working solution. Especially since we
do have those extra bundles that are managed by the karaf main class.

regards, Achim


2013/5/13 Freeman Fang freeman.f...@gmail.com

 I'm also concerned about this change, added my comment in KARAF-1545
 -
 Freeman(Yue) Fang

 Red Hat, Inc.
 FuseSource is now part of Red Hat
 Web: http://fusesource.com | http://www.redhat.com/
 Twitter: freemanfang
 Blog: http://freemanfang.blogspot.com
 http://blog.sina.com.cn/u/1473905042
 weibo: @Freeman小屋

 www.camelone.org : The open source integration conference:

 On 2013-5-13, at 下午1:53, Dan Tran wrote:

  Hi,
 
  I have addressed my concerns on this enhancement, and would like to hear
  more from dev group.
 
  Big Thanks
 
  -Dan




-- 

Apache Karaf http://karaf.apache.org/ Committer  PMC
OPS4J Pax Web http://wiki.ops4j.org/display/paxweb/Pax+Web/ Committer 
Project Lead
OPS4J Pax for Vaadin http://team.ops4j.org/wiki/display/PAXVAADIN/Home
Commiter  Project Lead
blog http://notizblog.nierbeck.de/


Re: [discussion] thoughts on https://issues.apache.org/jira/browse/KARAF-1545 ?

2013-05-13 Thread Guillaume Nodet
AFAIK, all jar files in the lib folder are added to the classpath, so if
anyone want to add jars globally without using bundles, that's the way to
go.
See
https://github.com/apache/karaf/blob/trunk/main/src/main/java/org/apache/karaf/main/Main.java#L266

The lib/ext lib/endorsed and lib/karaf-*.jar are used to create the JVM
application classloader and make sure the initial environment is quite safe
and undisturbed.
All other lib/*.jar files are added to the classloader used to create the
OSGi framework and should be available

For JDBC drivers, they need to be available from the application
classloader, so what could be done without changing the current behavior
and introducing incompatibilities is to add a lib/app/ folder which would
be added to the application classloader (i.e. in the shell scripts).

Thoughts ?



2013/5/13 Achim Nierbeck bcanh...@googlemail.com

 Hi,

 ok, I'd like to get the discussion into the dev-list away from the jira
 issue :-)

 Now, I've heard both sides of the story and tbh, it's not an easy thing
 here.
 I agree that it's not a understandable solution to have bootloaded jars
 with a karaf- prefix.
 I'm not sure about the bundle looking for external jars in the lib folder,
 it feels almost like an
 extra file-installer thing bound to the lib folder.
 @Dan could you please elaborate your use-case for placing your custom
 libraries in this folder
 and how you use them?

 I also agree that a JDBC driver should be used as a bundle and not like a
 bootloader jar, though I'm not sure
 if this is also doable for the failover configuration.
 One of the comments mentioned that it might be a better solution to look
 for bootloaded jars in the
 lib/karaf folder. Right now to me it sounds most likely to be the only
 working solution. Especially since we
 do have those extra bundles that are managed by the karaf main class.

 regards, Achim


 2013/5/13 Freeman Fang freeman.f...@gmail.com

  I'm also concerned about this change, added my comment in KARAF-1545
  -
  Freeman(Yue) Fang
 
  Red Hat, Inc.
  FuseSource is now part of Red Hat
  Web: http://fusesource.com | http://www.redhat.com/
  Twitter: freemanfang
  Blog: http://freemanfang.blogspot.com
  http://blog.sina.com.cn/u/1473905042
  weibo: @Freeman小屋
 
  www.camelone.org : The open source integration conference:
 
  On 2013-5-13, at 下午1:53, Dan Tran wrote:
 
   Hi,
  
   I have addressed my concerns on this enhancement, and would like to
 hear
   more from dev group.
  
   Big Thanks
  
   -Dan
 
 


 --

 Apache Karaf http://karaf.apache.org/ Committer  PMC
 OPS4J Pax Web http://wiki.ops4j.org/display/paxweb/Pax+Web/ Committer 
 Project Lead
 OPS4J Pax for Vaadin http://team.ops4j.org/wiki/display/PAXVAADIN/Home
 Commiter  Project Lead
 blog http://notizblog.nierbeck.de/



Re: [discussion] thoughts on https://issues.apache.org/jira/browse/KARAF-1545 ?

2013-05-13 Thread Freeman Fang
+1
-
Freeman(Yue) Fang

Red Hat, Inc. 
FuseSource is now part of Red Hat
Web: http://fusesource.com | http://www.redhat.com/
Twitter: freemanfang
Blog: http://freemanfang.blogspot.com
http://blog.sina.com.cn/u/1473905042
weibo: @Freeman小屋

www.camelone.org : The open source integration conference: 

On 2013-5-13, at 下午3:46, Guillaume Nodet wrote:

 AFAIK, all jar files in the lib folder are added to the classpath, so if
 anyone want to add jars globally without using bundles, that's the way to
 go.
 See
 https://github.com/apache/karaf/blob/trunk/main/src/main/java/org/apache/karaf/main/Main.java#L266
 
 The lib/ext lib/endorsed and lib/karaf-*.jar are used to create the JVM
 application classloader and make sure the initial environment is quite safe
 and undisturbed.
 All other lib/*.jar files are added to the classloader used to create the
 OSGi framework and should be available
 
 For JDBC drivers, they need to be available from the application
 classloader, so what could be done without changing the current behavior
 and introducing incompatibilities is to add a lib/app/ folder which would
 be added to the application classloader (i.e. in the shell scripts).
 
 Thoughts ?
 
 
 
 2013/5/13 Achim Nierbeck bcanh...@googlemail.com
 
 Hi,
 
 ok, I'd like to get the discussion into the dev-list away from the jira
 issue :-)
 
 Now, I've heard both sides of the story and tbh, it's not an easy thing
 here.
 I agree that it's not a understandable solution to have bootloaded jars
 with a karaf- prefix.
 I'm not sure about the bundle looking for external jars in the lib folder,
 it feels almost like an
 extra file-installer thing bound to the lib folder.
 @Dan could you please elaborate your use-case for placing your custom
 libraries in this folder
 and how you use them?
 
 I also agree that a JDBC driver should be used as a bundle and not like a
 bootloader jar, though I'm not sure
 if this is also doable for the failover configuration.
 One of the comments mentioned that it might be a better solution to look
 for bootloaded jars in the
 lib/karaf folder. Right now to me it sounds most likely to be the only
 working solution. Especially since we
 do have those extra bundles that are managed by the karaf main class.
 
 regards, Achim
 
 
 2013/5/13 Freeman Fang freeman.f...@gmail.com
 
 I'm also concerned about this change, added my comment in KARAF-1545
 -
 Freeman(Yue) Fang
 
 Red Hat, Inc.
 FuseSource is now part of Red Hat
 Web: http://fusesource.com | http://www.redhat.com/
 Twitter: freemanfang
 Blog: http://freemanfang.blogspot.com
 http://blog.sina.com.cn/u/1473905042
 weibo: @Freeman小屋
 
 www.camelone.org : The open source integration conference:
 
 On 2013-5-13, at 下午1:53, Dan Tran wrote:
 
 Hi,
 
 I have addressed my concerns on this enhancement, and would like to
 hear
 more from dev group.
 
 Big Thanks
 
 -Dan
 
 
 
 
 --
 
 Apache Karaf http://karaf.apache.org/ Committer  PMC
 OPS4J Pax Web http://wiki.ops4j.org/display/paxweb/Pax+Web/ Committer 
 Project Lead
 OPS4J Pax for Vaadin http://team.ops4j.org/wiki/display/PAXVAADIN/Home
 Commiter  Project Lead
 blog http://notizblog.nierbeck.de/
 



Re: [discussion] thoughts on https://issues.apache.org/jira/browse/KARAF-1545 ?

2013-05-13 Thread Achim Nierbeck
+1


2013/5/13 Jean-Baptiste Onofré j...@nanthrax.net

 +1

 Regards
 JB


 On 05/13/2013 09:46 AM, Guillaume Nodet wrote:

 AFAIK, all jar files in the lib folder are added to the classpath, so if
 anyone want to add jars globally without using bundles, that's the way to
 go.
 See
 https://github.com/apache/**karaf/blob/trunk/main/src/**
 main/java/org/apache/karaf/**main/Main.java#L266https://github.com/apache/karaf/blob/trunk/main/src/main/java/org/apache/karaf/main/Main.java#L266

 The lib/ext lib/endorsed and lib/karaf-*.jar are used to create the JVM
 application classloader and make sure the initial environment is quite
 safe
 and undisturbed.
 All other lib/*.jar files are added to the classloader used to create the
 OSGi framework and should be available

 For JDBC drivers, they need to be available from the application
 classloader, so what could be done without changing the current behavior
 and introducing incompatibilities is to add a lib/app/ folder which would
 be added to the application classloader (i.e. in the shell scripts).

 Thoughts ?



 2013/5/13 Achim Nierbeck bcanh...@googlemail.com

  Hi,

 ok, I'd like to get the discussion into the dev-list away from the jira
 issue :-)

 Now, I've heard both sides of the story and tbh, it's not an easy thing
 here.
 I agree that it's not a understandable solution to have bootloaded jars
 with a karaf- prefix.
 I'm not sure about the bundle looking for external jars in the lib
 folder,
 it feels almost like an
 extra file-installer thing bound to the lib folder.
 @Dan could you please elaborate your use-case for placing your custom
 libraries in this folder
 and how you use them?

 I also agree that a JDBC driver should be used as a bundle and not like a
 bootloader jar, though I'm not sure
 if this is also doable for the failover configuration.
 One of the comments mentioned that it might be a better solution to look
 for bootloaded jars in the
 lib/karaf folder. Right now to me it sounds most likely to be the only
 working solution. Especially since we
 do have those extra bundles that are managed by the karaf main class.

 regards, Achim


 2013/5/13 Freeman Fang freeman.f...@gmail.com

  I'm also concerned about this change, added my comment in KARAF-1545
 -
 Freeman(Yue) Fang

 Red Hat, Inc.
 FuseSource is now part of Red Hat
 Web: http://fusesource.com | http://www.redhat.com/
 Twitter: freemanfang
 Blog: http://freemanfang.blogspot.**comhttp://freemanfang.blogspot.com
 http://blog.sina.com.cn/u/**1473905042http://blog.sina.com.cn/u/1473905042
 weibo: @Freeman小屋

 www.camelone.org : The open source integration conference:

 On 2013-5-13, at 下午1:53, Dan Tran wrote:

  Hi,

 I have addressed my concerns on this enhancement, and would like to

 hear

 more from dev group.

 Big Thanks

 -Dan





 --

 Apache Karaf http://karaf.apache.org/ Committer  PMC
 OPS4J Pax Web 
 http://wiki.ops4j.org/**display/paxweb/Pax+Web/http://wiki.ops4j.org/display/paxweb/Pax+Web/
 Committer 
 Project Lead
 OPS4J Pax for Vaadin http://team.ops4j.org/wiki/**
 display/PAXVAADIN/Homehttp://team.ops4j.org/wiki/display/PAXVAADIN/Home
 
 Commiter  Project Lead
 blog http://notizblog.nierbeck.de/**



 --
 Jean-Baptiste Onofré
 jbono...@apache.org
 http://blog.nanthrax.net
 Talend - http://www.talend.com




-- 

Apache Karaf http://karaf.apache.org/ Committer  PMC
OPS4J Pax Web http://wiki.ops4j.org/display/paxweb/Pax+Web/ Committer 
Project Lead
OPS4J Pax for Vaadin http://team.ops4j.org/wiki/display/PAXVAADIN/Home
Commiter  Project Lead
blog http://notizblog.nierbeck.de/


Re: [discussion] thoughts on https://issues.apache.org/jira/browse/KARAF-1545 ?

2013-05-13 Thread Heath Kesler
+1

Will revert to karaf prefix in the lib and add a sub directory for any required 
external jar without karat prefix.

On May 12, 2013, at 11:53 PM, Dan Tran dant...@gmail.com wrote:

 Hi,
 
 I have addressed my concerns on this enhancement, and would like to hear
 more from dev group.
 
 Big Thanks
 
 -Dan



Re: [discussion] thoughts on https://issues.apache.org/jira/browse/KARAF-1545 ?

2013-05-13 Thread Guillaume Nodet
2013/5/13 Dan Tran dant...@gmail.com

 For my case, my distribution consists of Karaf container + our bunbles, + a
 bunch of stand alone apps with bootstrap/startup script generated by
 appassembler-maven-plugin[1].

 The standalone apps ( command line utilities, swing app, etc ) have its
 jars placed under lib directory where the startup/boostrap script will use
 to construct the extract classpath.

 Now, base on Guillaume Nodet comments, I have to think hard about my
 approach, since karaf indirectly load all the jars under lib directory to
 its class loader.  The question here, which class loader are we talking
 about here ( system? ) and which component under karaf would care about
 this hidden feature?


The only change I suggested is to slightly alter the shell script to add
lib/system/*.jar to the classpath.
That keeps all existing installation unchanged and allow more control for
the jdbc driver use case.
We need to correctly document the classloading mechanism, but it's a
minimal change which imho cleanly support the needed use case.



 Thanks

 -D



 [1]

 http://mojo.codehaus.org/appassembler/appassembler-maven-plugin/assemble-mojo.html


 On Mon, May 13, 2013 at 7:40 AM, Heath Kesler heathkes...@gmail.com
 wrote:

  +1
 
  Will revert to karaf prefix in the lib and add a sub directory for any
  required external jar without karat prefix.
 
  On May 12, 2013, at 11:53 PM, Dan Tran dant...@gmail.com wrote:
 
   Hi,
  
   I have addressed my concerns on this enhancement, and would like to
 hear
   more from dev group.
  
   Big Thanks
  
   -Dan
 
 



Re: [discussion] thoughts on https://issues.apache.org/jira/browse/KARAF-1545 ?

2013-05-13 Thread Dan Tran
Hi Guillaume,

I am living dangerously by placing my stand-alone apps's jars under lib
directory since karaf is currently pushing those jars into osgi framework
classloader?

Thanks

-Dan




On Mon, May 13, 2013 at 10:55 AM, Guillaume Nodet gno...@apache.org wrote:

 2013/5/13 Dan Tran dant...@gmail.com

  For my case, my distribution consists of Karaf container + our bunbles,
 + a
  bunch of stand alone apps with bootstrap/startup script generated by
  appassembler-maven-plugin[1].
 
  The standalone apps ( command line utilities, swing app, etc ) have its
  jars placed under lib directory where the startup/boostrap script will
 use
  to construct the extract classpath.
 
  Now, base on Guillaume Nodet comments, I have to think hard about my
  approach, since karaf indirectly load all the jars under lib directory to
  its class loader.  The question here, which class loader are we talking
  about here ( system? ) and which component under karaf would care about
  this hidden feature?
 

 The only change I suggested is to slightly alter the shell script to add
 lib/system/*.jar to the classpath.
 That keeps all existing installation unchanged and allow more control for
 the jdbc driver use case.
 We need to correctly document the classloading mechanism, but it's a
 minimal change which imho cleanly support the needed use case.


 
  Thanks
 
  -D
 
 
 
  [1]
 
 
 http://mojo.codehaus.org/appassembler/appassembler-maven-plugin/assemble-mojo.html
 
 
  On Mon, May 13, 2013 at 7:40 AM, Heath Kesler heathkes...@gmail.com
  wrote:
 
   +1
  
   Will revert to karaf prefix in the lib and add a sub directory for any
   required external jar without karat prefix.
  
   On May 12, 2013, at 11:53 PM, Dan Tran dant...@gmail.com wrote:
  
Hi,
   
I have addressed my concerns on this enhancement, and would like to
  hear
more from dev group.
   
Big Thanks
   
-Dan
  
  
 



[discussion] thoughts on https://issues.apache.org/jira/browse/KARAF-1545 ?

2013-05-12 Thread Dan Tran
Hi,

I have addressed my concerns on this enhancement, and would like to hear
more from dev group.

Big Thanks

-Dan


Re: [discussion] thoughts on https://issues.apache.org/jira/browse/KARAF-1545 ?

2013-05-12 Thread Jean-Baptiste Onofré

Hi Dan,

I'm back in the business, I gonna review KARAF-1545 today.

Regards
JB

On 05/13/2013 07:53 AM, Dan Tran wrote:

Hi,

I have addressed my concerns on this enhancement, and would like to hear
more from dev group.

Big Thanks

-Dan



--
Jean-Baptiste Onofré
jbono...@apache.org
http://blog.nanthrax.net
Talend - http://www.talend.com