You are viewing a plain text version of this content. The canonical link for it is here.
Posted to dev@empire-db.apache.org by Rainer Döbele <do...@esteam.de> on 2009/02/13 16:13:19 UTC

using Maven

Hi Franics,

Being a Maven newbe I wonder whether you could give me some advice on how to use it.

I have both Maven and the Maven Eclipse Plugin installed but unlike Jörg I don't have the Option to "Check out as Maven project" within the SVN Repository View (for some reason).

Now if I check out the entire maven branch into my workspace and call "mvn eclipse:eclipse" it reports "build successful".

However in the Package Explorer I only have the maven node with its subnodes but none of them is marked as a project. Thus I cannot compile or run anything. I also have a bin and a target folder but there's not much in there.

If I only check out an example project (e.g. the empire-db-example) and call mvn eclipse:eclipse I get the following error:
org.apache.maven.reactor.MavenExecutionException: Cannot find parent: org.apache
.empire-db:empire-db-examples for project: org.apache.empire-db:empire-db-exampl
e:jar:2.0.5-SNAPSHOT for project org.apache.empire-db:empire-db-example:jar:2.0.
5-SNAPSHOT

So what is the recommended way for checking the files out and running the examples?

Rainer

> -----Ursprüngliche Nachricht-----
> Von: Francis De Brabandere [mailto:francisdb@gmail.com]
> Gesendet: Donnerstag, 12. Februar 2009 23:09
> An: empire-db-dev@incubator.apache.org
> Betreff: Re: mavenized project
> 
> well depends on what the release dist should look like, it won't be
> the same as before
> 
> On Tue, Feb 10, 2009 at 9:43 PM, Rainer Döbele <do...@esteam.de> wrote:
> > Sounds good.
> > Thanks for your evalation Jörg.
> > And even more for your work Francis.
> >
> > So before we merge the maven branch with the trunk is there anything
> else to consider?
> > If not I would call for a vote to merge the branches.
> >
> > Regards
> > Rainer
> >
> >
> > Jörg Reiher wrote:
> >> re: mavenized project
> >>
> >> Hi,
> >> I used m2e (just found out it wasn't even the latest release but 0.96
> (September 2008))
> >> I haven't done a big evaluation of the available tools when I installed
> it, just wanted to > know if there is any working plugin, cause when I
> worked at a company where Maven was used > (about 1.5 years ago) it was a
> big pain to keep
> >> Eclipse project and Maven in synch... always switching between console
> and Eclipse, refreshing > the project; now it seems to be much much better
> - m2e did what I expected, so I didn't bother > trying other plugins.
> >>
> >> Greets
> >> jorg
> >>
> >
> 
> 
> 
> --
> http://www.somatik.be
> Microsoft gives you windows, Linux gives you the whole house.

Re: [VOTE] Merge SVN Maven branch with trunk

Posted by Francis De Brabandere <fr...@gmail.com>.
+1 (am I allowed to vote?)

On Sun, Feb 15, 2009 at 10:43 PM, Rainer Döbele <do...@esteam.de> wrote:
> Hi everyone
>
> Through the great work of Francis we now have reorganized the project in a Maven style project structure. However all modifications have been made on a branch which we not intend to merge with the trunk.
>
> Please let us know within the usual 72 hours whether you agree with this transaction.
>
> here is my +1
>
> Rainer
>



-- 
http://www.somatik.be
Microsoft gives you windows, Linux gives you the whole house.

re: again Maven

Posted by Rainer Döbele <do...@esteam.de>.
Hi Francis

Don't worry. I don't think there are many (if any) changes in the trunk that aren't already in the maven branch.
I am waiting with some of my changes until the branches have been merged.
New features will be added later on.

We need to check what's different of course, but I don't see many problems.
The problems will come when we decide to make an official release, since this has to be accepted by the mentors and the incubator PMC. They will particularly take a close look on all the legal issues such as Apache disclaimers in all files etc.

Francis De Brabandere wrote:
> Re: again Maven
> 
> do you have a lot of changes? as I don't see me doing a real merge but
> just moving stuff around in trunk the same way they are in the branch
> + copying over the extra pom files, unit tests and stuff
> 
> On Sun, Feb 15, 2009 at 10:36 PM, Rainer Döbele <do...@esteam.de>
> wrote:
> > Hi Francis,
> >
> > What? You're working on other projects? Shame on you! :-)
> >
> > Since the sources of hsqldb 1.8.0.7 don't seem to be avaiable
> anywhere I will probably to with 1.8.0.1.
> >
> > We should go ahead merging the branches now, then I can to my
> modifications on the trunk again.
> >
> > Although I am not sure whether we have to, I will do it the Apache
> way and call for a vote.
> >
> > Regards,
> > Rainer
> >
> >
> > Francis De Brabandere wrote:
> >> Re: again Maven
> >>
> >> On Sun, Feb 15, 2009 at 10:00 PM, Rainer Döbele <do...@esteam.de>
> wrote:
> >> > Hi Francis,
> >> >
> >> > first of all I am astonished that you always reply within minutes.
> >> > I hope that sitting in front of your computer answering my
> (stupid) questions is not your only activity in > life.
> >> > If so, let me tell you that there is more to life than computers
> and that you should sometimes really go out > and have a beer or two :-
> )
> >>
> >> hehe, I've had my part of beer drinking this weekend :-) don't worry
> >> it's just that I'm working on an other project of mine and I happen
> to
> >> be at my desk right now...
> >>
> >> >
> >> > Back to business.
> >> > 1. The MANIFEST.MF does not seem to get recreated, so forget about
> it for now.
> >> > 2. IMO the config.xml should always be in the file system. It
> makes no sense to hide it inside a jar. I > think even logically it
> belongs exactly where the readme.txt and the tutorial.pdf belong. And
> there is no doubt > that we must be able to debug the app without
> fiddling around with program arguments. And besides that I > always
> plead for "comfort over convention".
> >>
> >> well I understand your view on the subject. I'll put it in the
> module
> >> root when we move to maven layout
> >>
> >> > 3. Thanks for the mvnrepository link. I tried so hard but could
> not find it on the Maven site > (http://maven.apache.org). Strange
> isn't it?
> >> >
> >>
> >> there are other sites to find artifacts but that one is best, it
> tends
> >> to go down from time to time though
> >>
> >> > One more question for you though.
> >> > I want to debug the HSQLDB JDBC driver code.
> >> > So in Eclipse I opened the "Maven dependencies" node, right-
> clicked on hsqldb-1.8.0.7 and picked Maven-> >Download sources.
> >> > Unfortunately nothing happened (not even an error message).
> >> > How can I obtain the sources for HSQLDB-1.8.0.7?
> >>
> >> not all artifacts have sources/javadoc available in the central
> repo,
> >> you can just download them from the site of the project and attach
> >> them to the lib as you do normally in eclipse
> >>
> >> or you can browse the repo and look for a version that has sources
> >> like this one:
> >> http://mirrors.ibiblio.org/pub/mirrors/maven2/hsqldb/hsqldb/1.8.0.1/
> >>
> >> >
> >> > Regards,
> >> > Rainer
> >> >
> >
> 
> 
> 
> --
> http://www.somatik.be
> Microsoft gives you windows, Linux gives you the whole house.

Re: again Maven

Posted by Francis De Brabandere <fr...@gmail.com>.
do you have a lot of changes? as I don't see me doing a real merge but
just moving stuff around in trunk the same way they are in the branch
+ copying over the extra pom files, unit tests and stuff

On Sun, Feb 15, 2009 at 10:36 PM, Rainer Döbele <do...@esteam.de> wrote:
> Hi Francis,
>
> What? You're working on other projects? Shame on you! :-)
>
> Since the sources of hsqldb 1.8.0.7 don't seem to be avaiable anywhere I will probably to with 1.8.0.1.
>
> We should go ahead merging the branches now, then I can to my modifications on the trunk again.
>
> Although I am not sure whether we have to, I will do it the Apache way and call for a vote.
>
> Regards,
> Rainer
>
>
> Francis De Brabandere wrote:
>> Re: again Maven
>>
>> On Sun, Feb 15, 2009 at 10:00 PM, Rainer Döbele <do...@esteam.de> wrote:
>> > Hi Francis,
>> >
>> > first of all I am astonished that you always reply within minutes.
>> > I hope that sitting in front of your computer answering my (stupid) questions is not your only activity in > life.
>> > If so, let me tell you that there is more to life than computers and that you should sometimes really go out > and have a beer or two :-)
>>
>> hehe, I've had my part of beer drinking this weekend :-) don't worry
>> it's just that I'm working on an other project of mine and I happen to
>> be at my desk right now...
>>
>> >
>> > Back to business.
>> > 1. The MANIFEST.MF does not seem to get recreated, so forget about it for now.
>> > 2. IMO the config.xml should always be in the file system. It makes no sense to hide it inside a jar. I > think even logically it belongs exactly where the readme.txt and the tutorial.pdf belong. And there is no doubt > that we must be able to debug the app without fiddling around with program arguments. And besides that I > always plead for "comfort over convention".
>>
>> well I understand your view on the subject. I'll put it in the module
>> root when we move to maven layout
>>
>> > 3. Thanks for the mvnrepository link. I tried so hard but could not find it on the Maven site > (http://maven.apache.org). Strange isn't it?
>> >
>>
>> there are other sites to find artifacts but that one is best, it tends
>> to go down from time to time though
>>
>> > One more question for you though.
>> > I want to debug the HSQLDB JDBC driver code.
>> > So in Eclipse I opened the "Maven dependencies" node, right-clicked on hsqldb-1.8.0.7 and picked Maven-> >Download sources.
>> > Unfortunately nothing happened (not even an error message).
>> > How can I obtain the sources for HSQLDB-1.8.0.7?
>>
>> not all artifacts have sources/javadoc available in the central repo,
>> you can just download them from the site of the project and attach
>> them to the lib as you do normally in eclipse
>>
>> or you can browse the repo and look for a version that has sources
>> like this one:
>> http://mirrors.ibiblio.org/pub/mirrors/maven2/hsqldb/hsqldb/1.8.0.1/
>>
>> >
>> > Regards,
>> > Rainer
>> >
>



-- 
http://www.somatik.be
Microsoft gives you windows, Linux gives you the whole house.

Re: [VOTE] Merge SVN Maven branch with trunk

Posted by Henning Schmiedehausen <he...@apache.org>.
Just to make things clear: This is a vote about a development issue, so
it should be run on the dev list, no need to cc private.

I have to admit that I don't understand the vote subject. Should that be
"... which we *NOW* intend to merge..." ?

	Ciao
		Henning


On Sun, 2009-02-15 at 22:43 +0100, Rainer Döbele wrote:
> Hi everyone
> 
> Through the great work of Francis we now have reorganized the project in a Maven style project structure. However all modifications have been made on a branch which we not intend to merge with the trunk.
> 
> Please let us know within the usual 72 hours whether you agree with this transaction.
> 
> here is my +1
> 
> Rainer


[VOTE] [RESULT] Merge SVN Maven branch with trunk

Posted by Rainer Döbele <do...@esteam.de>.
Hello everyone,

The [VOTE] is now closed. The [VOTE] to merge SVN Maven branch with trunk is successful.

There are two +1 votes, no 0 or -1.
Since lazy consensus applies, the transaction has been approved.

Rainer


Re: [VOTE] Merge SVN Maven branch with trunk

Posted by Francis De Brabandere <fr...@gmail.com>.
shall we conclude this vote?

On Mon, Feb 16, 2009 at 3:11 PM, Thomas Fischer <fi...@seitenbau.net> wrote:
>> Furthermore my intention was that lazy consensus applies i.e. if
>> there are no objections within 72 hours we will perform the change.
>> Do I have to point that our more clearly?
>
> IMHO it makes sense to state it clearly if one intends lazy consensus. It
> does not hurt and avoids uncertainty.
>
>   Thomas



-- 
http://www.somatik.be
Microsoft gives you windows, Linux gives you the whole house.

RE: [VOTE] Merge SVN Maven branch with trunk

Posted by Thomas Fischer <fi...@seitenbau.net>.
> Furthermore my intention was that lazy consensus applies i.e. if 
> there are no objections within 72 hours we will perform the change. 
> Do I have to point that our more clearly?

IMHO it makes sense to state it clearly if one intends lazy consensus. It 
does not hurt and avoids uncertainty.

   Thomas

Fwd: [VOTE] Merge SVN Maven branch with trunk

Posted by Rainer Döbele <do...@esteam.de>.
Hello everybody,
 
first I have to apologize for this very bad typo that you hopefully all recognized:
Instead of "... which we not intend to merge"
it should be "... which we now intend to merge".
Shame on me - this is a really nasty one.
 
Although it is (only) a dev issue I posted it on the private list too - just to make sure everyone is informed. I thought this would be a good idea. Sorry for that Henning.

Furthermore my intention was that lazy consensus applies i.e. if there are no objections within 72 hours we will perform the change. Do I have to point that our more clearly?

And yes Francis, you are allowed to vote.

Regards
Rainer
 
> Hi everyone
> 
> Through the great work of Francis we now have reorganized the project in a Maven style project structure. However all > modifications have been made on a branch which we not intend to merge with the trunk.
> 
> Please let us know within the usual 72 hours whether you agree with this transaction.
> 
> here is my +1
> 
> Rainer

[VOTE] Merge SVN Maven branch with trunk

Posted by Rainer Döbele <do...@esteam.de>.
Hi everyone

Through the great work of Francis we now have reorganized the project in a Maven style project structure. However all modifications have been made on a branch which we not intend to merge with the trunk.

Please let us know within the usual 72 hours whether you agree with this transaction.

here is my +1

Rainer

Voting on important changes [was: Re: again Maven]

Posted by Thomas Fischer <fi...@seitenbau.net>.
> We should go ahead merging the branches now, then I can to my 
> modifications on the trunk again.
> 
> Although I am not sure whether we have to, I will do it the Apache way 
and call for a vote.

>From my personal understanding, voting on this is no must but I'd consider 
it bad style if one incorporates important changes without announcing them 
beforehand. 
Personally, I prefer lazy consensus, e.g. like "I intend to merge the XXX 
branch with the trunk, please object within 72 hours if you see any 
problems", but this might be personal style and depends also on the size 
and style of the community.

 Regards,

          Thomas

re: again Maven

Posted by Rainer Döbele <do...@esteam.de>.
Hi Francis,

What? You're working on other projects? Shame on you! :-)

Since the sources of hsqldb 1.8.0.7 don't seem to be avaiable anywhere I will probably to with 1.8.0.1.

We should go ahead merging the branches now, then I can to my modifications on the trunk again.

Although I am not sure whether we have to, I will do it the Apache way and call for a vote.

Regards,
Rainer


Francis De Brabandere wrote:
> Re: again Maven
>  
> On Sun, Feb 15, 2009 at 10:00 PM, Rainer Döbele <do...@esteam.de> wrote:
> > Hi Francis,
> >
> > first of all I am astonished that you always reply within minutes.
> > I hope that sitting in front of your computer answering my (stupid) questions is not your only activity in > life.
> > If so, let me tell you that there is more to life than computers and that you should sometimes really go out > and have a beer or two :-)
> 
> hehe, I've had my part of beer drinking this weekend :-) don't worry
> it's just that I'm working on an other project of mine and I happen to
> be at my desk right now...
> 
> >
> > Back to business.
> > 1. The MANIFEST.MF does not seem to get recreated, so forget about it for now.
> > 2. IMO the config.xml should always be in the file system. It makes no sense to hide it inside a jar. I > think even logically it belongs exactly where the readme.txt and the tutorial.pdf belong. And there is no doubt > that we must be able to debug the app without fiddling around with program arguments. And besides that I > always plead for "comfort over convention".
> 
> well I understand your view on the subject. I'll put it in the module
> root when we move to maven layout
> 
> > 3. Thanks for the mvnrepository link. I tried so hard but could not find it on the Maven site > (http://maven.apache.org). Strange isn't it?
> >
> 
> there are other sites to find artifacts but that one is best, it tends
> to go down from time to time though
> 
> > One more question for you though.
> > I want to debug the HSQLDB JDBC driver code.
> > So in Eclipse I opened the "Maven dependencies" node, right-clicked on hsqldb-1.8.0.7 and picked Maven-> >Download sources.
> > Unfortunately nothing happened (not even an error message).
> > How can I obtain the sources for HSQLDB-1.8.0.7?
> 
> not all artifacts have sources/javadoc available in the central repo,
> you can just download them from the site of the project and attach
> them to the lib as you do normally in eclipse
> 
> or you can browse the repo and look for a version that has sources
> like this one:
> http://mirrors.ibiblio.org/pub/mirrors/maven2/hsqldb/hsqldb/1.8.0.1/
> 
> >
> > Regards,
> > Rainer
> >

Re: again Maven

Posted by Francis De Brabandere <fr...@gmail.com>.
On Sun, Feb 15, 2009 at 10:00 PM, Rainer Döbele <do...@esteam.de> wrote:
> Hi Francis,
>
> first of all I am astonished that you always reply within minutes.
> I hope that sitting in front of your computer answering my (stupid) questions is not your only activity in life.
> If so, let me tell you that there is more to life than computers and that you should sometimes really go out and have a beer or two :-)

hehe, I've had my part of beer drinking this weekend :-) don't worry
it's just that I'm working on an other project of mine and I happen to
be at my desk right now...

>
> Back to business.
> 1. The MANIFEST.MF does not seem to get recreated, so forget about it for now.
> 2. IMO the config.xml should always be in the file system. It makes no sense to hide it inside a jar. I think even logically it belongs exactly where the readme.txt and the tutorial.pdf belong. And there is no doubt that we must be able to debug the app without fiddling around with program arguments. And besides that I always plead for "comfort over convention".

well I understand your view on the subject. I'll put it in the module
root when we move to maven layout

> 3. Thanks for the mvnrepository link. I tried so hard but could not find it on the Maven site (http://maven.apache.org). Strange isn't it?
>

there are other sites to find artifacts but that one is best, it tends
to go down from time to time though

> One more question for you though.
> I want to debug the HSQLDB JDBC driver code.
> So in Eclipse I opened the "Maven dependencies" node, right-clicked on hsqldb-1.8.0.7 and picked Maven->Download sources.
> Unfortunately nothing happened (not even an error message).
> How can I obtain the sources for HSQLDB-1.8.0.7?

not all artifacts have sources/javadoc available in the central repo,
you can just download them from the site of the project and attach
them to the lib as you do normally in eclipse

or you can browse the repo and look for a version that has sources
like this one:
http://mirrors.ibiblio.org/pub/mirrors/maven2/hsqldb/hsqldb/1.8.0.1/

>
> Regards,
> Rainer
>



-- 
http://www.somatik.be
Microsoft gives you windows, Linux gives you the whole house.

again Maven

Posted by Rainer Döbele <do...@esteam.de>.
Hi Francis,

first of all I am astonished that you always reply within minutes. 
I hope that sitting in front of your computer answering my (stupid) questions is not your only activity in life.
If so, let me tell you that there is more to life than computers and that you should sometimes really go out and have a beer or two :-)

Back to business.
1. The MANIFEST.MF does not seem to get recreated, so forget about it for now.
2. IMO the config.xml should always be in the file system. It makes no sense to hide it inside a jar. I think even logically it belongs exactly where the readme.txt and the tutorial.pdf belong. And there is no doubt that we must be able to debug the app without fiddling around with program arguments. And besides that I always plead for "comfort over convention".
3. Thanks for the mvnrepository link. I tried so hard but could not find it on the Maven site (http://maven.apache.org). Strange isn't it?

One more question for you though.
I want to debug the HSQLDB JDBC driver code. 
So in Eclipse I opened the "Maven dependencies" node, right-clicked on hsqldb-1.8.0.7 and picked Maven->Download sources.
Unfortunately nothing happened (not even an error message).
How can I obtain the sources for HSQLDB-1.8.0.7?

Regards,
Rainer

Re: using Maven

Posted by Francis De Brabandere <fr...@gmail.com>.
[inline reply]

On Sun, Feb 15, 2009 at 9:13 PM, Rainer Döbele <do...@esteam.de> wrote:
> Hi Francis,
>
> The MANIFEST.MF is in \empire-db-parent\empire-db\src\main\java\META-INF.
> Don't know what or who's creating it.

I don't see that file, is it being regenerated if you delete it?

>
> About the configuration file:
> When running a project eclipse set's the root path to the project directory.
> This is where we expect to find the config.xml.
> Hence for the empire-db-example the config.xml should be in the \empire-db-parent\empire-db-examples\empire-db-example directory - where the readme.txt or the tutorial.pdf are.
> If there is no good reason aginst it, we should move it from src/main/resources back to the root.
> We can still move it somewhere else in a coming distribution file.

resources belong in the resources folder and should be loaded using
the classloader, it's a minor change in the demo code as there is some
boolean param available to load from the classpath
(the resources folder is merged with the classes in the resulting jar)

I like to keep the project root as clean as possible. (we could add a
etc or conf dir where we expect the file if you really want to load it
from the filesystem)

>
> Finally I am having problems running it with the oracle, sqlserver and mysql databases.
> How can I find out the Maven groupId and artifactId in order to add a dependency for them to the pom?

http://www.mvnrepository.com/

the only driver not available in the public repository is the
sqlserver one. Just add a dependency and a version eg
<dependency>
    <groupId>mssql</groupId>
    <artifactId>mssql-driver</artifactId>
    <version>2005.1</version>
</dependency>

and run mvn clean install, maven will complain about the missing file
and show you how to upload it to your local maven repository
we could add some bat/sh file that does the download and installs the file

>
> (As you can see I am still struggeling, but I am slowly getting familiar with it)

I hope the struggling stops at some point ;-)

Francis

>
> Rainer
>
> Francis De Brabandere wrote:
>> Re: using Maven
>>
>> On Sat, Feb 14, 2009 at 11:44 AM, Rainer Döbele <do...@esteam.de>
>> wrote:
>> > Hi Franics,
>> >
>> > good news. I have finally managed to get the "Checkout as Maven
>> project" in the SVN view.
>> > I had to update all plugins first and then install the subversive
>> integration for M2Eclipse from
>> >
>> http://www.polarion.org/projects/subversive/download/integrations/updat
>> e-site/
>> > (I am using the m2 eclipse plugin)
>>
>> good to hear that
>>
>> >
>> > Using the "Checkout as Maven project" command works really cool and I
>> was able to run the SampleApp.
>> > The two parent projects you mentioned are present and this can be a
>> bit confusing. I'd rather not have them but I can live with it too.
>> > What is still a problem however, is that it for every project (the
>> parent projects as well as the real projects) it wants to add the
>> following files and folders to the SVN Repository:
>> >        .settings
>> > org.eclipse.jdt.core.prefs
>> > org.maven.ide.eclipse.prefs
>> >        src/main/java/META-INF/MANIFEST.MF
>> >        target
>> >        .classpath
>> >        .project
>> > Isn't there a way of automatically adding them to svn.ignore so that
>> after checking everything out no changes are reported from svn? Is this
>> only a problem with the M2Eclipse plugin and what is the behaviour of
>> the q4e plugin you mentioned?
>>
>> I have only been testing the m2eclipse plugin the last two weeks, and
>> I added the ignores for those files manually in my eclipse
>> installation. I don't have any non-eclipse projects that might want to
>> check in those files.
>>
>> I have these ignores:
>> target
>> .project
>> .settings
>> .classpath
>> .svn
>>
>> for the manifest file,where did that come from?
>>
>> never tried the q4e plugin
>>
>> >
>> > The standard eclipse way you described does not really work for me.
>> First when you check out into your workspace, the Import Projects
>> wizard hides the projects below the maven directory since they are
>> already in the workspace. I guess you checked them out to a different
>> location, which is no option for me as I want check out the files
>> directly into my workspace.
>>
>> I'm not using eclipse to check out into my workspace, I do this on the
>> console and I'm not having these problems that way. You need to start
>> with a clean checkout, run the maven eclipse target and then do the
>> import of the 5 projects at once. Once you have a .project in the root
>> (caused by m2eclipse) he won't detect the other projects any more.
>>
>>
>> > Being able to "Checkout as Maven project" from SVN now is a great
>> improvement for me and solves most of my problems. Without the plugin
>> however I find it rather difficult and inconvenient to use. It would be
>> cool though  if we could find a solution for automatically excluding
>> the generated files mentioned above from the version control system.
>> >
>>
>> I don't think there is an automatic way for excluding on import...
>>
>>
>> Francis
>>
>> > Rainer
>> >
>> > Francis De Brabandere wrote:
>> >> Re: using Maven
>> >>
>> >> Rainer,
>> >>
>> >> Are you sure you started with a clean checkout and without using the
>> >> eclipse q4e plugin?
>> >>
>> >> svn checkout https://svn.apache.org/repos/asf/incubator/empire-
>> >> db/branches/maven
>> >> empire-maven-branch
>> >>
>> >> ### standard eclipse way ###
>> >>
>> >> cd empire-maven-branch
>> >> mvn eclipse:eclipse -DdownloadSources=true
>> >> ....
>> >> [INFO] -------------------------------------------------------------
>> ---
>> >> --------
>> >> [INFO] Reactor Summary:
>> >> [INFO] -------------------------------------------------------------
>> ---
>> >> --------
>> >> [INFO] Empire-db Parent ......................................
>> SUCCESS
>> >> [2.243s]
>> >> [INFO] Empire-db .............................................
>> SUCCESS
>> >> [0.533s]
>> >> [INFO] Empire-db Examples ....................................
>> SUCCESS
>> >> [0.006s]
>> >> [INFO] Empire-db Example .....................................
>> SUCCESS
>> >> [5.821s]
>> >> [INFO] Empire-db Advanced Example ............................
>> SUCCESS
>> >> [0.089s]
>> >> [INFO] Empire-db Struts2 Extension ...........................
>> SUCCESS
>> >> [0.767s]
>> >> [INFO] Empire-db Struts2 Example .............................
>> SUCCESS
>> >> [0.354s]
>> >> [INFO] -------------------------------------------------------------
>> ---
>> >> --------
>> >> [INFO] -------------------------------------------------------------
>> ---
>> >> --------
>> >> [INFO] BUILD SUCCESSFUL
>> >> [INFO] -------------------------------------------------------------
>> ---
>> >> --------
>> >> [INFO] Total time: 13 seconds
>> >> [INFO] Finished at: Fri Feb 13 23:46:57 CET 2009
>> >> [INFO] Final Memory: 8M/279M
>> >> [INFO] -------------------------------------------------------------
>> ---
>> >> --------
>> >>
>> >> file - import - existing projects into workspace
>> >>
>> >> select the folder where you checked out the maven branch and click
>> >> finish
>> >> all projects should be imported and ready for use now. (see
>> screenshot)
>> >>
>> >> http://www.somatik.be/files/Screenshot-Import%20.png
>> >>
>> >> ### m2eclipse way ###
>> >> file - import - maven projects
>> >>
>> >> select the folder where you checked out the maven branch and click
>> >> finish
>> >> all projects should be imported and ready for use now (see console
>> >> view and enable maven console)
>> >> this way you will have eclipse projects for the parent projects as
>> >> well (empire-db-parent and empire-db-examples)
>> >>
>> >> About your questions:
>> >>
>> >>  - there seems to be a problem that after you have used the
>> m2eclipse
>> >> plugin and you try eclipse:eclipse + standard import that only the
>> >> parent project is coming up. Delete .project, .classpath and
>> .settings
>> >> in the root folder and the empire-db-examples folder to fix this.
>> that
>> >> is because the eclipse:eclipse plugin does not set up projects for
>> >> grouping projects and m2eclipse does.
>> >> *So the simple solution is choose with or without the m2eclipse
>> plugin
>> >> and stick to your choice*.
>> >>
>> >>  - what is the problem with checking out the whole branch? I
>> >> structured the project as one parent project with 3 modules and the
>> >> examples module has its own submodules, I could decouple the samples
>> >> module if that is bothering you but it's nice to have everything at
>> >> once and eclipse setting up the inter project dependencies. (with
>> >> m2eclipse you can choose to only import one module (with its
>> dependent
>> >> modules))
>> >>
>> >>  - yes it's best to ignore .project, .classpath, .settings and
>> target/
>> >>
>> >> we might want to add this info to a wiki somewhere
>> >>
>> >> On Fri, Feb 13, 2009 at 9:06 PM, Rainer Döbele <do...@esteam.de>
>> >> wrote:
>> >> > Hi Francis,
>> >> >
>> >> > thanks for your tips.
>> >> >
>> >> > The procedure you described has several disadvantages for me. At
>> the
>> >> moment it seem as if I could only checkout the whole maven branch -
>> >> otherwise it won't build. But instead of having the individual
>> projects
>> >> I have the whole maven directory treated as one project in the
>> Package
>> >> explorer (which of course it isn't). Following your advice I used
>> >> "import existing projects into workspace" for empire-db and empire-
>> db-
>> >> example. Then of course I have the sources appear twice, first under
>> >> their project node and second under the maven node - which is not
>> >> really a problem but not nice either.
>> >> > I tried to run the SampleApp but it could not find the
>> configuration
>> >> file.
>> >> > Also when synchronizing with svn it shows me a number of files it
>> >> wants to add to the repository - like , the classpath file, the
>> project
>> >> file and everything under target. These files and folders should
>> >> probably be added to svn ignore.
>> >> >
>> >> > What I dislike most, is that I have to check out the root into my
>> >> workspace and then use "import existing projects into workspace".
>> Isn't
>> >> there a more convenient way to do it?
>> >> >
>> >> > I am currently working on a project for a customer for which I
>> have
>> >> to use Maven.
>> >> > I can check out the project into the workspace, call mvn
>> >> eclipse:eclipse, use refresh and then run the project.
>> >> > This is a very convenient way, and I would like to have something
>> >> similar for Empire-db. But this project has no eclipse project
>> >> dependencies.
>> >> >
>> >> > I really don't mind calling one or two maven command from the
>> command
>> >> line, but I don't like to move files around (as with import project
>> >> into workspace etc.).
>> >> > For Jörg it seems to work, but without the appropriate command in
>> the
>> >> SVN repository view (which I still could not manage to have it
>> appear)
>> >> it's very inconvenient to use.
>> >> > I would be happy if I could check out the individual projects
>> >> directly and run the maven eclipse:eclipse command.
>> >> >
>> >> > I am sorry for being so late with my criticism - I really should
>> have
>> >> evaluated it earlier.
>> >> >
>> >> > Rainer
>> >> >
>> >> >> -----Ursprüngliche Nachricht-----
>> >> >> Von: Francis De Brabandere [mailto:francisdb@gmail.com]
>> >> >> Gesendet: Freitag, 13. Februar 2009 16:30
>> >> >> An: empire-db-dev@incubator.apache.org
>> >> >> Betreff: Re: using Maven
>> >> >>
>> >> >> Hi Rainer,
>> >> >>
>> >> >> the simplest way to get going is not installing an eclipse plugin
>> >> but
>> >> >> running the commands as explained in one of my my previous mails.
>> >> >>
>> >> >> mvn eclipse:eclipse -DdownloadSources=true
>> >> >> (for cleaning up first: mvn clean eclipse:clean eclipse:eclipse
>> >> >> -DdownloadSources=true)
>> >> >>
>> >> >> after that in eclipse:
>> >> >> file - import - existing projects into workspace
>> >> >>
>> >> >> select the folder where you checked out the maven branch and
>> click
>> >> >> finish
>> >> >> all projects hould be imported and ready for use now.
>> >> >>
>> >> >> the alternative is using m2eclipse plugin or q4e plugin
>> >> >> I only tested the m2eclipse plugin and if you use that one you
>> can
>> >> >> skip the eclipse:eclipse command and select import existing maven
>> >> >> project in the import menu
>> >> >>
>> >> >> and don't install both eclipse maven plugins as that is looking
>> for
>> >> >> trouble.
>> >> >>
>> >> >> I hope this helps
>> >> >>
>> >> >> On Fri, Feb 13, 2009 at 4:13 PM, Rainer Döbele
>> <do...@esteam.de>
>> >> >> wrote:
>> >> >> > Hi Franics,
>> >> >> >
>> >> >> > Being a Maven newbe I wonder whether you could give me some
>> advice
>> >> on
>> >> >> how to use it.
>> >> >> >
>> >> >> > I have both Maven and the Maven Eclipse Plugin installed but
>> >> unlike
>> >> >> Jörg I don't have the Option to "Check out as Maven project"
>> within
>> >> the
>> >> >> SVN Repository View (for some reason).
>> >> >> >
>> >> >> > Now if I check out the entire maven branch into my workspace
>> and
>> >> call
>> >> >> "mvn eclipse:eclipse" it reports "build successful".
>> >> >> >
>> >> >> > However in the Package Explorer I only have the maven node with
>> >> its
>> >> >> subnodes but none of them is marked as a project. Thus I cannot
>> >> compile
>> >> >> or run anything. I also have a bin and a target folder but
>> there's
>> >> not
>> >> >> much in there.
>> >> >> >
>> >> >> > If I only check out an example project (e.g. the empire-db-
>> >> example)
>> >> >> and call mvn eclipse:eclipse I get the following error:
>> >> >> > org.apache.maven.reactor.MavenExecutionException: Cannot find
>> >> parent:
>> >> >> org.apache
>> >> >> > .empire-db:empire-db-examples for project: org.apache.empire-
>> >> >> db:empire-db-exampl
>> >> >> > e:jar:2.0.5-SNAPSHOT for project org.apache.empire-db:empire-
>> db-
>> >> >> example:jar:2.0.
>> >> >> > 5-SNAPSHOT
>> >> >> >
>> >> >> > So what is the recommended way for checking the files out and
>> >> running
>> >> >> the examples?
>> >> >> >
>> >> >> > Rainer
>> >> >> >
>> >> >> >> -----Ursprüngliche Nachricht-----
>> >> >> >> Von: Francis De Brabandere [mailto:francisdb@gmail.com]
>> >> >> >> Gesendet: Donnerstag, 12. Februar 2009 23:09
>> >> >> >> An: empire-db-dev@incubator.apache.org
>> >> >> >> Betreff: Re: mavenized project
>> >> >> >>
>> >> >> >> well depends on what the release dist should look like, it
>> won't
>> >> be
>> >> >> >> the same as before
>> >> >> >>
>> >> >> >> On Tue, Feb 10, 2009 at 9:43 PM, Rainer Döbele
>> >> <do...@esteam.de>
>> >> >> wrote:
>> >> >> >> > Sounds good.
>> >> >> >> > Thanks for your evalation Jörg.
>> >> >> >> > And even more for your work Francis.
>> >> >> >> >
>> >> >> >> > So before we merge the maven branch with the trunk is there
>> >> >> anything
>> >> >> >> else to consider?
>> >> >> >> > If not I would call for a vote to merge the branches.
>> >> >> >> >
>> >> >> >> > Regards
>> >> >> >> > Rainer
>> >> >> >> >
>> >> >> >> >
>> >> >> >> > Jörg Reiher wrote:
>> >> >> >> >> re: mavenized project
>> >> >> >> >>
>> >> >> >> >> Hi,
>> >> >> >> >> I used m2e (just found out it wasn't even the latest
>> release
>> >> but
>> >> >> 0.96
>> >> >> >> (September 2008))
>> >> >> >> >> I haven't done a big evaluation of the available tools when
>> I
>> >> >> installed
>> >> >> >> it, just wanted to > know if there is any working plugin,
>> cause
>> >> when
>> >> >> I
>> >> >> >> worked at a company where Maven was used > (about 1.5 years
>> ago)
>> >> it
>> >> >> was a
>> >> >> >> big pain to keep
>> >> >> >> >> Eclipse project and Maven in synch... always switching
>> between
>> >> >> console
>> >> >> >> and Eclipse, refreshing > the project; now it seems to be much
>> >> much
>> >> >> better
>> >> >> >> - m2e did what I expected, so I didn't bother > trying other
>> >> >> plugins.
>> >> >> >> >>
>> >> >> >> >> Greets
>> >> >> >> >> jorg
>> >> >> >> >>
>> >> >> >> >
>> >> >> >>
>> >> >> >>
>> >> >> >>
>> >> >> >> --
>> >> >> >> http://www.somatik.be
>> >> >> >> Microsoft gives you windows, Linux gives you the whole house.
>> >> >> >
>> >> >>
>> >> >>
>> >> >>
>> >> >> --
>> >> >> http://www.somatik.be
>> >> >> Microsoft gives you windows, Linux gives you the whole house.
>> >> >
>> >>
>> >>
>> >>
>> >> --
>> >> http://www.somatik.be
>> >> Microsoft gives you windows, Linux gives you the whole house.
>> >
>>
>>
>>
>> --
>> http://www.somatik.be
>> Microsoft gives you windows, Linux gives you the whole house.
>



-- 
http://www.somatik.be
Microsoft gives you windows, Linux gives you the whole house.

re: using Maven

Posted by Rainer Döbele <do...@esteam.de>.
Hi Francis,

The MANIFEST.MF is in \empire-db-parent\empire-db\src\main\java\META-INF.
Don't know what or who's creating it.

About the configuration file:
When running a project eclipse set's the root path to the project directory.
This is where we expect to find the config.xml.
Hence for the empire-db-example the config.xml should be in the \empire-db-parent\empire-db-examples\empire-db-example directory - where the readme.txt or the tutorial.pdf are.
If there is no good reason aginst it, we should move it from src/main/resources back to the root.
We can still move it somewhere else in a coming distribution file.

Finally I am having problems running it with the oracle, sqlserver and mysql databases.
How can I find out the Maven groupId and artifactId in order to add a dependency for them to the pom?

(As you can see I am still struggeling, but I am slowly getting familiar with it)

Rainer

Francis De Brabandere wrote:
> Re: using Maven
> 
> On Sat, Feb 14, 2009 at 11:44 AM, Rainer Döbele <do...@esteam.de>
> wrote:
> > Hi Franics,
> >
> > good news. I have finally managed to get the "Checkout as Maven
> project" in the SVN view.
> > I had to update all plugins first and then install the subversive
> integration for M2Eclipse from
> >
> http://www.polarion.org/projects/subversive/download/integrations/updat
> e-site/
> > (I am using the m2 eclipse plugin)
> 
> good to hear that
> 
> >
> > Using the "Checkout as Maven project" command works really cool and I
> was able to run the SampleApp.
> > The two parent projects you mentioned are present and this can be a
> bit confusing. I'd rather not have them but I can live with it too.
> > What is still a problem however, is that it for every project (the
> parent projects as well as the real projects) it wants to add the
> following files and folders to the SVN Repository:
> >        .settings
> > org.eclipse.jdt.core.prefs
> > org.maven.ide.eclipse.prefs
> >        src/main/java/META-INF/MANIFEST.MF
> >        target
> >        .classpath
> >        .project
> > Isn't there a way of automatically adding them to svn.ignore so that
> after checking everything out no changes are reported from svn? Is this
> only a problem with the M2Eclipse plugin and what is the behaviour of
> the q4e plugin you mentioned?
> 
> I have only been testing the m2eclipse plugin the last two weeks, and
> I added the ignores for those files manually in my eclipse
> installation. I don't have any non-eclipse projects that might want to
> check in those files.
> 
> I have these ignores:
> target
> .project
> .settings
> .classpath
> .svn
> 
> for the manifest file,where did that come from?
> 
> never tried the q4e plugin
> 
> >
> > The standard eclipse way you described does not really work for me.
> First when you check out into your workspace, the Import Projects
> wizard hides the projects below the maven directory since they are
> already in the workspace. I guess you checked them out to a different
> location, which is no option for me as I want check out the files
> directly into my workspace.
> 
> I'm not using eclipse to check out into my workspace, I do this on the
> console and I'm not having these problems that way. You need to start
> with a clean checkout, run the maven eclipse target and then do the
> import of the 5 projects at once. Once you have a .project in the root
> (caused by m2eclipse) he won't detect the other projects any more.
> 
> 
> > Being able to "Checkout as Maven project" from SVN now is a great
> improvement for me and solves most of my problems. Without the plugin
> however I find it rather difficult and inconvenient to use. It would be
> cool though  if we could find a solution for automatically excluding
> the generated files mentioned above from the version control system.
> >
> 
> I don't think there is an automatic way for excluding on import...
> 
> 
> Francis
> 
> > Rainer
> >
> > Francis De Brabandere wrote:
> >> Re: using Maven
> >>
> >> Rainer,
> >>
> >> Are you sure you started with a clean checkout and without using the
> >> eclipse q4e plugin?
> >>
> >> svn checkout https://svn.apache.org/repos/asf/incubator/empire-
> >> db/branches/maven
> >> empire-maven-branch
> >>
> >> ### standard eclipse way ###
> >>
> >> cd empire-maven-branch
> >> mvn eclipse:eclipse -DdownloadSources=true
> >> ....
> >> [INFO] -------------------------------------------------------------
> ---
> >> --------
> >> [INFO] Reactor Summary:
> >> [INFO] -------------------------------------------------------------
> ---
> >> --------
> >> [INFO] Empire-db Parent ......................................
> SUCCESS
> >> [2.243s]
> >> [INFO] Empire-db .............................................
> SUCCESS
> >> [0.533s]
> >> [INFO] Empire-db Examples ....................................
> SUCCESS
> >> [0.006s]
> >> [INFO] Empire-db Example .....................................
> SUCCESS
> >> [5.821s]
> >> [INFO] Empire-db Advanced Example ............................
> SUCCESS
> >> [0.089s]
> >> [INFO] Empire-db Struts2 Extension ...........................
> SUCCESS
> >> [0.767s]
> >> [INFO] Empire-db Struts2 Example .............................
> SUCCESS
> >> [0.354s]
> >> [INFO] -------------------------------------------------------------
> ---
> >> --------
> >> [INFO] -------------------------------------------------------------
> ---
> >> --------
> >> [INFO] BUILD SUCCESSFUL
> >> [INFO] -------------------------------------------------------------
> ---
> >> --------
> >> [INFO] Total time: 13 seconds
> >> [INFO] Finished at: Fri Feb 13 23:46:57 CET 2009
> >> [INFO] Final Memory: 8M/279M
> >> [INFO] -------------------------------------------------------------
> ---
> >> --------
> >>
> >> file - import - existing projects into workspace
> >>
> >> select the folder where you checked out the maven branch and click
> >> finish
> >> all projects should be imported and ready for use now. (see
> screenshot)
> >>
> >> http://www.somatik.be/files/Screenshot-Import%20.png
> >>
> >> ### m2eclipse way ###
> >> file - import - maven projects
> >>
> >> select the folder where you checked out the maven branch and click
> >> finish
> >> all projects should be imported and ready for use now (see console
> >> view and enable maven console)
> >> this way you will have eclipse projects for the parent projects as
> >> well (empire-db-parent and empire-db-examples)
> >>
> >> About your questions:
> >>
> >>  - there seems to be a problem that after you have used the
> m2eclipse
> >> plugin and you try eclipse:eclipse + standard import that only the
> >> parent project is coming up. Delete .project, .classpath and
> .settings
> >> in the root folder and the empire-db-examples folder to fix this.
> that
> >> is because the eclipse:eclipse plugin does not set up projects for
> >> grouping projects and m2eclipse does.
> >> *So the simple solution is choose with or without the m2eclipse
> plugin
> >> and stick to your choice*.
> >>
> >>  - what is the problem with checking out the whole branch? I
> >> structured the project as one parent project with 3 modules and the
> >> examples module has its own submodules, I could decouple the samples
> >> module if that is bothering you but it's nice to have everything at
> >> once and eclipse setting up the inter project dependencies. (with
> >> m2eclipse you can choose to only import one module (with its
> dependent
> >> modules))
> >>
> >>  - yes it's best to ignore .project, .classpath, .settings and
> target/
> >>
> >> we might want to add this info to a wiki somewhere
> >>
> >> On Fri, Feb 13, 2009 at 9:06 PM, Rainer Döbele <do...@esteam.de>
> >> wrote:
> >> > Hi Francis,
> >> >
> >> > thanks for your tips.
> >> >
> >> > The procedure you described has several disadvantages for me. At
> the
> >> moment it seem as if I could only checkout the whole maven branch -
> >> otherwise it won't build. But instead of having the individual
> projects
> >> I have the whole maven directory treated as one project in the
> Package
> >> explorer (which of course it isn't). Following your advice I used
> >> "import existing projects into workspace" for empire-db and empire-
> db-
> >> example. Then of course I have the sources appear twice, first under
> >> their project node and second under the maven node - which is not
> >> really a problem but not nice either.
> >> > I tried to run the SampleApp but it could not find the
> configuration
> >> file.
> >> > Also when synchronizing with svn it shows me a number of files it
> >> wants to add to the repository - like , the classpath file, the
> project
> >> file and everything under target. These files and folders should
> >> probably be added to svn ignore.
> >> >
> >> > What I dislike most, is that I have to check out the root into my
> >> workspace and then use "import existing projects into workspace".
> Isn't
> >> there a more convenient way to do it?
> >> >
> >> > I am currently working on a project for a customer for which I
> have
> >> to use Maven.
> >> > I can check out the project into the workspace, call mvn
> >> eclipse:eclipse, use refresh and then run the project.
> >> > This is a very convenient way, and I would like to have something
> >> similar for Empire-db. But this project has no eclipse project
> >> dependencies.
> >> >
> >> > I really don't mind calling one or two maven command from the
> command
> >> line, but I don't like to move files around (as with import project
> >> into workspace etc.).
> >> > For Jörg it seems to work, but without the appropriate command in
> the
> >> SVN repository view (which I still could not manage to have it
> appear)
> >> it's very inconvenient to use.
> >> > I would be happy if I could check out the individual projects
> >> directly and run the maven eclipse:eclipse command.
> >> >
> >> > I am sorry for being so late with my criticism - I really should
> have
> >> evaluated it earlier.
> >> >
> >> > Rainer
> >> >
> >> >> -----Ursprüngliche Nachricht-----
> >> >> Von: Francis De Brabandere [mailto:francisdb@gmail.com]
> >> >> Gesendet: Freitag, 13. Februar 2009 16:30
> >> >> An: empire-db-dev@incubator.apache.org
> >> >> Betreff: Re: using Maven
> >> >>
> >> >> Hi Rainer,
> >> >>
> >> >> the simplest way to get going is not installing an eclipse plugin
> >> but
> >> >> running the commands as explained in one of my my previous mails.
> >> >>
> >> >> mvn eclipse:eclipse -DdownloadSources=true
> >> >> (for cleaning up first: mvn clean eclipse:clean eclipse:eclipse
> >> >> -DdownloadSources=true)
> >> >>
> >> >> after that in eclipse:
> >> >> file - import - existing projects into workspace
> >> >>
> >> >> select the folder where you checked out the maven branch and
> click
> >> >> finish
> >> >> all projects hould be imported and ready for use now.
> >> >>
> >> >> the alternative is using m2eclipse plugin or q4e plugin
> >> >> I only tested the m2eclipse plugin and if you use that one you
> can
> >> >> skip the eclipse:eclipse command and select import existing maven
> >> >> project in the import menu
> >> >>
> >> >> and don't install both eclipse maven plugins as that is looking
> for
> >> >> trouble.
> >> >>
> >> >> I hope this helps
> >> >>
> >> >> On Fri, Feb 13, 2009 at 4:13 PM, Rainer Döbele
> <do...@esteam.de>
> >> >> wrote:
> >> >> > Hi Franics,
> >> >> >
> >> >> > Being a Maven newbe I wonder whether you could give me some
> advice
> >> on
> >> >> how to use it.
> >> >> >
> >> >> > I have both Maven and the Maven Eclipse Plugin installed but
> >> unlike
> >> >> Jörg I don't have the Option to "Check out as Maven project"
> within
> >> the
> >> >> SVN Repository View (for some reason).
> >> >> >
> >> >> > Now if I check out the entire maven branch into my workspace
> and
> >> call
> >> >> "mvn eclipse:eclipse" it reports "build successful".
> >> >> >
> >> >> > However in the Package Explorer I only have the maven node with
> >> its
> >> >> subnodes but none of them is marked as a project. Thus I cannot
> >> compile
> >> >> or run anything. I also have a bin and a target folder but
> there's
> >> not
> >> >> much in there.
> >> >> >
> >> >> > If I only check out an example project (e.g. the empire-db-
> >> example)
> >> >> and call mvn eclipse:eclipse I get the following error:
> >> >> > org.apache.maven.reactor.MavenExecutionException: Cannot find
> >> parent:
> >> >> org.apache
> >> >> > .empire-db:empire-db-examples for project: org.apache.empire-
> >> >> db:empire-db-exampl
> >> >> > e:jar:2.0.5-SNAPSHOT for project org.apache.empire-db:empire-
> db-
> >> >> example:jar:2.0.
> >> >> > 5-SNAPSHOT
> >> >> >
> >> >> > So what is the recommended way for checking the files out and
> >> running
> >> >> the examples?
> >> >> >
> >> >> > Rainer
> >> >> >
> >> >> >> -----Ursprüngliche Nachricht-----
> >> >> >> Von: Francis De Brabandere [mailto:francisdb@gmail.com]
> >> >> >> Gesendet: Donnerstag, 12. Februar 2009 23:09
> >> >> >> An: empire-db-dev@incubator.apache.org
> >> >> >> Betreff: Re: mavenized project
> >> >> >>
> >> >> >> well depends on what the release dist should look like, it
> won't
> >> be
> >> >> >> the same as before
> >> >> >>
> >> >> >> On Tue, Feb 10, 2009 at 9:43 PM, Rainer Döbele
> >> <do...@esteam.de>
> >> >> wrote:
> >> >> >> > Sounds good.
> >> >> >> > Thanks for your evalation Jörg.
> >> >> >> > And even more for your work Francis.
> >> >> >> >
> >> >> >> > So before we merge the maven branch with the trunk is there
> >> >> anything
> >> >> >> else to consider?
> >> >> >> > If not I would call for a vote to merge the branches.
> >> >> >> >
> >> >> >> > Regards
> >> >> >> > Rainer
> >> >> >> >
> >> >> >> >
> >> >> >> > Jörg Reiher wrote:
> >> >> >> >> re: mavenized project
> >> >> >> >>
> >> >> >> >> Hi,
> >> >> >> >> I used m2e (just found out it wasn't even the latest
> release
> >> but
> >> >> 0.96
> >> >> >> (September 2008))
> >> >> >> >> I haven't done a big evaluation of the available tools when
> I
> >> >> installed
> >> >> >> it, just wanted to > know if there is any working plugin,
> cause
> >> when
> >> >> I
> >> >> >> worked at a company where Maven was used > (about 1.5 years
> ago)
> >> it
> >> >> was a
> >> >> >> big pain to keep
> >> >> >> >> Eclipse project and Maven in synch... always switching
> between
> >> >> console
> >> >> >> and Eclipse, refreshing > the project; now it seems to be much
> >> much
> >> >> better
> >> >> >> - m2e did what I expected, so I didn't bother > trying other
> >> >> plugins.
> >> >> >> >>
> >> >> >> >> Greets
> >> >> >> >> jorg
> >> >> >> >>
> >> >> >> >
> >> >> >>
> >> >> >>
> >> >> >>
> >> >> >> --
> >> >> >> http://www.somatik.be
> >> >> >> Microsoft gives you windows, Linux gives you the whole house.
> >> >> >
> >> >>
> >> >>
> >> >>
> >> >> --
> >> >> http://www.somatik.be
> >> >> Microsoft gives you windows, Linux gives you the whole house.
> >> >
> >>
> >>
> >>
> >> --
> >> http://www.somatik.be
> >> Microsoft gives you windows, Linux gives you the whole house.
> >
> 
> 
> 
> --
> http://www.somatik.be
> Microsoft gives you windows, Linux gives you the whole house.

Re: using Maven

Posted by Francis De Brabandere <fr...@gmail.com>.
On Sat, Feb 14, 2009 at 11:44 AM, Rainer Döbele <do...@esteam.de> wrote:
> Hi Franics,
>
> good news. I have finally managed to get the "Checkout as Maven project" in the SVN view.
> I had to update all plugins first and then install the subversive integration for M2Eclipse from
> http://www.polarion.org/projects/subversive/download/integrations/update-site/
> (I am using the m2 eclipse plugin)

good to hear that

>
> Using the "Checkout as Maven project" command works really cool and I was able to run the SampleApp.
> The two parent projects you mentioned are present and this can be a bit confusing. I'd rather not have them but I can live with it too.
> What is still a problem however, is that it for every project (the parent projects as well as the real projects) it wants to add the following files and folders to the SVN Repository:
>        .settings
> org.eclipse.jdt.core.prefs
> org.maven.ide.eclipse.prefs
>        src/main/java/META-INF/MANIFEST.MF
>        target
>        .classpath
>        .project
> Isn't there a way of automatically adding them to svn.ignore so that after checking everything out no changes are reported from svn? Is this only a problem with the M2Eclipse plugin and what is the behaviour of the q4e plugin you mentioned?

I have only been testing the m2eclipse plugin the last two weeks, and
I added the ignores for those files manually in my eclipse
installation. I don't have any non-eclipse projects that might want to
check in those files.

I have these ignores:
target
.project
.settings
.classpath
.svn

for the manifest file,where did that come from?

never tried the q4e plugin

>
> The standard eclipse way you described does not really work for me. First when you check out into your workspace, the Import Projects wizard hides the projects below the maven directory since they are already in the workspace. I guess you checked them out to a different location, which is no option for me as I want check out the files directly into my workspace.

I'm not using eclipse to check out into my workspace, I do this on the
console and I'm not having these problems that way. You need to start
with a clean checkout, run the maven eclipse target and then do the
import of the 5 projects at once. Once you have a .project in the root
(caused by m2eclipse) he won't detect the other projects any more.


> Being able to "Checkout as Maven project" from SVN now is a great improvement for me and solves most of my problems. Without the plugin however I find it rather difficult and inconvenient to use. It would be cool though  if we could find a solution for automatically excluding the generated files mentioned above from the version control system.
>

I don't think there is an automatic way for excluding on import...


Francis

> Rainer
>
> Francis De Brabandere wrote:
>> Re: using Maven
>>
>> Rainer,
>>
>> Are you sure you started with a clean checkout and without using the
>> eclipse q4e plugin?
>>
>> svn checkout https://svn.apache.org/repos/asf/incubator/empire-
>> db/branches/maven
>> empire-maven-branch
>>
>> ### standard eclipse way ###
>>
>> cd empire-maven-branch
>> mvn eclipse:eclipse -DdownloadSources=true
>> ....
>> [INFO] ----------------------------------------------------------------
>> --------
>> [INFO] Reactor Summary:
>> [INFO] ----------------------------------------------------------------
>> --------
>> [INFO] Empire-db Parent ...................................... SUCCESS
>> [2.243s]
>> [INFO] Empire-db ............................................. SUCCESS
>> [0.533s]
>> [INFO] Empire-db Examples .................................... SUCCESS
>> [0.006s]
>> [INFO] Empire-db Example ..................................... SUCCESS
>> [5.821s]
>> [INFO] Empire-db Advanced Example ............................ SUCCESS
>> [0.089s]
>> [INFO] Empire-db Struts2 Extension ........................... SUCCESS
>> [0.767s]
>> [INFO] Empire-db Struts2 Example ............................. SUCCESS
>> [0.354s]
>> [INFO] ----------------------------------------------------------------
>> --------
>> [INFO] ----------------------------------------------------------------
>> --------
>> [INFO] BUILD SUCCESSFUL
>> [INFO] ----------------------------------------------------------------
>> --------
>> [INFO] Total time: 13 seconds
>> [INFO] Finished at: Fri Feb 13 23:46:57 CET 2009
>> [INFO] Final Memory: 8M/279M
>> [INFO] ----------------------------------------------------------------
>> --------
>>
>> file - import - existing projects into workspace
>>
>> select the folder where you checked out the maven branch and click
>> finish
>> all projects should be imported and ready for use now. (see screenshot)
>>
>> http://www.somatik.be/files/Screenshot-Import%20.png
>>
>> ### m2eclipse way ###
>> file - import - maven projects
>>
>> select the folder where you checked out the maven branch and click
>> finish
>> all projects should be imported and ready for use now (see console
>> view and enable maven console)
>> this way you will have eclipse projects for the parent projects as
>> well (empire-db-parent and empire-db-examples)
>>
>> About your questions:
>>
>>  - there seems to be a problem that after you have used the m2eclipse
>> plugin and you try eclipse:eclipse + standard import that only the
>> parent project is coming up. Delete .project, .classpath and .settings
>> in the root folder and the empire-db-examples folder to fix this. that
>> is because the eclipse:eclipse plugin does not set up projects for
>> grouping projects and m2eclipse does.
>> *So the simple solution is choose with or without the m2eclipse plugin
>> and stick to your choice*.
>>
>>  - what is the problem with checking out the whole branch? I
>> structured the project as one parent project with 3 modules and the
>> examples module has its own submodules, I could decouple the samples
>> module if that is bothering you but it's nice to have everything at
>> once and eclipse setting up the inter project dependencies. (with
>> m2eclipse you can choose to only import one module (with its dependent
>> modules))
>>
>>  - yes it's best to ignore .project, .classpath, .settings and target/
>>
>> we might want to add this info to a wiki somewhere
>>
>> On Fri, Feb 13, 2009 at 9:06 PM, Rainer Döbele <do...@esteam.de>
>> wrote:
>> > Hi Francis,
>> >
>> > thanks for your tips.
>> >
>> > The procedure you described has several disadvantages for me. At the
>> moment it seem as if I could only checkout the whole maven branch -
>> otherwise it won't build. But instead of having the individual projects
>> I have the whole maven directory treated as one project in the Package
>> explorer (which of course it isn't). Following your advice I used
>> "import existing projects into workspace" for empire-db and empire-db-
>> example. Then of course I have the sources appear twice, first under
>> their project node and second under the maven node - which is not
>> really a problem but not nice either.
>> > I tried to run the SampleApp but it could not find the configuration
>> file.
>> > Also when synchronizing with svn it shows me a number of files it
>> wants to add to the repository - like , the classpath file, the project
>> file and everything under target. These files and folders should
>> probably be added to svn ignore.
>> >
>> > What I dislike most, is that I have to check out the root into my
>> workspace and then use "import existing projects into workspace". Isn't
>> there a more convenient way to do it?
>> >
>> > I am currently working on a project for a customer for which I have
>> to use Maven.
>> > I can check out the project into the workspace, call mvn
>> eclipse:eclipse, use refresh and then run the project.
>> > This is a very convenient way, and I would like to have something
>> similar for Empire-db. But this project has no eclipse project
>> dependencies.
>> >
>> > I really don't mind calling one or two maven command from the command
>> line, but I don't like to move files around (as with import project
>> into workspace etc.).
>> > For Jörg it seems to work, but without the appropriate command in the
>> SVN repository view (which I still could not manage to have it appear)
>> it's very inconvenient to use.
>> > I would be happy if I could check out the individual projects
>> directly and run the maven eclipse:eclipse command.
>> >
>> > I am sorry for being so late with my criticism - I really should have
>> evaluated it earlier.
>> >
>> > Rainer
>> >
>> >> -----Ursprüngliche Nachricht-----
>> >> Von: Francis De Brabandere [mailto:francisdb@gmail.com]
>> >> Gesendet: Freitag, 13. Februar 2009 16:30
>> >> An: empire-db-dev@incubator.apache.org
>> >> Betreff: Re: using Maven
>> >>
>> >> Hi Rainer,
>> >>
>> >> the simplest way to get going is not installing an eclipse plugin
>> but
>> >> running the commands as explained in one of my my previous mails.
>> >>
>> >> mvn eclipse:eclipse -DdownloadSources=true
>> >> (for cleaning up first: mvn clean eclipse:clean eclipse:eclipse
>> >> -DdownloadSources=true)
>> >>
>> >> after that in eclipse:
>> >> file - import - existing projects into workspace
>> >>
>> >> select the folder where you checked out the maven branch and click
>> >> finish
>> >> all projects hould be imported and ready for use now.
>> >>
>> >> the alternative is using m2eclipse plugin or q4e plugin
>> >> I only tested the m2eclipse plugin and if you use that one you can
>> >> skip the eclipse:eclipse command and select import existing maven
>> >> project in the import menu
>> >>
>> >> and don't install both eclipse maven plugins as that is looking for
>> >> trouble.
>> >>
>> >> I hope this helps
>> >>
>> >> On Fri, Feb 13, 2009 at 4:13 PM, Rainer Döbele <do...@esteam.de>
>> >> wrote:
>> >> > Hi Franics,
>> >> >
>> >> > Being a Maven newbe I wonder whether you could give me some advice
>> on
>> >> how to use it.
>> >> >
>> >> > I have both Maven and the Maven Eclipse Plugin installed but
>> unlike
>> >> Jörg I don't have the Option to "Check out as Maven project" within
>> the
>> >> SVN Repository View (for some reason).
>> >> >
>> >> > Now if I check out the entire maven branch into my workspace and
>> call
>> >> "mvn eclipse:eclipse" it reports "build successful".
>> >> >
>> >> > However in the Package Explorer I only have the maven node with
>> its
>> >> subnodes but none of them is marked as a project. Thus I cannot
>> compile
>> >> or run anything. I also have a bin and a target folder but there's
>> not
>> >> much in there.
>> >> >
>> >> > If I only check out an example project (e.g. the empire-db-
>> example)
>> >> and call mvn eclipse:eclipse I get the following error:
>> >> > org.apache.maven.reactor.MavenExecutionException: Cannot find
>> parent:
>> >> org.apache
>> >> > .empire-db:empire-db-examples for project: org.apache.empire-
>> >> db:empire-db-exampl
>> >> > e:jar:2.0.5-SNAPSHOT for project org.apache.empire-db:empire-db-
>> >> example:jar:2.0.
>> >> > 5-SNAPSHOT
>> >> >
>> >> > So what is the recommended way for checking the files out and
>> running
>> >> the examples?
>> >> >
>> >> > Rainer
>> >> >
>> >> >> -----Ursprüngliche Nachricht-----
>> >> >> Von: Francis De Brabandere [mailto:francisdb@gmail.com]
>> >> >> Gesendet: Donnerstag, 12. Februar 2009 23:09
>> >> >> An: empire-db-dev@incubator.apache.org
>> >> >> Betreff: Re: mavenized project
>> >> >>
>> >> >> well depends on what the release dist should look like, it won't
>> be
>> >> >> the same as before
>> >> >>
>> >> >> On Tue, Feb 10, 2009 at 9:43 PM, Rainer Döbele
>> <do...@esteam.de>
>> >> wrote:
>> >> >> > Sounds good.
>> >> >> > Thanks for your evalation Jörg.
>> >> >> > And even more for your work Francis.
>> >> >> >
>> >> >> > So before we merge the maven branch with the trunk is there
>> >> anything
>> >> >> else to consider?
>> >> >> > If not I would call for a vote to merge the branches.
>> >> >> >
>> >> >> > Regards
>> >> >> > Rainer
>> >> >> >
>> >> >> >
>> >> >> > Jörg Reiher wrote:
>> >> >> >> re: mavenized project
>> >> >> >>
>> >> >> >> Hi,
>> >> >> >> I used m2e (just found out it wasn't even the latest release
>> but
>> >> 0.96
>> >> >> (September 2008))
>> >> >> >> I haven't done a big evaluation of the available tools when I
>> >> installed
>> >> >> it, just wanted to > know if there is any working plugin, cause
>> when
>> >> I
>> >> >> worked at a company where Maven was used > (about 1.5 years ago)
>> it
>> >> was a
>> >> >> big pain to keep
>> >> >> >> Eclipse project and Maven in synch... always switching between
>> >> console
>> >> >> and Eclipse, refreshing > the project; now it seems to be much
>> much
>> >> better
>> >> >> - m2e did what I expected, so I didn't bother > trying other
>> >> plugins.
>> >> >> >>
>> >> >> >> Greets
>> >> >> >> jorg
>> >> >> >>
>> >> >> >
>> >> >>
>> >> >>
>> >> >>
>> >> >> --
>> >> >> http://www.somatik.be
>> >> >> Microsoft gives you windows, Linux gives you the whole house.
>> >> >
>> >>
>> >>
>> >>
>> >> --
>> >> http://www.somatik.be
>> >> Microsoft gives you windows, Linux gives you the whole house.
>> >
>>
>>
>>
>> --
>> http://www.somatik.be
>> Microsoft gives you windows, Linux gives you the whole house.
>



-- 
http://www.somatik.be
Microsoft gives you windows, Linux gives you the whole house.

re: using Maven

Posted by Rainer Döbele <do...@esteam.de>.
Hi Franics,

good news. I have finally managed to get the "Checkout as Maven project" in the SVN view. 
I had to update all plugins first and then install the subversive integration for M2Eclipse from
http://www.polarion.org/projects/subversive/download/integrations/update-site/
(I am using the m2 eclipse plugin)

Using the "Checkout as Maven project" command works really cool and I was able to run the SampleApp. 
The two parent projects you mentioned are present and this can be a bit confusing. I'd rather not have them but I can live with it too.
What is still a problem however, is that it for every project (the parent projects as well as the real projects) it wants to add the following files and folders to the SVN Repository:
	.settings
org.eclipse.jdt.core.prefs
org.maven.ide.eclipse.prefs
	src/main/java/META-INF/MANIFEST.MF
	target
	.classpath
	.project
Isn't there a way of automatically adding them to svn.ignore so that after checking everything out no changes are reported from svn? Is this only a problem with the M2Eclipse plugin and what is the behaviour of the q4e plugin you mentioned?

The standard eclipse way you described does not really work for me. First when you check out into your workspace, the Import Projects wizard hides the projects below the maven directory since they are already in the workspace. I guess you checked them out to a different location, which is no option for me as I want check out the files directly into my workspace.

Being able to "Checkout as Maven project" from SVN now is a great improvement for me and solves most of my problems. Without the plugin however I find it rather difficult and inconvenient to use. It would be cool though  if we could find a solution for automatically excluding the generated files mentioned above from the version control system.

Rainer

Francis De Brabandere wrote:
> Re: using Maven
> 
> Rainer,
> 
> Are you sure you started with a clean checkout and without using the
> eclipse q4e plugin?
> 
> svn checkout https://svn.apache.org/repos/asf/incubator/empire-
> db/branches/maven
> empire-maven-branch
> 
> ### standard eclipse way ###
> 
> cd empire-maven-branch
> mvn eclipse:eclipse -DdownloadSources=true
> ....
> [INFO] ----------------------------------------------------------------
> --------
> [INFO] Reactor Summary:
> [INFO] ----------------------------------------------------------------
> --------
> [INFO] Empire-db Parent ...................................... SUCCESS
> [2.243s]
> [INFO] Empire-db ............................................. SUCCESS
> [0.533s]
> [INFO] Empire-db Examples .................................... SUCCESS
> [0.006s]
> [INFO] Empire-db Example ..................................... SUCCESS
> [5.821s]
> [INFO] Empire-db Advanced Example ............................ SUCCESS
> [0.089s]
> [INFO] Empire-db Struts2 Extension ........................... SUCCESS
> [0.767s]
> [INFO] Empire-db Struts2 Example ............................. SUCCESS
> [0.354s]
> [INFO] ----------------------------------------------------------------
> --------
> [INFO] ----------------------------------------------------------------
> --------
> [INFO] BUILD SUCCESSFUL
> [INFO] ----------------------------------------------------------------
> --------
> [INFO] Total time: 13 seconds
> [INFO] Finished at: Fri Feb 13 23:46:57 CET 2009
> [INFO] Final Memory: 8M/279M
> [INFO] ----------------------------------------------------------------
> --------
> 
> file - import - existing projects into workspace
> 
> select the folder where you checked out the maven branch and click
> finish
> all projects should be imported and ready for use now. (see screenshot)
> 
> http://www.somatik.be/files/Screenshot-Import%20.png
> 
> ### m2eclipse way ###
> file - import - maven projects
> 
> select the folder where you checked out the maven branch and click
> finish
> all projects should be imported and ready for use now (see console
> view and enable maven console)
> this way you will have eclipse projects for the parent projects as
> well (empire-db-parent and empire-db-examples)
> 
> About your questions:
> 
>  - there seems to be a problem that after you have used the m2eclipse
> plugin and you try eclipse:eclipse + standard import that only the
> parent project is coming up. Delete .project, .classpath and .settings
> in the root folder and the empire-db-examples folder to fix this. that
> is because the eclipse:eclipse plugin does not set up projects for
> grouping projects and m2eclipse does.
> *So the simple solution is choose with or without the m2eclipse plugin
> and stick to your choice*.
> 
>  - what is the problem with checking out the whole branch? I
> structured the project as one parent project with 3 modules and the
> examples module has its own submodules, I could decouple the samples
> module if that is bothering you but it's nice to have everything at
> once and eclipse setting up the inter project dependencies. (with
> m2eclipse you can choose to only import one module (with its dependent
> modules))
> 
>  - yes it's best to ignore .project, .classpath, .settings and target/
> 
> we might want to add this info to a wiki somewhere
> 
> On Fri, Feb 13, 2009 at 9:06 PM, Rainer Döbele <do...@esteam.de>
> wrote:
> > Hi Francis,
> >
> > thanks for your tips.
> >
> > The procedure you described has several disadvantages for me. At the
> moment it seem as if I could only checkout the whole maven branch -
> otherwise it won't build. But instead of having the individual projects
> I have the whole maven directory treated as one project in the Package
> explorer (which of course it isn't). Following your advice I used
> "import existing projects into workspace" for empire-db and empire-db-
> example. Then of course I have the sources appear twice, first under
> their project node and second under the maven node - which is not
> really a problem but not nice either.
> > I tried to run the SampleApp but it could not find the configuration
> file.
> > Also when synchronizing with svn it shows me a number of files it
> wants to add to the repository - like , the classpath file, the project
> file and everything under target. These files and folders should
> probably be added to svn ignore.
> >
> > What I dislike most, is that I have to check out the root into my
> workspace and then use "import existing projects into workspace". Isn't
> there a more convenient way to do it?
> >
> > I am currently working on a project for a customer for which I have
> to use Maven.
> > I can check out the project into the workspace, call mvn
> eclipse:eclipse, use refresh and then run the project.
> > This is a very convenient way, and I would like to have something
> similar for Empire-db. But this project has no eclipse project
> dependencies.
> >
> > I really don't mind calling one or two maven command from the command
> line, but I don't like to move files around (as with import project
> into workspace etc.).
> > For Jörg it seems to work, but without the appropriate command in the
> SVN repository view (which I still could not manage to have it appear)
> it's very inconvenient to use.
> > I would be happy if I could check out the individual projects
> directly and run the maven eclipse:eclipse command.
> >
> > I am sorry for being so late with my criticism - I really should have
> evaluated it earlier.
> >
> > Rainer
> >
> >> -----Ursprüngliche Nachricht-----
> >> Von: Francis De Brabandere [mailto:francisdb@gmail.com]
> >> Gesendet: Freitag, 13. Februar 2009 16:30
> >> An: empire-db-dev@incubator.apache.org
> >> Betreff: Re: using Maven
> >>
> >> Hi Rainer,
> >>
> >> the simplest way to get going is not installing an eclipse plugin
> but
> >> running the commands as explained in one of my my previous mails.
> >>
> >> mvn eclipse:eclipse -DdownloadSources=true
> >> (for cleaning up first: mvn clean eclipse:clean eclipse:eclipse
> >> -DdownloadSources=true)
> >>
> >> after that in eclipse:
> >> file - import - existing projects into workspace
> >>
> >> select the folder where you checked out the maven branch and click
> >> finish
> >> all projects hould be imported and ready for use now.
> >>
> >> the alternative is using m2eclipse plugin or q4e plugin
> >> I only tested the m2eclipse plugin and if you use that one you can
> >> skip the eclipse:eclipse command and select import existing maven
> >> project in the import menu
> >>
> >> and don't install both eclipse maven plugins as that is looking for
> >> trouble.
> >>
> >> I hope this helps
> >>
> >> On Fri, Feb 13, 2009 at 4:13 PM, Rainer Döbele <do...@esteam.de>
> >> wrote:
> >> > Hi Franics,
> >> >
> >> > Being a Maven newbe I wonder whether you could give me some advice
> on
> >> how to use it.
> >> >
> >> > I have both Maven and the Maven Eclipse Plugin installed but
> unlike
> >> Jörg I don't have the Option to "Check out as Maven project" within
> the
> >> SVN Repository View (for some reason).
> >> >
> >> > Now if I check out the entire maven branch into my workspace and
> call
> >> "mvn eclipse:eclipse" it reports "build successful".
> >> >
> >> > However in the Package Explorer I only have the maven node with
> its
> >> subnodes but none of them is marked as a project. Thus I cannot
> compile
> >> or run anything. I also have a bin and a target folder but there's
> not
> >> much in there.
> >> >
> >> > If I only check out an example project (e.g. the empire-db-
> example)
> >> and call mvn eclipse:eclipse I get the following error:
> >> > org.apache.maven.reactor.MavenExecutionException: Cannot find
> parent:
> >> org.apache
> >> > .empire-db:empire-db-examples for project: org.apache.empire-
> >> db:empire-db-exampl
> >> > e:jar:2.0.5-SNAPSHOT for project org.apache.empire-db:empire-db-
> >> example:jar:2.0.
> >> > 5-SNAPSHOT
> >> >
> >> > So what is the recommended way for checking the files out and
> running
> >> the examples?
> >> >
> >> > Rainer
> >> >
> >> >> -----Ursprüngliche Nachricht-----
> >> >> Von: Francis De Brabandere [mailto:francisdb@gmail.com]
> >> >> Gesendet: Donnerstag, 12. Februar 2009 23:09
> >> >> An: empire-db-dev@incubator.apache.org
> >> >> Betreff: Re: mavenized project
> >> >>
> >> >> well depends on what the release dist should look like, it won't
> be
> >> >> the same as before
> >> >>
> >> >> On Tue, Feb 10, 2009 at 9:43 PM, Rainer Döbele
> <do...@esteam.de>
> >> wrote:
> >> >> > Sounds good.
> >> >> > Thanks for your evalation Jörg.
> >> >> > And even more for your work Francis.
> >> >> >
> >> >> > So before we merge the maven branch with the trunk is there
> >> anything
> >> >> else to consider?
> >> >> > If not I would call for a vote to merge the branches.
> >> >> >
> >> >> > Regards
> >> >> > Rainer
> >> >> >
> >> >> >
> >> >> > Jörg Reiher wrote:
> >> >> >> re: mavenized project
> >> >> >>
> >> >> >> Hi,
> >> >> >> I used m2e (just found out it wasn't even the latest release
> but
> >> 0.96
> >> >> (September 2008))
> >> >> >> I haven't done a big evaluation of the available tools when I
> >> installed
> >> >> it, just wanted to > know if there is any working plugin, cause
> when
> >> I
> >> >> worked at a company where Maven was used > (about 1.5 years ago)
> it
> >> was a
> >> >> big pain to keep
> >> >> >> Eclipse project and Maven in synch... always switching between
> >> console
> >> >> and Eclipse, refreshing > the project; now it seems to be much
> much
> >> better
> >> >> - m2e did what I expected, so I didn't bother > trying other
> >> plugins.
> >> >> >>
> >> >> >> Greets
> >> >> >> jorg
> >> >> >>
> >> >> >
> >> >>
> >> >>
> >> >>
> >> >> --
> >> >> http://www.somatik.be
> >> >> Microsoft gives you windows, Linux gives you the whole house.
> >> >
> >>
> >>
> >>
> >> --
> >> http://www.somatik.be
> >> Microsoft gives you windows, Linux gives you the whole house.
> >
> 
> 
> 
> --
> http://www.somatik.be
> Microsoft gives you windows, Linux gives you the whole house.

Re: using Maven

Posted by Francis De Brabandere <fr...@gmail.com>.
Rainer,

Are you sure you started with a clean checkout and without using the
eclipse q4e plugin?

svn checkout https://svn.apache.org/repos/asf/incubator/empire-db/branches/maven
empire-maven-branch

### standard eclipse way ###

cd empire-maven-branch
mvn eclipse:eclipse -DdownloadSources=true
....
[INFO] ------------------------------------------------------------------------
[INFO] Reactor Summary:
[INFO] ------------------------------------------------------------------------
[INFO] Empire-db Parent ...................................... SUCCESS [2.243s]
[INFO] Empire-db ............................................. SUCCESS [0.533s]
[INFO] Empire-db Examples .................................... SUCCESS [0.006s]
[INFO] Empire-db Example ..................................... SUCCESS [5.821s]
[INFO] Empire-db Advanced Example ............................ SUCCESS [0.089s]
[INFO] Empire-db Struts2 Extension ........................... SUCCESS [0.767s]
[INFO] Empire-db Struts2 Example ............................. SUCCESS [0.354s]
[INFO] ------------------------------------------------------------------------
[INFO] ------------------------------------------------------------------------
[INFO] BUILD SUCCESSFUL
[INFO] ------------------------------------------------------------------------
[INFO] Total time: 13 seconds
[INFO] Finished at: Fri Feb 13 23:46:57 CET 2009
[INFO] Final Memory: 8M/279M
[INFO] ------------------------------------------------------------------------

file - import - existing projects into workspace

select the folder where you checked out the maven branch and click finish
all projects should be imported and ready for use now. (see screenshot)

http://www.somatik.be/files/Screenshot-Import%20.png

### m2eclipse way ###
file - import - maven projects

select the folder where you checked out the maven branch and click finish
all projects should be imported and ready for use now (see console
view and enable maven console)
this way you will have eclipse projects for the parent projects as
well (empire-db-parent and empire-db-examples)

About your questions:

 - there seems to be a problem that after you have used the m2eclipse
plugin and you try eclipse:eclipse + standard import that only the
parent project is coming up. Delete .project, .classpath and .settings
in the root folder and the empire-db-examples folder to fix this. that
is because the eclipse:eclipse plugin does not set up projects for
grouping projects and m2eclipse does.
*So the simple solution is choose with or without the m2eclipse plugin
and stick to your choice*.

 - what is the problem with checking out the whole branch? I
structured the project as one parent project with 3 modules and the
examples module has its own submodules, I could decouple the samples
module if that is bothering you but it's nice to have everything at
once and eclipse setting up the inter project dependencies. (with
m2eclipse you can choose to only import one module (with its dependent
modules))

 - yes it's best to ignore .project, .classpath, .settings and target/

we might want to add this info to a wiki somewhere

On Fri, Feb 13, 2009 at 9:06 PM, Rainer Döbele <do...@esteam.de> wrote:
> Hi Francis,
>
> thanks for your tips.
>
> The procedure you described has several disadvantages for me. At the moment it seem as if I could only checkout the whole maven branch - otherwise it won't build. But instead of having the individual projects I have the whole maven directory treated as one project in the Package explorer (which of course it isn't). Following your advice I used "import existing projects into workspace" for empire-db and empire-db-example. Then of course I have the sources appear twice, first under their project node and second under the maven node - which is not really a problem but not nice either.
> I tried to run the SampleApp but it could not find the configuration file.
> Also when synchronizing with svn it shows me a number of files it wants to add to the repository - like , the classpath file, the project file and everything under target. These files and folders should probably be added to svn ignore.
>
> What I dislike most, is that I have to check out the root into my workspace and then use "import existing projects into workspace". Isn't there a more convenient way to do it?
>
> I am currently working on a project for a customer for which I have to use Maven.
> I can check out the project into the workspace, call mvn eclipse:eclipse, use refresh and then run the project.
> This is a very convenient way, and I would like to have something similar for Empire-db. But this project has no eclipse project dependencies.
>
> I really don't mind calling one or two maven command from the command line, but I don't like to move files around (as with import project into workspace etc.).
> For Jörg it seems to work, but without the appropriate command in the SVN repository view (which I still could not manage to have it appear) it's very inconvenient to use.
> I would be happy if I could check out the individual projects directly and run the maven eclipse:eclipse command.
>
> I am sorry for being so late with my criticism - I really should have evaluated it earlier.
>
> Rainer
>
>> -----Ursprüngliche Nachricht-----
>> Von: Francis De Brabandere [mailto:francisdb@gmail.com]
>> Gesendet: Freitag, 13. Februar 2009 16:30
>> An: empire-db-dev@incubator.apache.org
>> Betreff: Re: using Maven
>>
>> Hi Rainer,
>>
>> the simplest way to get going is not installing an eclipse plugin but
>> running the commands as explained in one of my my previous mails.
>>
>> mvn eclipse:eclipse -DdownloadSources=true
>> (for cleaning up first: mvn clean eclipse:clean eclipse:eclipse
>> -DdownloadSources=true)
>>
>> after that in eclipse:
>> file - import - existing projects into workspace
>>
>> select the folder where you checked out the maven branch and click
>> finish
>> all projects hould be imported and ready for use now.
>>
>> the alternative is using m2eclipse plugin or q4e plugin
>> I only tested the m2eclipse plugin and if you use that one you can
>> skip the eclipse:eclipse command and select import existing maven
>> project in the import menu
>>
>> and don't install both eclipse maven plugins as that is looking for
>> trouble.
>>
>> I hope this helps
>>
>> On Fri, Feb 13, 2009 at 4:13 PM, Rainer Döbele <do...@esteam.de>
>> wrote:
>> > Hi Franics,
>> >
>> > Being a Maven newbe I wonder whether you could give me some advice on
>> how to use it.
>> >
>> > I have both Maven and the Maven Eclipse Plugin installed but unlike
>> Jörg I don't have the Option to "Check out as Maven project" within the
>> SVN Repository View (for some reason).
>> >
>> > Now if I check out the entire maven branch into my workspace and call
>> "mvn eclipse:eclipse" it reports "build successful".
>> >
>> > However in the Package Explorer I only have the maven node with its
>> subnodes but none of them is marked as a project. Thus I cannot compile
>> or run anything. I also have a bin and a target folder but there's not
>> much in there.
>> >
>> > If I only check out an example project (e.g. the empire-db-example)
>> and call mvn eclipse:eclipse I get the following error:
>> > org.apache.maven.reactor.MavenExecutionException: Cannot find parent:
>> org.apache
>> > .empire-db:empire-db-examples for project: org.apache.empire-
>> db:empire-db-exampl
>> > e:jar:2.0.5-SNAPSHOT for project org.apache.empire-db:empire-db-
>> example:jar:2.0.
>> > 5-SNAPSHOT
>> >
>> > So what is the recommended way for checking the files out and running
>> the examples?
>> >
>> > Rainer
>> >
>> >> -----Ursprüngliche Nachricht-----
>> >> Von: Francis De Brabandere [mailto:francisdb@gmail.com]
>> >> Gesendet: Donnerstag, 12. Februar 2009 23:09
>> >> An: empire-db-dev@incubator.apache.org
>> >> Betreff: Re: mavenized project
>> >>
>> >> well depends on what the release dist should look like, it won't be
>> >> the same as before
>> >>
>> >> On Tue, Feb 10, 2009 at 9:43 PM, Rainer Döbele <do...@esteam.de>
>> wrote:
>> >> > Sounds good.
>> >> > Thanks for your evalation Jörg.
>> >> > And even more for your work Francis.
>> >> >
>> >> > So before we merge the maven branch with the trunk is there
>> anything
>> >> else to consider?
>> >> > If not I would call for a vote to merge the branches.
>> >> >
>> >> > Regards
>> >> > Rainer
>> >> >
>> >> >
>> >> > Jörg Reiher wrote:
>> >> >> re: mavenized project
>> >> >>
>> >> >> Hi,
>> >> >> I used m2e (just found out it wasn't even the latest release but
>> 0.96
>> >> (September 2008))
>> >> >> I haven't done a big evaluation of the available tools when I
>> installed
>> >> it, just wanted to > know if there is any working plugin, cause when
>> I
>> >> worked at a company where Maven was used > (about 1.5 years ago) it
>> was a
>> >> big pain to keep
>> >> >> Eclipse project and Maven in synch... always switching between
>> console
>> >> and Eclipse, refreshing > the project; now it seems to be much much
>> better
>> >> - m2e did what I expected, so I didn't bother > trying other
>> plugins.
>> >> >>
>> >> >> Greets
>> >> >> jorg
>> >> >>
>> >> >
>> >>
>> >>
>> >>
>> >> --
>> >> http://www.somatik.be
>> >> Microsoft gives you windows, Linux gives you the whole house.
>> >
>>
>>
>>
>> --
>> http://www.somatik.be
>> Microsoft gives you windows, Linux gives you the whole house.
>



-- 
http://www.somatik.be
Microsoft gives you windows, Linux gives you the whole house.

AW: using Maven

Posted by Rainer Döbele <do...@esteam.de>.
Hi Francis,

thanks for your tips.

The procedure you described has several disadvantages for me. At the moment it seem as if I could only checkout the whole maven branch - otherwise it won't build. But instead of having the individual projects I have the whole maven directory treated as one project in the Package explorer (which of course it isn't). Following your advice I used "import existing projects into workspace" for empire-db and empire-db-example. Then of course I have the sources appear twice, first under their project node and second under the maven node - which is not really a problem but not nice either.
I tried to run the SampleApp but it could not find the configuration file.
Also when synchronizing with svn it shows me a number of files it wants to add to the repository - like , the classpath file, the project file and everything under target. These files and folders should probably be added to svn ignore. 

What I dislike most, is that I have to check out the root into my workspace and then use "import existing projects into workspace". Isn't there a more convenient way to do it?

I am currently working on a project for a customer for which I have to use Maven.
I can check out the project into the workspace, call mvn eclipse:eclipse, use refresh and then run the project.
This is a very convenient way, and I would like to have something similar for Empire-db. But this project has no eclipse project dependencies.

I really don't mind calling one or two maven command from the command line, but I don't like to move files around (as with import project into workspace etc.). 
For Jörg it seems to work, but without the appropriate command in the SVN repository view (which I still could not manage to have it appear) it's very inconvenient to use.
I would be happy if I could check out the individual projects directly and run the maven eclipse:eclipse command.

I am sorry for being so late with my criticism - I really should have evaluated it earlier.

Rainer

> -----Ursprüngliche Nachricht-----
> Von: Francis De Brabandere [mailto:francisdb@gmail.com]
> Gesendet: Freitag, 13. Februar 2009 16:30
> An: empire-db-dev@incubator.apache.org
> Betreff: Re: using Maven
> 
> Hi Rainer,
> 
> the simplest way to get going is not installing an eclipse plugin but
> running the commands as explained in one of my my previous mails.
> 
> mvn eclipse:eclipse -DdownloadSources=true
> (for cleaning up first: mvn clean eclipse:clean eclipse:eclipse
> -DdownloadSources=true)
> 
> after that in eclipse:
> file - import - existing projects into workspace
> 
> select the folder where you checked out the maven branch and click
> finish
> all projects hould be imported and ready for use now.
> 
> the alternative is using m2eclipse plugin or q4e plugin
> I only tested the m2eclipse plugin and if you use that one you can
> skip the eclipse:eclipse command and select import existing maven
> project in the import menu
> 
> and don't install both eclipse maven plugins as that is looking for
> trouble.
> 
> I hope this helps
> 
> On Fri, Feb 13, 2009 at 4:13 PM, Rainer Döbele <do...@esteam.de>
> wrote:
> > Hi Franics,
> >
> > Being a Maven newbe I wonder whether you could give me some advice on
> how to use it.
> >
> > I have both Maven and the Maven Eclipse Plugin installed but unlike
> Jörg I don't have the Option to "Check out as Maven project" within the
> SVN Repository View (for some reason).
> >
> > Now if I check out the entire maven branch into my workspace and call
> "mvn eclipse:eclipse" it reports "build successful".
> >
> > However in the Package Explorer I only have the maven node with its
> subnodes but none of them is marked as a project. Thus I cannot compile
> or run anything. I also have a bin and a target folder but there's not
> much in there.
> >
> > If I only check out an example project (e.g. the empire-db-example)
> and call mvn eclipse:eclipse I get the following error:
> > org.apache.maven.reactor.MavenExecutionException: Cannot find parent:
> org.apache
> > .empire-db:empire-db-examples for project: org.apache.empire-
> db:empire-db-exampl
> > e:jar:2.0.5-SNAPSHOT for project org.apache.empire-db:empire-db-
> example:jar:2.0.
> > 5-SNAPSHOT
> >
> > So what is the recommended way for checking the files out and running
> the examples?
> >
> > Rainer
> >
> >> -----Ursprüngliche Nachricht-----
> >> Von: Francis De Brabandere [mailto:francisdb@gmail.com]
> >> Gesendet: Donnerstag, 12. Februar 2009 23:09
> >> An: empire-db-dev@incubator.apache.org
> >> Betreff: Re: mavenized project
> >>
> >> well depends on what the release dist should look like, it won't be
> >> the same as before
> >>
> >> On Tue, Feb 10, 2009 at 9:43 PM, Rainer Döbele <do...@esteam.de>
> wrote:
> >> > Sounds good.
> >> > Thanks for your evalation Jörg.
> >> > And even more for your work Francis.
> >> >
> >> > So before we merge the maven branch with the trunk is there
> anything
> >> else to consider?
> >> > If not I would call for a vote to merge the branches.
> >> >
> >> > Regards
> >> > Rainer
> >> >
> >> >
> >> > Jörg Reiher wrote:
> >> >> re: mavenized project
> >> >>
> >> >> Hi,
> >> >> I used m2e (just found out it wasn't even the latest release but
> 0.96
> >> (September 2008))
> >> >> I haven't done a big evaluation of the available tools when I
> installed
> >> it, just wanted to > know if there is any working plugin, cause when
> I
> >> worked at a company where Maven was used > (about 1.5 years ago) it
> was a
> >> big pain to keep
> >> >> Eclipse project and Maven in synch... always switching between
> console
> >> and Eclipse, refreshing > the project; now it seems to be much much
> better
> >> - m2e did what I expected, so I didn't bother > trying other
> plugins.
> >> >>
> >> >> Greets
> >> >> jorg
> >> >>
> >> >
> >>
> >>
> >>
> >> --
> >> http://www.somatik.be
> >> Microsoft gives you windows, Linux gives you the whole house.
> >
> 
> 
> 
> --
> http://www.somatik.be
> Microsoft gives you windows, Linux gives you the whole house.

Re: using Maven

Posted by Francis De Brabandere <fr...@gmail.com>.
Hi Rainer,

the simplest way to get going is not installing an eclipse plugin but
running the commands as explained in one of my my previous mails.

mvn eclipse:eclipse -DdownloadSources=true
(for cleaning up first: mvn clean eclipse:clean eclipse:eclipse
-DdownloadSources=true)

after that in eclipse:
file - import - existing projects into workspace

select the folder where you checked out the maven branch and click finish
all projects hould be imported and ready for use now.

the alternative is using m2eclipse plugin or q4e plugin
I only tested the m2eclipse plugin and if you use that one you can
skip the eclipse:eclipse command and select import existing maven
project in the import menu

and don't install both eclipse maven plugins as that is looking for trouble.

I hope this helps

On Fri, Feb 13, 2009 at 4:13 PM, Rainer Döbele <do...@esteam.de> wrote:
> Hi Franics,
>
> Being a Maven newbe I wonder whether you could give me some advice on how to use it.
>
> I have both Maven and the Maven Eclipse Plugin installed but unlike Jörg I don't have the Option to "Check out as Maven project" within the SVN Repository View (for some reason).
>
> Now if I check out the entire maven branch into my workspace and call "mvn eclipse:eclipse" it reports "build successful".
>
> However in the Package Explorer I only have the maven node with its subnodes but none of them is marked as a project. Thus I cannot compile or run anything. I also have a bin and a target folder but there's not much in there.
>
> If I only check out an example project (e.g. the empire-db-example) and call mvn eclipse:eclipse I get the following error:
> org.apache.maven.reactor.MavenExecutionException: Cannot find parent: org.apache
> .empire-db:empire-db-examples for project: org.apache.empire-db:empire-db-exampl
> e:jar:2.0.5-SNAPSHOT for project org.apache.empire-db:empire-db-example:jar:2.0.
> 5-SNAPSHOT
>
> So what is the recommended way for checking the files out and running the examples?
>
> Rainer
>
>> -----Ursprüngliche Nachricht-----
>> Von: Francis De Brabandere [mailto:francisdb@gmail.com]
>> Gesendet: Donnerstag, 12. Februar 2009 23:09
>> An: empire-db-dev@incubator.apache.org
>> Betreff: Re: mavenized project
>>
>> well depends on what the release dist should look like, it won't be
>> the same as before
>>
>> On Tue, Feb 10, 2009 at 9:43 PM, Rainer Döbele <do...@esteam.de> wrote:
>> > Sounds good.
>> > Thanks for your evalation Jörg.
>> > And even more for your work Francis.
>> >
>> > So before we merge the maven branch with the trunk is there anything
>> else to consider?
>> > If not I would call for a vote to merge the branches.
>> >
>> > Regards
>> > Rainer
>> >
>> >
>> > Jörg Reiher wrote:
>> >> re: mavenized project
>> >>
>> >> Hi,
>> >> I used m2e (just found out it wasn't even the latest release but 0.96
>> (September 2008))
>> >> I haven't done a big evaluation of the available tools when I installed
>> it, just wanted to > know if there is any working plugin, cause when I
>> worked at a company where Maven was used > (about 1.5 years ago) it was a
>> big pain to keep
>> >> Eclipse project and Maven in synch... always switching between console
>> and Eclipse, refreshing > the project; now it seems to be much much better
>> - m2e did what I expected, so I didn't bother > trying other plugins.
>> >>
>> >> Greets
>> >> jorg
>> >>
>> >
>>
>>
>>
>> --
>> http://www.somatik.be
>> Microsoft gives you windows, Linux gives you the whole house.
>



-- 
http://www.somatik.be
Microsoft gives you windows, Linux gives you the whole house.