karaf:features-generate-descriptor goal generated feature dependency problem

2014-05-26 Thread ellirael
I'm using karaf-maven-plugin/3.0.1 to build my feature projects.

pom.xml dependency section:


${project.groupId}
person.api.feature
${project.version}
features
xml


${project.groupId}
person.impl.simple
${project.version}


${project.groupId}
person.command
${project.version}



my feature.xml file:

http://karaf.apache.org/xmlns/features/v1.0.0";>




According to this text:
aggregateFeatures   boolean (false) Specifies processing of feature
repositories that are (transitive) Maven dependencies. If false, all
features in these repositories become dependencies of the generated feature.
If true, all features in these repositories are copied into the generated
feature repository. 

when I build my feature project with aggregateFeatures set to false I should
get attached artifact file looks like this:



person.api.feature
mvn:group/person.impl.simple/0.0.0
mvn:group/person.command/0.0.0



But I get file looks like this:



mvn:group/person.impl.simple/0.0.0
mvn:group/person.command/0.0.0



No depended feature line included.
When I try to resolve dependencies with maven resolver I see bundles from
person.api.feature included in dependency list. But karaf-maven.plugin miss
them.




--
View this message in context: 
http://karaf.922171.n3.nabble.com/karaf-features-generate-descriptor-goal-generated-feature-dependency-problem-tp4033282.html
Sent from the Karaf - User mailing list archive at Nabble.com.


RE: JPA with Karaf

2014-05-26 Thread Ephemeris Lappis
Hello.

I'm testing Hibernate on ServiceMix, and I have similar problems.
I've tried using the Hibernate 4.2.7 that comes with ServiceMix 5.0.1, but
as it did work, I've built a simple feature with the 4.2.12.
I had the same error that you described about the the EntityManagerFactory,
and stopping the Hibernate-OSGi bundle before I deploy my bundles seemed to
resolve the issue.
Thanks for the trick !
But when I test it all, I have now a problem with the transaction that seems
no to be commited at the end of my service call, and, therefore, the
persisted entities are not really inserted into the database. I use the
tx:transaction declaration in the service blueprint, but it doesn't work.
Did you experience such problems ?
Thanks.
Regards.



--
View this message in context: 
http://karaf.922171.n3.nabble.com/JPA-with-Karaf-tp4031000p4033281.html
Sent from the Karaf - User mailing list archive at Nabble.com.


Re: karaf feature absolute path problem

2014-05-26 Thread Jean-Baptiste Onofré

Hi Seb,

you can populate your system folder (it's a maven structure): like this 
Karaf will look for the system folder before going to the "remote" repo.


Did you try it ?

I'm not sure to follow you for "relative path". WDYM ?

Regards
JB

On 05/26/2014 02:46 PM, DERIES Sebastien wrote:

Hi JB ,

thank you for your answer.

When I install my bundles on my development machine, the maven
repository is found and so do the configuration files. However on my my
target platform I do not (and will never)  have access to the maven
repository. That’s why we build and install our bundles on a development
on our development machine and copy the built KARAF on our target
platform. The problem I have occurs only  on an already installed KARAF.

I thought that after installing features, everything was relative to
karaf home which seems not to be the case.  Can I tune the
etc/org.ops4j.pax.url.mvn.cfg so that everything is configured as
relative path?







*Sébastien Deries*
Tel. : + 33 (0)4 92 96 31 52
sebastien.der...@thalesgroup.com **



[@@ THALES GROUP INTERNAL @@]

*De :*j...@nanthrax.net [mailto:j...@nanthrax.net]
*Envoyé :* lundi 26 mai 2014 14:06
*À :* user@karaf.apache.org; user@karaf.apache.org
*Objet :* Re: karaf feature absolute path problem

Hi,

You have to define the maven repo (and being able to access to the repo)
in etc/org.ops4j.pax.url.mvn.cfg.
More over, the user launching karaf has to have the write permission.

Is it the case ?

Regards
JB

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

- Reply message -
From: "DERIES Sebastien" mailto:sebastien.der...@thalesgroup.com>>
To: "user@karaf.apache.org "
mailto:user@karaf.apache.org>>
Subject: karaf feature absolute path problem
Date: Mon, May 26, 2014 1:53 pm

Hi all,

I’m using apache-karaf-3.0.0.RC1, with Java 8u20 on Linux Red hat 6.2.

We use karaf features to install our bundles and configuration files
into KARAF.

Example:



mvn:
package.lang/language/0.0.1-SNAPSHOT/cfg

mvn:package.lang/language/0.0.1-SNAPSHOT



Everything works perfectly fine when we install and run our application
on our development machine. However when we run a copied version of
karaf on our integration platform, KARAF cannot find the configuration file.

We got a File not found exception saying that karaf wants a file on the
KARAF_HOME/etc development machine instead of getting the configuration
file from the integration platform KARAF_HOME/etc. example:
/useraccounts/myuser/KARAF/ apache-karaf-3.0.0.RC1/etc/package.lang.cfg
instead of ./etc/package.lang.cfg

It seems that feature installation uses absolute path for configuration
files instead of a relative path.

Is there a way to configure features to use relative path? Or to set the
a feature home directory?

Thanks a lot.







*Sébastien Deries*
Tel. : + 33 (0)4 92 96 31 52
sebastien.der...@thalesgroup.com **



[@@ THALES GROUP INTERNAL @@]



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


RE: karaf feature absolute path problem

2014-05-26 Thread DERIES Sebastien
Hi JB ,
thank you for your answer.
When I install my bundles on my development machine, the maven repository is 
found and so do the configuration files. However on my my target platform I do 
not (and will never)  have access to the maven repository. That’s why we build 
and install our bundles on a development on our development machine and copy 
the built KARAF on our target platform. The problem I have occurs only  on an 
already installed KARAF.

I thought that after installing features, everything was relative to karaf home 
which seems not to be the case.  Can I tune the etc/org.ops4j.pax.url.mvn.cfg 
so that everything is configured as relative path ?







Sébastien Deries
Tel. : + 33 (0)4 92 96 31 52
sebastien.der...@thalesgroup.com


[@@ THALES GROUP INTERNAL @@]

De : j...@nanthrax.net [mailto:j...@nanthrax.net]
Envoyé : lundi 26 mai 2014 14:06
À : user@karaf.apache.org; user@karaf.apache.org
Objet : Re: karaf feature absolute path problem

Hi,

You have to define the maven repo (and being able to access to the repo) in 
etc/org.ops4j.pax.url.mvn.cfg.
More over, the user launching karaf has to have the write permission.

Is it the case ?

Regards
JB

--
Jean-Baptiste Onofré
jbono...@apache.org
http://blog.nanthrax.net
Talend - http://wwx.talend.com
- Reply message -
From: "DERIES Sebastien" 
mailto:sebastien.der...@thalesgroup.com>>
To: "user@karaf.apache.org" 
mailto:user@karaf.apache.org>>
Subject: karaf feature absolute path problem
Date: Mon, May 26, 2014 1:53 pm

Hi all,

I’m using apache-karaf-3.0.0.RC1, with Java 8u20 on Linux Red hat 6.2.

We use karaf features to install our bundles and configuration files into KARAF.
Example:

   mvn: 
package.lang/language/0.0.1-SNAPSHOT/cfg
   mvn:package.lang/language/0.0.1-SNAPSHOT


Everything works perfectly fine when we install and run our application on our 
development machine. However when we run a copied version of karaf on our 
integration platform, KARAF cannot find the configuration file.

We got a File not found exception saying that karaf wants a file on the 
KARAF_HOME/etc development machine instead of getting the configuration file 
from the integration platform KARAF_HOME/etc. example: 
/useraccounts/myuser/KARAF/ apache-karaf-3.0.0.RC1/etc/package.lang.cfg instead 
of ./etc/package.lang.cfg

It seems that feature installation uses absolute path for configuration files 
instead of a relative path.

Is there a way to configure features to use relative path? Or to set the a 
feature home directory?

Thanks a lot.






Sébastien Deries
Tel. : + 33 (0)4 92 96 31 52
sebastien.der...@thalesgroup.com


[@@ THALES GROUP INTERNAL @@]



Re: karaf feature absolute path problem

2014-05-26 Thread j...@nanthrax.net
Hi,

You have to define the maven repo (and being able to access to the repo) in 
etc/org.ops4j.pax.url.mvn.cfg.
More over, the user launching karaf has to have the write permission.

Is it the case ?

Regards
JB

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

- Reply message -
From: "DERIES Sebastien" 
To: "user@karaf.apache.org" 
Subject: karaf feature absolute path problem
Date: Mon, May 26, 2014 1:53 pm
Hi all, I’m using apache-karaf-3.0.0.RC1, with Java 8u20 on Linux Red hat 6.2. 
We use karaf features to install our bundles and configuration files into 
KARAF. Example:   
mvn: 
package.lang/language/0.0.1-SNAPSHOT/cfg   
    mvn:package.lang/language/0.0.1-SNAPSHOT 
Everything works perfectly fine when we install and run our application on our 
development machine. However when we run a copied version of karaf on our 
integration platform, KARAF cannot find the configuration file. We got a File 
not found exception saying that karaf wants a file on the KARAF_HOME/etc 
development machine instead of getting the configuration file from the 
integration platform KARAF_HOME/etc. example: /useraccounts/myuser/KARAF/ 
apache-karaf-3.0.0.RC1/etc/package.lang.cfg instead of ./etc/package.lang.cfg  
It seems that feature installation uses absolute path for configuration files 
instead of a relative path. Is there a way to configure features to use 
relative path? Or to set the a feature home directory? Thanks a lot. 
Sébastien Deries 
Tel. : + 33 (0)4 92 96 31 52
sebastien.der...@thalesgroup.com [@@ THALES GROUP INTERNAL @@]

karaf feature absolute path problem

2014-05-26 Thread DERIES Sebastien
Hi all,

I'm using apache-karaf-3.0.0.RC1, with Java 8u20 on Linux Red hat 6.2.

We use karaf features to install our bundles and configuration files into KARAF.
Example:

   mvn: 
package.lang/language/0.0.1-SNAPSHOT/cfg
   mvn:package.lang/language/0.0.1-SNAPSHOT


Everything works perfectly fine when we install and run our application on our 
development machine. However when we run a copied version of karaf on our 
integration platform, KARAF cannot find the configuration file.

We got a File not found exception saying that karaf wants a file on the 
KARAF_HOME/etc development machine instead of getting the configuration file 
from the integration platform KARAF_HOME/etc. example: 
/useraccounts/myuser/KARAF/ apache-karaf-3.0.0.RC1/etc/package.lang.cfg instead 
of ./etc/package.lang.cfg

It seems that feature installation uses absolute path for configuration files 
instead of a relative path.

Is there a way to configure features to use relative path? Or to set the a 
feature home directory?

Thanks a lot.






Sébastien Deries
Tel. : + 33 (0)4 92 96 31 52
sebastien.der...@thalesgroup.com


[@@ THALES GROUP INTERNAL @@]