You are viewing a plain text version of this content. The canonical link for it is here.
Posted to dev@ofbiz.apache.org by Pierre Smits <pi...@gmail.com> on 2012/04/10 15:04:05 UTC

Building with Jenkins - cobertura and sonar

Hi Erwan,

In build.xml is following code:

        <!-- list of optional Sonar properties -->

        <property name="sonar.projectName" value="Apache OFBiz" />

        <sonar:sonar key="org.apache:ofbiz" version=
"${info.entry.commit(revision)}" xmlns:sonar="antlib:org.sonar.ant:sonar"/>

        <property name="sonar.dynamicAnalysis" value="reuseReports" />

        <property name="sonar.cobertura.reportPath" value=
"runtime/logs/cobertura-report/coverage.xml"/>

        <property name="sonar.java.source" value="1.6" />

        <property name="sonar.java.target" value="1.6" />

        <property name="sonar.jdbc.url"

           value=
"jdbc:mysql://localhost:3306/sonar?useUnicode=true&amp;characterEncoding=utf8"
/>

        <property name="sonar.jdbc.driverClassName" value=
"com.mysql.jdbc.Driver" />

        <property name="sonar.jdbc.username" value="${sonar.jdbc.username}"
/>

        <property name="sonar.jdbc.password" value="${sonar.jdbc.password}"
/>

I am trying to set this up and I have following questions:

   1. Should the mySQL driver be in framework/entity/lib/jdbc folder?
   2. My mySQL db for sonar is on a different server (not localhost). Must
   I adjust build.xml or pass it as a parameter?
   3. Am I correct to understand that both ${sonar.jdbc.username}
   and ${sonar.jdbc.password} are to be passed as parameters when triggering
   the target, or are they supposed to be set in build.xml?

I appreciate your input.

Regards,

Pierre

Re: Building with Jenkins - cobertura and sonar

Posted by Erwan de FERRIERES <er...@nereide.fr>.
Le 11/04/2012 22:50, Pierre Smits a écrit :
> Hi Erwan,
>
> I am a bit confused here. I have sonar running on a separate VM, with my
> db on yet another VM. I have sonar running and according to what I see
> in sonar.properties it looks ok.
>
> Do you intend to say that I need an additional sonar.properties file in
> my OFBiz download?

then you just have to configure your properties sonar.jdbc.password, 
user and url when running the task with OFBiz
Nothing more.

>
> Regards,
>
> Pierre
>
> Op 11 april 2012 21:53 schreef Erwan de FERRIERES
> <erwan.de-ferrieres@nereide.fr <ma...@nereide.fr>>
> het volgende:
>
>     Le 11/04/2012 20:49, Pierre Smits a écrit :
>
>         Hi Erwan,
>
>         I tried ant sonar (after doing a clean-all and load-demo)
>         against my mySQL
>         where the repository of sonar resides and I got following:
>
>         /Users/s0001/Documents/__workspace/ofbiz-trunk/build.__xml:1060:
>         org.picocontainer.__PicoLifecycleException:
>         PicoLifecycleException: method
>         'public final org.sonar.persistence.__DefaultDatabase
>
>
>     Hi Pierre,
>     have you configured the sonar.properties file ?
>     once this done, you have to start your sonar instance, and it will
>     create the database schema. I just tried it yesterday, and this is
>     working very well.
>
>
>     Cheers,
>
>
>     --
>     Erwan de FERRIERES
>     www.nereide.biz <http://www.nereide.biz>
>
>


-- 
Erwan de FERRIERES
www.nereide.biz

Re: Building with Jenkins - cobertura and sonar

Posted by Pierre Smits <pi...@gmail.com>.
Hi Erwan,

I am a bit confused here. I have sonar running on a separate VM, with my db
on yet another VM. I have sonar running and according to what I see in
sonar.properties it looks ok.

Do you intend to say that I need an additional sonar.properties file in my
OFBiz download?

Regards,

Pierre

Op 11 april 2012 21:53 schreef Erwan de FERRIERES <
erwan.de-ferrieres@nereide.fr> het volgende:

> Le 11/04/2012 20:49, Pierre Smits a écrit :
>
>  Hi Erwan,
>>
>> I tried ant sonar (after doing a clean-all and load-demo) against my mySQL
>> where the repository of sonar resides and I got following:
>>
>> /Users/s0001/Documents/**workspace/ofbiz-trunk/build.**xml:1060:
>> org.picocontainer.**PicoLifecycleException: PicoLifecycleException:
>> method
>> 'public final org.sonar.persistence.**DefaultDatabase
>>
>
> Hi Pierre,
> have you configured the sonar.properties file ?
> once this done, you have to start your sonar instance, and it will create
> the database schema. I just tried it yesterday, and this is working very
> well.
>
>
> Cheers,
>
>
> --
> Erwan de FERRIERES
> www.nereide.biz
>

Re: Building with Jenkins - cobertura and sonar

Posted by Erwan de FERRIERES <er...@nereide.fr>.
Le 11/04/2012 20:49, Pierre Smits a écrit :
> Hi Erwan,
>
> I tried ant sonar (after doing a clean-all and load-demo) against my mySQL
> where the repository of sonar resides and I got following:
>
> /Users/s0001/Documents/workspace/ofbiz-trunk/build.xml:1060:
> org.picocontainer.PicoLifecycleException: PicoLifecycleException: method
> 'public final org.sonar.persistence.DefaultDatabase

Hi Pierre,
have you configured the sonar.properties file ?
once this done, you have to start your sonar instance, and it will 
create the database schema. I just tried it yesterday, and this is 
working very well.

Cheers,


-- 
Erwan de FERRIERES
www.nereide.biz

Re: Building with Jenkins - cobertura and sonar

Posted by Pierre Smits <pi...@gmail.com>.
Hi Erwan,

I tried ant sonar (after doing a clean-all and load-demo) against my mySQL
where the repository of sonar resides and I got following:

/Users/s0001/Documents/workspace/ofbiz-trunk/build.xml:1060:
org.picocontainer.PicoLifecycleException: PicoLifecycleException: method
'public final org.sonar.persistence.DefaultDatabase
org.sonar.persistence.DefaultDatabase.start()', instance
'org.sonar.batch.bootstrap.BatchDatabase@57f5b4d1,
java.lang.RuntimeException: wrapper
at
org.picocontainer.monitors.NullComponentMonitor.lifecycleInvocationFailed(NullComponentMonitor.java:77)
at
org.picocontainer.lifecycle.ReflectionLifecycleStrategy.monitorAndThrowReflectionLifecycleException(ReflectionLifecycleStrategy.java:132)
at
org.picocontainer.lifecycle.ReflectionLifecycleStrategy.invokeMethod(ReflectionLifecycleStrategy.java:115)
at
org.picocontainer.lifecycle.ReflectionLifecycleStrategy.start(ReflectionLifecycleStrategy.java:89)
at
org.picocontainer.injectors.AbstractInjectionFactory$LifecycleAdapter.start(AbstractInjectionFactory.java:84)
at
org.picocontainer.behaviors.AbstractBehavior.start(AbstractBehavior.java:169)
at
org.picocontainer.behaviors.Stored$RealComponentLifecycle.start(Stored.java:132)
at org.picocontainer.behaviors.Stored.start(Stored.java:110)
at
org.picocontainer.DefaultPicoContainer.potentiallyStartAdapter(DefaultPicoContainer.java:996)
at
org.picocontainer.DefaultPicoContainer.startAdapters(DefaultPicoContainer.java:989)
at
org.picocontainer.DefaultPicoContainer.start(DefaultPicoContainer.java:746)
at
org.sonar.api.platform.ComponentContainer.startComponents(ComponentContainer.java:70)
at org.sonar.batch.bootstrap.Module.start(Module.java:82)
at org.sonar.batch.Batch.execute(Batch.java:100)
at org.sonar.ant.Launcher.executeBatch(Launcher.java:121)
at org.sonar.ant.Launcher.execute(Launcher.java:60)
at sun.reflect.NativeMethodAccessorImpl.invoke0(Native Method)
at
sun.reflect.NativeMethodAccessorImpl.invoke(NativeMethodAccessorImpl.java:39)
at
sun.reflect.DelegatingMethodAccessorImpl.invoke(DelegatingMethodAccessorImpl.java:25)
at java.lang.reflect.Method.invoke(Method.java:597)
at org.sonar.ant.SonarTask.delegateExecution(SonarTask.java:167)
at org.sonar.ant.SonarTask.execute(SonarTask.java:151)
at org.apache.tools.ant.UnknownElement.execute(UnknownElement.java:291)
at sun.reflect.GeneratedMethodAccessor4.invoke(Unknown Source)
at
sun.reflect.DelegatingMethodAccessorImpl.invoke(DelegatingMethodAccessorImpl.java:25)
at java.lang.reflect.Method.invoke(Method.java:597)
at
org.apache.tools.ant.dispatch.DispatchUtils.execute(DispatchUtils.java:106)
at org.apache.tools.ant.Task.perform(Task.java:348)
at org.apache.tools.ant.Target.execute(Target.java:390)
at org.apache.tools.ant.Target.performTasks(Target.java:411)
at org.apache.tools.ant.Project.executeSortedTargets(Project.java:1399)
at org.apache.tools.ant.Project.executeTarget(Project.java:1368)
at
org.apache.tools.ant.helper.DefaultExecutor.executeTargets(DefaultExecutor.java:41)
at org.apache.tools.ant.Project.executeTargets(Project.java:1251)
at org.apache.tools.ant.Main.runBuild(Main.java:809)
at org.apache.tools.ant.Main.startAnt(Main.java:217)
at org.apache.tools.ant.launch.Launcher.run(Launcher.java:280)
at org.apache.tools.ant.launch.Launcher.main(Launcher.java:109)
Caused by: java.lang.RuntimeException: wrapper
at
org.picocontainer.lifecycle.ReflectionLifecycleStrategy.monitorAndThrowReflectionLifecycleException(ReflectionLifecycleStrategy.java:130)
... 36 more
Caused by: java.lang.IllegalStateException: Fail to connect to database
at org.sonar.persistence.DefaultDatabase.start(DefaultDatabase.java:65)
at sun.reflect.NativeMethodAccessorImpl.invoke0(Native Method)
at
sun.reflect.NativeMethodAccessorImpl.invoke(NativeMethodAccessorImpl.java:39)
at
sun.reflect.DelegatingMethodAccessorImpl.invoke(DelegatingMethodAccessorImpl.java:25)
at java.lang.reflect.Method.invoke(Method.java:597)
at
org.picocontainer.lifecycle.ReflectionLifecycleStrategy.invokeMethod(ReflectionLifecycleStrategy.java:110)
... 35 more
Caused by: org.apache.commons.dbcp.SQLNestedException: Cannot load JDBC
driver class 'org.apache.derby.jdbc.ClientDriver'
at
org.apache.commons.dbcp.BasicDataSource.createConnectionFactory(BasicDataSource.java:1429)
at
org.apache.commons.dbcp.BasicDataSource.createDataSource(BasicDataSource.java:1371)
at
org.apache.commons.dbcp.BasicDataSource.getLogWriter(BasicDataSource.java:1098)
at
org.apache.commons.dbcp.BasicDataSourceFactory.createDataSource(BasicDataSourceFactory.java:350)
at
org.sonar.persistence.DefaultDatabase.initDatasource(DefaultDatabase.java:71)
at org.sonar.persistence.DefaultDatabase.start(DefaultDatabase.java:61)
... 40 more
Caused by: java.lang.ClassNotFoundException:
org.apache.derby.jdbc.ClientDriver
at java.net.URLClassLoader$1.run(URLClassLoader.java:202)
at java.security.AccessController.doPrivileged(Native Method)
at java.net.URLClassLoader.findClass(URLClassLoader.java:190)
at java.lang.ClassLoader.loadClass(ClassLoader.java:306)
at java.lang.ClassLoader.loadClass(ClassLoader.java:247)
at
org.apache.commons.dbcp.BasicDataSource.createConnectionFactory(BasicDataSource.java:1420)
... 45 more

Total time: 15 seconds

It seems that it is still looking to access derby.

What do you make of this?

Regards,

Pierre

Op 10 april 2012 18:30 schreef Erwan de FERRIERES <
erwan.deferrieres@gmail.com> het volgende:

> Pierre,
> so sonar does not need any driver, just take a look in
> sonar-2.14/extensions/jdbc-driver
> You just need to configure the sonar.properties file.
>
> 2012/4/10 Pierre Smits <pi...@gmail.com>:
> > Hi Jacques,
> >
> > Postgresql is also my preferred choice of db, but OFBiz delivers on the
> > opportunity of using mySQL as a db platform. Using a download and install
> > mechanism as we have for Postgresql and other plugins (Cobertura, Sonar)
> > would help our endusers in their adoption of OFBiz, in stead of letting
> > them look for the appropriate driver, downloading and installing it
> > manually in the right place of OFBiz.
> >
> > I am just concerned about the legal (licence) implications of such a
> > functionality.
> >
> > Regards,
> >
> > Pierre
> >
> > Op 10 april 2012 17:33 schreef Jacques Le Roux <
> jacques.le.roux@les7arts.com
> >> het volgende:
> >
> >> Maybe out of subject, but I'd prefer Postgres and we have an ant task
> >> already for that (thanks to Erwan IIRW)
> >>
> >> Jacques
> >>
> >> From: "Pierre Smits" <pi...@gmail.com>
> >>
> >>  Hi Erwan,
> >>>
> >>> I think there might be an issue here regarding mysql. As licence is not
> >>> compatible/usable with ASF 2.0 we cannot include the mySQL jar by
> default.
> >>>
> >>> But if we want to do an automated reporting on OFBiz, trunk pulled from
> >>> svn, to sonar on mysql then the driver is needed. And manually pulling
> and
> >>> placing it in the correct folder on an automated process is very
> >>> cumbersome.
> >>>
> >>> I will submit a patch that will enable the user to do a download and
> >>> install with ivy, like the postgresql target. Does that fit our needs
> and
> >>> solve licence issue?
> >>>
> >>> Regards,
> >>>
> >>> Pierre
> >>>
> >>> Op 10 april 2012 16:20 schreef Pierre Smits <pi...@gmail.com>
> het
> >>> volgende:
> >>>
> >>>  Hi Erwan,
> >>>>
> >>>> I guess that the same would then be applicable for:
> >>>>
> >>>> <property key="sonar.host.url" value="${sonar.host.url}" />
> >>>>
> >>>> Regards,
> >>>>
> >>>> Pierre
> >>>>
> >>>>
> >>>>
> >>>>
> >>>> Op 10 april 2012 16:09 schreef Erwan de FERRIERES <
> >>>> erwan.deferrieres@gmail.com> het volgende:
> >>>>
> >>>> >
> >>>>
> >>>>> > I am trying to set this up and I have following questions:
> >>>>> >
> >>>>> I never used it with another DB than derby...
> >>>>> >   1. Should the mySQL driver be in framework/entity/lib/jdbc
> folder?
> >>>>> can't answer but I'll make some tests
> >>>>>
> >>>>> >   2. My mySQL db for sonar is on a different server (not
> localhost).
> >>>>> Must
> >>>>> >   I adjust build.xml or pass it as a parameter?
> >>>>> I'll change the parameter this way tonight: <property
> >>>>> name="sonar.jdbc.url" value="${sonar.jdbc.url}"/>
> >>>>>
> >>>>> >   3. Am I correct to understand that both ${sonar.jdbc.username}
> >>>>> >   and ${sonar.jdbc.password} are to be passed as parameters when
> >>>>> triggering
> >>>>> >   the target, or are they supposed to be set in build.xml?
> >>>>> parameters
> >>>>> >
> >>>>> parameters when the job is triggered.
> >>>>>
> >>>>> Cheers,
> >>>>>
> >>>>>
> >>>>>
> >>>>> --
> >>>>> Erwan de FERRIERES
> >>>>>
> >>>>>
> >>>>
> >>>>
> >>>
>
>
>
> --
> Erwan de FERRIERES
>

Re: Building with Jenkins - cobertura and sonar

Posted by Erwan de FERRIERES <er...@gmail.com>.
Pierre,
so sonar does not need any driver, just take a look in
sonar-2.14/extensions/jdbc-driver
You just need to configure the sonar.properties file.

2012/4/10 Pierre Smits <pi...@gmail.com>:
> Hi Jacques,
>
> Postgresql is also my preferred choice of db, but OFBiz delivers on the
> opportunity of using mySQL as a db platform. Using a download and install
> mechanism as we have for Postgresql and other plugins (Cobertura, Sonar)
> would help our endusers in their adoption of OFBiz, in stead of letting
> them look for the appropriate driver, downloading and installing it
> manually in the right place of OFBiz.
>
> I am just concerned about the legal (licence) implications of such a
> functionality.
>
> Regards,
>
> Pierre
>
> Op 10 april 2012 17:33 schreef Jacques Le Roux <jacques.le.roux@les7arts.com
>> het volgende:
>
>> Maybe out of subject, but I'd prefer Postgres and we have an ant task
>> already for that (thanks to Erwan IIRW)
>>
>> Jacques
>>
>> From: "Pierre Smits" <pi...@gmail.com>
>>
>>  Hi Erwan,
>>>
>>> I think there might be an issue here regarding mysql. As licence is not
>>> compatible/usable with ASF 2.0 we cannot include the mySQL jar by default.
>>>
>>> But if we want to do an automated reporting on OFBiz, trunk pulled from
>>> svn, to sonar on mysql then the driver is needed. And manually pulling and
>>> placing it in the correct folder on an automated process is very
>>> cumbersome.
>>>
>>> I will submit a patch that will enable the user to do a download and
>>> install with ivy, like the postgresql target. Does that fit our needs and
>>> solve licence issue?
>>>
>>> Regards,
>>>
>>> Pierre
>>>
>>> Op 10 april 2012 16:20 schreef Pierre Smits <pi...@gmail.com> het
>>> volgende:
>>>
>>>  Hi Erwan,
>>>>
>>>> I guess that the same would then be applicable for:
>>>>
>>>> <property key="sonar.host.url" value="${sonar.host.url}" />
>>>>
>>>> Regards,
>>>>
>>>> Pierre
>>>>
>>>>
>>>>
>>>>
>>>> Op 10 april 2012 16:09 schreef Erwan de FERRIERES <
>>>> erwan.deferrieres@gmail.com> het volgende:
>>>>
>>>> >
>>>>
>>>>> > I am trying to set this up and I have following questions:
>>>>> >
>>>>> I never used it with another DB than derby...
>>>>> >   1. Should the mySQL driver be in framework/entity/lib/jdbc folder?
>>>>> can't answer but I'll make some tests
>>>>>
>>>>> >   2. My mySQL db for sonar is on a different server (not localhost).
>>>>> Must
>>>>> >   I adjust build.xml or pass it as a parameter?
>>>>> I'll change the parameter this way tonight: <property
>>>>> name="sonar.jdbc.url" value="${sonar.jdbc.url}"/>
>>>>>
>>>>> >   3. Am I correct to understand that both ${sonar.jdbc.username}
>>>>> >   and ${sonar.jdbc.password} are to be passed as parameters when
>>>>> triggering
>>>>> >   the target, or are they supposed to be set in build.xml?
>>>>> parameters
>>>>> >
>>>>> parameters when the job is triggered.
>>>>>
>>>>> Cheers,
>>>>>
>>>>>
>>>>>
>>>>> --
>>>>> Erwan de FERRIERES
>>>>>
>>>>>
>>>>
>>>>
>>>



-- 
Erwan de FERRIERES

Re: Building with Jenkins - cobertura and sonar

Posted by Pierre Smits <pi...@gmail.com>.
Done!

Op 10 april 2012 18:36 schreef Jacques Le Roux <jacques.le.roux@les7arts.com
> het volgende:

> From: "Pierre Smits" <pi...@gmail.com>
>
>> Hi Jacques,
>>
>>
>> Postgresql is also my preferred choice of db, but OFBiz delivers on the
>> opportunity of using mySQL as a db platform. Using a download and install
>> mechanism as we have for Postgresql and other plugins (Cobertura, Sonar)
>> would help our endusers in their adoption of OFBiz, in stead of letting
>> them look for the appropriate driver, downloading and installing it
>> manually in the right place of OFBiz.
>>
>> I am just concerned about the legal (licence) implications of such a
>> functionality.
>>
>
> Then simply follow the ant download-PG-JDBC way (MySql being GPL)
>
> Jacques
>
>
>  Regards,
>>
>> Pierre
>>
>> Op 10 april 2012 17:33 schreef Jacques Le Roux <
>> jacques.le.roux@les7arts.com
>>
>>> het volgende:
>>>
>>
>>  Maybe out of subject, but I'd prefer Postgres and we have an ant task
>>> already for that (thanks to Erwan IIRW)
>>>
>>> Jacques
>>>
>>> From: "Pierre Smits" <pi...@gmail.com>
>>>
>>>  Hi Erwan,
>>>
>>>>
>>>> I think there might be an issue here regarding mysql. As licence is not
>>>> compatible/usable with ASF 2.0 we cannot include the mySQL jar by
>>>> default.
>>>>
>>>> But if we want to do an automated reporting on OFBiz, trunk pulled from
>>>> svn, to sonar on mysql then the driver is needed. And manually pulling
>>>> and
>>>> placing it in the correct folder on an automated process is very
>>>> cumbersome.
>>>>
>>>> I will submit a patch that will enable the user to do a download and
>>>> install with ivy, like the postgresql target. Does that fit our needs
>>>> and
>>>> solve licence issue?
>>>>
>>>> Regards,
>>>>
>>>> Pierre
>>>>
>>>> Op 10 april 2012 16:20 schreef Pierre Smits <pi...@gmail.com>
>>>> het
>>>> volgende:
>>>>
>>>>  Hi Erwan,
>>>>
>>>>>
>>>>> I guess that the same would then be applicable for:
>>>>>
>>>>> <property key="sonar.host.url" value="${sonar.host.url}" />
>>>>>
>>>>> Regards,
>>>>>
>>>>> Pierre
>>>>>
>>>>>
>>>>>
>>>>>
>>>>> Op 10 april 2012 16:09 schreef Erwan de FERRIERES <
>>>>> erwan.deferrieres@gmail.com> het volgende:
>>>>>
>>>>> >
>>>>>
>>>>>  > I am trying to set this up and I have following questions:
>>>>>> >
>>>>>> I never used it with another DB than derby...
>>>>>> >   1. Should the mySQL driver be in framework/entity/lib/jdbc folder?
>>>>>> can't answer but I'll make some tests
>>>>>>
>>>>>> >   2. My mySQL db for sonar is on a different server (not localhost).
>>>>>> Must
>>>>>> >   I adjust build.xml or pass it as a parameter?
>>>>>> I'll change the parameter this way tonight: <property
>>>>>> name="sonar.jdbc.url" value="${sonar.jdbc.url}"/>
>>>>>>
>>>>>> >   3. Am I correct to understand that both ${sonar.jdbc.username}
>>>>>> >   and ${sonar.jdbc.password} are to be passed as parameters when
>>>>>> triggering
>>>>>> >   the target, or are they supposed to be set in build.xml?
>>>>>> parameters
>>>>>> >
>>>>>> parameters when the job is triggered.
>>>>>>
>>>>>> Cheers,
>>>>>>
>>>>>>
>>>>>>
>>>>>> --
>>>>>> Erwan de FERRIERES
>>>>>>
>>>>>>
>>>>>>
>>>>>
>>>>>
>>>>
>>

Re: Building with Jenkins - cobertura and sonar

Posted by Jacques Le Roux <ja...@les7arts.com>.
From: "Pierre Smits" <pi...@gmail.com>
> Hi Jacques,
> 
> Postgresql is also my preferred choice of db, but OFBiz delivers on the
> opportunity of using mySQL as a db platform. Using a download and install
> mechanism as we have for Postgresql and other plugins (Cobertura, Sonar)
> would help our endusers in their adoption of OFBiz, in stead of letting
> them look for the appropriate driver, downloading and installing it
> manually in the right place of OFBiz.
> 
> I am just concerned about the legal (licence) implications of such a
> functionality.

Then simply follow the ant download-PG-JDBC way (MySql being GPL)

Jacques
 
> Regards,
> 
> Pierre
> 
> Op 10 april 2012 17:33 schreef Jacques Le Roux <jacques.le.roux@les7arts.com
>> het volgende:
> 
>> Maybe out of subject, but I'd prefer Postgres and we have an ant task
>> already for that (thanks to Erwan IIRW)
>>
>> Jacques
>>
>> From: "Pierre Smits" <pi...@gmail.com>
>>
>>  Hi Erwan,
>>>
>>> I think there might be an issue here regarding mysql. As licence is not
>>> compatible/usable with ASF 2.0 we cannot include the mySQL jar by default.
>>>
>>> But if we want to do an automated reporting on OFBiz, trunk pulled from
>>> svn, to sonar on mysql then the driver is needed. And manually pulling and
>>> placing it in the correct folder on an automated process is very
>>> cumbersome.
>>>
>>> I will submit a patch that will enable the user to do a download and
>>> install with ivy, like the postgresql target. Does that fit our needs and
>>> solve licence issue?
>>>
>>> Regards,
>>>
>>> Pierre
>>>
>>> Op 10 april 2012 16:20 schreef Pierre Smits <pi...@gmail.com> het
>>> volgende:
>>>
>>>  Hi Erwan,
>>>>
>>>> I guess that the same would then be applicable for:
>>>>
>>>> <property key="sonar.host.url" value="${sonar.host.url}" />
>>>>
>>>> Regards,
>>>>
>>>> Pierre
>>>>
>>>>
>>>>
>>>>
>>>> Op 10 april 2012 16:09 schreef Erwan de FERRIERES <
>>>> erwan.deferrieres@gmail.com> het volgende:
>>>>
>>>> >
>>>>
>>>>> > I am trying to set this up and I have following questions:
>>>>> >
>>>>> I never used it with another DB than derby...
>>>>> >   1. Should the mySQL driver be in framework/entity/lib/jdbc folder?
>>>>> can't answer but I'll make some tests
>>>>>
>>>>> >   2. My mySQL db for sonar is on a different server (not localhost).
>>>>> Must
>>>>> >   I adjust build.xml or pass it as a parameter?
>>>>> I'll change the parameter this way tonight: <property
>>>>> name="sonar.jdbc.url" value="${sonar.jdbc.url}"/>
>>>>>
>>>>> >   3. Am I correct to understand that both ${sonar.jdbc.username}
>>>>> >   and ${sonar.jdbc.password} are to be passed as parameters when
>>>>> triggering
>>>>> >   the target, or are they supposed to be set in build.xml?
>>>>> parameters
>>>>> >
>>>>> parameters when the job is triggered.
>>>>>
>>>>> Cheers,
>>>>>
>>>>>
>>>>>
>>>>> --
>>>>> Erwan de FERRIERES
>>>>>
>>>>>
>>>>
>>>>
>>>
>

Re: Building with Jenkins - cobertura and sonar

Posted by Pierre Smits <pi...@gmail.com>.
Hi Jacques,

Postgresql is also my preferred choice of db, but OFBiz delivers on the
opportunity of using mySQL as a db platform. Using a download and install
mechanism as we have for Postgresql and other plugins (Cobertura, Sonar)
would help our endusers in their adoption of OFBiz, in stead of letting
them look for the appropriate driver, downloading and installing it
manually in the right place of OFBiz.

I am just concerned about the legal (licence) implications of such a
functionality.

Regards,

Pierre

Op 10 april 2012 17:33 schreef Jacques Le Roux <jacques.le.roux@les7arts.com
> het volgende:

> Maybe out of subject, but I'd prefer Postgres and we have an ant task
> already for that (thanks to Erwan IIRW)
>
> Jacques
>
> From: "Pierre Smits" <pi...@gmail.com>
>
>  Hi Erwan,
>>
>> I think there might be an issue here regarding mysql. As licence is not
>> compatible/usable with ASF 2.0 we cannot include the mySQL jar by default.
>>
>> But if we want to do an automated reporting on OFBiz, trunk pulled from
>> svn, to sonar on mysql then the driver is needed. And manually pulling and
>> placing it in the correct folder on an automated process is very
>> cumbersome.
>>
>> I will submit a patch that will enable the user to do a download and
>> install with ivy, like the postgresql target. Does that fit our needs and
>> solve licence issue?
>>
>> Regards,
>>
>> Pierre
>>
>> Op 10 april 2012 16:20 schreef Pierre Smits <pi...@gmail.com> het
>> volgende:
>>
>>  Hi Erwan,
>>>
>>> I guess that the same would then be applicable for:
>>>
>>> <property key="sonar.host.url" value="${sonar.host.url}" />
>>>
>>> Regards,
>>>
>>> Pierre
>>>
>>>
>>>
>>>
>>> Op 10 april 2012 16:09 schreef Erwan de FERRIERES <
>>> erwan.deferrieres@gmail.com> het volgende:
>>>
>>> >
>>>
>>>> > I am trying to set this up and I have following questions:
>>>> >
>>>> I never used it with another DB than derby...
>>>> >   1. Should the mySQL driver be in framework/entity/lib/jdbc folder?
>>>> can't answer but I'll make some tests
>>>>
>>>> >   2. My mySQL db for sonar is on a different server (not localhost).
>>>> Must
>>>> >   I adjust build.xml or pass it as a parameter?
>>>> I'll change the parameter this way tonight: <property
>>>> name="sonar.jdbc.url" value="${sonar.jdbc.url}"/>
>>>>
>>>> >   3. Am I correct to understand that both ${sonar.jdbc.username}
>>>> >   and ${sonar.jdbc.password} are to be passed as parameters when
>>>> triggering
>>>> >   the target, or are they supposed to be set in build.xml?
>>>> parameters
>>>> >
>>>> parameters when the job is triggered.
>>>>
>>>> Cheers,
>>>>
>>>>
>>>>
>>>> --
>>>> Erwan de FERRIERES
>>>>
>>>>
>>>
>>>
>>

Re: Building with Jenkins - cobertura and sonar

Posted by Jacques Le Roux <ja...@les7arts.com>.
Maybe out of subject, but I'd prefer Postgres and we have an ant task already for that (thanks to Erwan IIRW)

Jacques

From: "Pierre Smits" <pi...@gmail.com>
> Hi Erwan,
> 
> I think there might be an issue here regarding mysql. As licence is not
> compatible/usable with ASF 2.0 we cannot include the mySQL jar by default.
> 
> But if we want to do an automated reporting on OFBiz, trunk pulled from
> svn, to sonar on mysql then the driver is needed. And manually pulling and
> placing it in the correct folder on an automated process is very cumbersome.
> 
> I will submit a patch that will enable the user to do a download and
> install with ivy, like the postgresql target. Does that fit our needs and
> solve licence issue?
> 
> Regards,
> 
> Pierre
> 
> Op 10 april 2012 16:20 schreef Pierre Smits <pi...@gmail.com> het
> volgende:
> 
>> Hi Erwan,
>>
>> I guess that the same would then be applicable for:
>>
>> <property key="sonar.host.url" value="${sonar.host.url}" />
>>
>> Regards,
>>
>> Pierre
>>
>>
>>
>>
>> Op 10 april 2012 16:09 schreef Erwan de FERRIERES <
>> erwan.deferrieres@gmail.com> het volgende:
>>
>> >
>>> > I am trying to set this up and I have following questions:
>>> >
>>> I never used it with another DB than derby...
>>> >   1. Should the mySQL driver be in framework/entity/lib/jdbc folder?
>>> can't answer but I'll make some tests
>>>
>>> >   2. My mySQL db for sonar is on a different server (not localhost).
>>> Must
>>> >   I adjust build.xml or pass it as a parameter?
>>> I'll change the parameter this way tonight: <property
>>> name="sonar.jdbc.url" value="${sonar.jdbc.url}"/>
>>>
>>> >   3. Am I correct to understand that both ${sonar.jdbc.username}
>>> >   and ${sonar.jdbc.password} are to be passed as parameters when
>>> triggering
>>> >   the target, or are they supposed to be set in build.xml?
>>> parameters
>>> >
>>> parameters when the job is triggered.
>>>
>>> Cheers,
>>>
>>>
>>>
>>> --
>>> Erwan de FERRIERES
>>>
>>
>>
>

Re: Building with Jenkins - cobertura and sonar

Posted by Erwan de FERRIERES <er...@gmail.com>.
2012/4/10 Pierre Smits <pi...@gmail.com>:
> Hi Erwan,
>
> I think there might be an issue here regarding mysql. As licence is not
> compatible/usable with ASF 2.0 we cannot include the mySQL jar by default.
>
> But if we want to do an automated reporting on OFBiz, trunk pulled from
> svn, to sonar on mysql then the driver is needed. And manually pulling and
> placing it in the correct folder on an automated process is very cumbersome.
>
> I will submit a patch that will enable the user to do a download and
> install with ivy, like the postgresql target. Does that fit our needs and
> solve licence issue?

>From http://docs.codehaus.org/display/SONAR/Install+Sonar, there is no
need to add a driver.
But it needs to be tested before, just to be sure.
I think sonar is embedding the mysql driver, but I can't verify now

>
> Regards,
>
> Pierre
>
> Op 10 april 2012 16:20 schreef Pierre Smits <pi...@gmail.com> het
> volgende:
>
>> Hi Erwan,
>>
>> I guess that the same would then be applicable for:
>>
>> <property key="sonar.host.url" value="${sonar.host.url}" />
>>
>> Regards,
>>
>> Pierre
>>
>>
>>
>>
>> Op 10 april 2012 16:09 schreef Erwan de FERRIERES <
>> erwan.deferrieres@gmail.com> het volgende:
>>
>> >
>>> > I am trying to set this up and I have following questions:
>>> >
>>> I never used it with another DB than derby...
>>> >   1. Should the mySQL driver be in framework/entity/lib/jdbc folder?
>>> can't answer but I'll make some tests
>>>
>>> >   2. My mySQL db for sonar is on a different server (not localhost).
>>> Must
>>> >   I adjust build.xml or pass it as a parameter?
>>> I'll change the parameter this way tonight: <property
>>> name="sonar.jdbc.url" value="${sonar.jdbc.url}"/>
>>>
>>> >   3. Am I correct to understand that both ${sonar.jdbc.username}
>>> >   and ${sonar.jdbc.password} are to be passed as parameters when
>>> triggering
>>> >   the target, or are they supposed to be set in build.xml?
>>> parameters
>>> >
>>> parameters when the job is triggered.
>>>
>>> Cheers,
>>>
>>>
>>>
>>> --
>>> Erwan de FERRIERES
>>>
>>
>>



-- 
Erwan de FERRIERES

Re: Building with Jenkins - cobertura and sonar

Posted by Pierre Smits <pi...@gmail.com>.
Hi Erwan,

I think there might be an issue here regarding mysql. As licence is not
compatible/usable with ASF 2.0 we cannot include the mySQL jar by default.

But if we want to do an automated reporting on OFBiz, trunk pulled from
svn, to sonar on mysql then the driver is needed. And manually pulling and
placing it in the correct folder on an automated process is very cumbersome.

I will submit a patch that will enable the user to do a download and
install with ivy, like the postgresql target. Does that fit our needs and
solve licence issue?

Regards,

Pierre

Op 10 april 2012 16:20 schreef Pierre Smits <pi...@gmail.com> het
volgende:

> Hi Erwan,
>
> I guess that the same would then be applicable for:
>
> <property key="sonar.host.url" value="${sonar.host.url}" />
>
> Regards,
>
> Pierre
>
>
>
>
> Op 10 april 2012 16:09 schreef Erwan de FERRIERES <
> erwan.deferrieres@gmail.com> het volgende:
>
> >
>> > I am trying to set this up and I have following questions:
>> >
>> I never used it with another DB than derby...
>> >   1. Should the mySQL driver be in framework/entity/lib/jdbc folder?
>> can't answer but I'll make some tests
>>
>> >   2. My mySQL db for sonar is on a different server (not localhost).
>> Must
>> >   I adjust build.xml or pass it as a parameter?
>> I'll change the parameter this way tonight: <property
>> name="sonar.jdbc.url" value="${sonar.jdbc.url}"/>
>>
>> >   3. Am I correct to understand that both ${sonar.jdbc.username}
>> >   and ${sonar.jdbc.password} are to be passed as parameters when
>> triggering
>> >   the target, or are they supposed to be set in build.xml?
>> parameters
>> >
>> parameters when the job is triggered.
>>
>> Cheers,
>>
>>
>>
>> --
>> Erwan de FERRIERES
>>
>
>

Re: Building with Jenkins - cobertura and sonar

Posted by Pierre Smits <pi...@gmail.com>.
Hi Erwan,

I guess that the same would then be applicable for:

<property key="sonar.host.url" value="${sonar.host.url}" />

Regards,

Pierre




Op 10 april 2012 16:09 schreef Erwan de FERRIERES <
erwan.deferrieres@gmail.com> het volgende:

> >
> > I am trying to set this up and I have following questions:
> >
> I never used it with another DB than derby...
> >   1. Should the mySQL driver be in framework/entity/lib/jdbc folder?
> can't answer but I'll make some tests
>
> >   2. My mySQL db for sonar is on a different server (not localhost). Must
> >   I adjust build.xml or pass it as a parameter?
> I'll change the parameter this way tonight: <property
> name="sonar.jdbc.url" value="${sonar.jdbc.url}"/>
>
> >   3. Am I correct to understand that both ${sonar.jdbc.username}
> >   and ${sonar.jdbc.password} are to be passed as parameters when
> triggering
> >   the target, or are they supposed to be set in build.xml?
> parameters
> >
> parameters when the job is triggered.
>
> Cheers,
>
>
>
> --
> Erwan de FERRIERES
>

Re: Building with Jenkins - cobertura and sonar

Posted by Erwan de FERRIERES <er...@gmail.com>.
>
> I am trying to set this up and I have following questions:
>
I never used it with another DB than derby...
>   1. Should the mySQL driver be in framework/entity/lib/jdbc folder?
can't answer but I'll make some tests

>   2. My mySQL db for sonar is on a different server (not localhost). Must
>   I adjust build.xml or pass it as a parameter?
I'll change the parameter this way tonight: <property
name="sonar.jdbc.url" value="${sonar.jdbc.url}"/>

>   3. Am I correct to understand that both ${sonar.jdbc.username}
>   and ${sonar.jdbc.password} are to be passed as parameters when triggering
>   the target, or are they supposed to be set in build.xml?
parameters
>
parameters when the job is triggered.

Cheers,



-- 
Erwan de FERRIERES