It is hard to make it clearer; suppose a version 2.0 of some library X got all 
@deprecated methods from 1.0 removed. A clean up. The project could have two 
dependencies that both refer to this library:

P -> A -> X 2.0
  -> B -> X 1.0

If this is resolved, then indeed X 2.0 is included, however B expects the 1.0 
version and may be using a @deprecated method that is no longer present. The 
end project will crash.

Is it possible to tell Maven that 2.0 is not a substitute for 1.0?



On 13-4-2011 13:42, Benson Margulies wrote:
There is perhaps a communications problem here. I don't think this is
about ranges. I suspect that it is about:

   - project g:A version 1 depends on x:y:2.0
   - project g:B version 1 depends on g:A:1 and x:y:1.0

What ends up in the classpath of B? x:y:2.0, I think.


On Wed, Apr 13, 2011 at 7:17 AM, Schrecker, Wolfgang
<wolfgang.schrec...@atosorigin.com>  wrote:
Maybe http://maven.apache.org/enforcer/enforcer-rules/index.html
  could help.

Wolfgang

-----Ursprüngliche Nachricht-----
Von: Jörg Schaible [mailto:joerg.schai...@scalaris.com]
Gesendet: Mittwoch, 13. April 2011 11:55
An: users@maven.apache.org
Betreff: Re: breaking backwards compatibility

Hi Tom,

Tom Eugelink wrote:

   I know Maven version management can be, ah, challenging, so I stick to
   Maven compatible versioning. Maybe not to the deepest level (1.0.0-b01),
   but surely in a very common accepted style (1.0). I am not having any
   problems with Maven using the wrong versions.

My question is with how to tell Maven two releases are no longer
compatible. So if one dependency uses 1.x and the other uses 2.x, and 2.x
is "declared" not backwards compatible to 1.x, then Maven should either:
1. report a build error on a version conflict 2. or include both versions
of the artifact.
What means "not compatible" for a single artifact? If my application only
uses a constant defined in some class, the dependency is only incompatible
if this constant is no longer available, has a different type or a value
that causes a failure situation in my own app.

You can define real incompatibility only from the consumer side. So what
could Maven actually report by default?

- Jörg


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





--------------------------------------------------

Atos Worldline GmbH
Hahnstraße 25
60528 Frankfurt/Main
Germany
Phone: +49 69/6657-1176
Fax:
Mobile:
mailto: wolfgang.schrec...@atosorigin.com
http://www.atosworldline.com

Geschäftsführer: Wolf Kunisch
Aufsichtsratsvorsitzender: Didier Dhennin
Sitz der Gesellschaft: Frankfurt/Main
Handelsregister: Frankfurt/Main HRB 40 417

* * * * * * * * L E G A L    D I S C L A I M E R * * * * * * * *
This e-mail and the documents attached are confidential and intended solely for 
the addressee; it may also be privileged. If you receive this e-mail by error, 
please notify the sender immediately and destroy it. As its integrity cannot be 
secured on the internet, the Atos Origin group liability cannot be triggered 
for the message content. Although the sender endeavours to maintain a computer 
virus-free network, the sender does not warrant that this transmission is 
virus-free and shall not be liable for any damages resulting from any virus 
transmitted.
* * * * * * * * L E G A L    D I S C L A I M E R * * * * * * * *

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




--

*Tom Eugelink*
Senior software engineer
+31 (0)6 - 47 93 85 92
t.eugel...@knowledgeplaza.nl <mailto:t.eugel...@knowledgeplaza.nl>
        *KnowledgePlaza <http://www.knowledgeplaza.nl>*
Sutton 15
7327 AB Apeldoorn
Tel: +31 (0)55 - 526 3887
Fax: +31 (0)55 - 526 3950
i...@knowledgeplaza.nl <mailto:i...@knowledgeplaza.nl>
Disclaimer: The information contained in this message is for the intended 
addressee only and may contain confidential and/or privileged information. If 
you are not the intended addressee, please delete this message and notify the 
sender; do not copy or distribute this message or disclose its contents to 
anyone.








Reply via email to