You are viewing a plain text version of this content. The canonical link for it is here.
Posted to users@maven.apache.org by Jochen Wiedmann <jo...@softwareag.com> on 2005/12/14 11:29:06 UTC

Why are jar files rebuilt all the time?

Hi,

this is probably a FAQ. If so, I apologize in advance.

I notice, that jar files are being rebuilt all the time. To me, this has 
serious disadvantages:

- Building the jar file takes time.
- Copying the updated jar file takes more time.
- Rebuilding other files, which include the jar file, takes more time.
... and the cycle continues.

IMO, this is an important point, when comparing Ant and Maven in terms 
of performance. A build with Ant is in most cases exceptionally fast, 
because Ant typically does very little. To Maven, this is a completely 
unknown thing.

Why is this so?


Jochen


---------------------------------------------------------------------
To unsubscribe, e-mail: users-unsubscribe@maven.apache.org
For additional commands, e-mail: users-help@maven.apache.org


RE: Why are jar files rebuilt all the time?

Posted by Jeff Jensen <je...@upstairstechnology.com>.
Thanks  :-)
 

-----Original Message-----
From: Jochen Wiedmann [mailto:jochen.wiedmann@gmail.com] 
Sent: Wednesday, December 14, 2005 8:28 AM
To: Maven Users List
Subject: Re: Why are jar files rebuilt all the time?

On 12/14/05, Jeff Jensen <je...@upstairstechnology.com> wrote:

> Yes, that is the way it is, and I have the same concern but have just 
> lived with it.  Perhaps a jira entry is needed (unless one already
exists).

MNG-1838

--
Often it does seem a pity that Noah and his party did not miss the boat.
(Mark Twain)

---------------------------------------------------------------------
To unsubscribe, e-mail: users-unsubscribe@maven.apache.org
For additional commands, e-mail: users-help@maven.apache.org


---------------------------------------------------------------------
To unsubscribe, e-mail: users-unsubscribe@maven.apache.org
For additional commands, e-mail: users-help@maven.apache.org


Re: Why are jar files rebuilt all the time?

Posted by Jochen Wiedmann <jo...@gmail.com>.
On 12/14/05, Jeff Jensen <je...@upstairstechnology.com> wrote:

> Yes, that is the way it is, and I have the same concern but have just lived
> with it.  Perhaps a jira entry is needed (unless one already exists).

MNG-1838

--
Often it does seem a pity that Noah and his party did not miss the
boat. (Mark Twain)

---------------------------------------------------------------------
To unsubscribe, e-mail: users-unsubscribe@maven.apache.org
For additional commands, e-mail: users-help@maven.apache.org


RE: Why are jar files rebuilt all the time?

Posted by Jeff Jensen <je...@upstairstechnology.com>.
Right, it is not.  That is my scenario as well.  

This solution doesn't work for all use cases, but for the build server...
We use CruiseControl so the core products are only built when CC detects a
source control change.  Therefore the jars only change when the code is
built.

You can also use CC's build dependencies (see <buildstatus>) to trigger the
dependent modules to build when a dependency changes.

Obviously, this does not help any non-CC usage, such as developers.
However, we use the IDE for ongoing development work, so it does not matter.

And this doesn't mean that Maven shouldn't be enhanced... :-)

HTH


-----Original Message-----
From: Jochen Wiedmann [mailto:jochen.wiedmann@gmail.com] 
Sent: Wednesday, December 14, 2005 8:02 AM
To: Maven Users List; ahj@trifork.com
Subject: Re: Why are jar files rebuilt all the time?

On 12/14/05, Anders Hessellund Jensen <ah...@trifork.com> wrote:

> If you only want to compile your sources, try "mvn compile". "mvn 
> test-compile" compiles both main and test. These phases should run 
> pretty fast.

In a multiproject environment this is typically not sufficient, isn't it?

Jochen

--
Often it does seem a pity that Noah and his party did not miss the boat.
(Mark Twain)

---------------------------------------------------------------------
To unsubscribe, e-mail: users-unsubscribe@maven.apache.org
For additional commands, e-mail: users-help@maven.apache.org


---------------------------------------------------------------------
To unsubscribe, e-mail: users-unsubscribe@maven.apache.org
For additional commands, e-mail: users-help@maven.apache.org


Re: Why are jar files rebuilt all the time?

Posted by Jochen Wiedmann <jo...@gmail.com>.
On 12/14/05, Anders Hessellund Jensen <ah...@trifork.com> wrote:

> If you only want to compile your sources, try "mvn compile". "mvn
> test-compile" compiles both main and test. These phases should run
> pretty fast.

In a multiproject environment this is typically not sufficient, isn't it?

Jochen

--
Often it does seem a pity that Noah and his party did not miss the
boat. (Mark Twain)

---------------------------------------------------------------------
To unsubscribe, e-mail: users-unsubscribe@maven.apache.org
For additional commands, e-mail: users-help@maven.apache.org


Re: Why are jar files rebuilt all the time?

Posted by Anders Hessellund Jensen <ah...@trifork.com>.
>>What goal(s) are you running?
> 
> 
> Does that matter? Take "package" for an example.

If you only want to compile your sources, try "mvn compile". "mvn 
test-compile" compiles both main and test. These phases should run 
pretty fast.

Best regards,
Anders

---------------------------------------------------------------------
To unsubscribe, e-mail: users-unsubscribe@maven.apache.org
For additional commands, e-mail: users-help@maven.apache.org


RE: Why are jar files rebuilt all the time?

Posted by Jeff Jensen <je...@upstairstechnology.com>.
It matters to newbies who run "package" or other by default and only want a
compile.

Yes, that is the way it is, and I have the same concern but have just lived
with it.  Perhaps a jira entry is needed (unless one already exists).
 

-----Original Message-----
From: Jochen Wiedmann [mailto:jochen.wiedmann@gmail.com] 
Sent: Wednesday, December 14, 2005 7:46 AM
To: Maven Users List
Subject: Re: Why are jar files rebuilt all the time?

On 12/14/05, Jeff Jensen <je...@upstairstechnology.com> wrote:
> What goal(s) are you running?

Does that matter? Take "package" for an example.


Jochen


--
Often it does seem a pity that Noah and his party did not miss the boat.
(Mark Twain)

---------------------------------------------------------------------
To unsubscribe, e-mail: users-unsubscribe@maven.apache.org
For additional commands, e-mail: users-help@maven.apache.org


---------------------------------------------------------------------
To unsubscribe, e-mail: users-unsubscribe@maven.apache.org
For additional commands, e-mail: users-help@maven.apache.org


Re: Why are jar files rebuilt all the time?

Posted by Jochen Wiedmann <jo...@gmail.com>.
On 12/14/05, Jeff Jensen <je...@upstairstechnology.com> wrote:
> What goal(s) are you running?

Does that matter? Take "package" for an example.


Jochen


--
Often it does seem a pity that Noah and his party did not miss the
boat. (Mark Twain)

---------------------------------------------------------------------
To unsubscribe, e-mail: users-unsubscribe@maven.apache.org
For additional commands, e-mail: users-help@maven.apache.org


RE: Why are jar files rebuilt all the time?

Posted by Jeff Jensen <je...@upstairstechnology.com>.
What goal(s) are you running?
 

-----Original Message-----
From: Jochen Wiedmann [mailto:jochen.wiedmann@softwareag.com] 
Sent: Wednesday, December 14, 2005 4:29 AM
To: Maven Users List
Subject: Why are jar files rebuilt all the time?


Hi,

this is probably a FAQ. If so, I apologize in advance.

I notice, that jar files are being rebuilt all the time. To me, this has
serious disadvantages:

- Building the jar file takes time.
- Copying the updated jar file takes more time.
- Rebuilding other files, which include the jar file, takes more time.
... and the cycle continues.

IMO, this is an important point, when comparing Ant and Maven in terms of
performance. A build with Ant is in most cases exceptionally fast, because
Ant typically does very little. To Maven, this is a completely unknown
thing.

Why is this so?


Jochen


---------------------------------------------------------------------
To unsubscribe, e-mail: users-unsubscribe@maven.apache.org
For additional commands, e-mail: users-help@maven.apache.org


---------------------------------------------------------------------
To unsubscribe, e-mail: users-unsubscribe@maven.apache.org
For additional commands, e-mail: users-help@maven.apache.org