-
Notifications
You must be signed in to change notification settings - Fork 29
New issue
Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.
By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.
Already on GitHub? Sign in to your account
Finer-grained ignore patterns #23
Comments
I think we'd happily accept any contribution (with tests) making this more flexible, but I'm not sure that the committers have time to work on it ourselves right now. I would happily help shepherd a PR, though! |
I will try to do that--thanks! What is a PR? |
Pull request, nothing more than GitHub's fancy UI over a branch you create with your changes. |
Face. Palm. I know what a pull request is, just didn't associate the abbreviation. |
The changes that I made in this PR: #16 Should be able to do what you want. |
mbellomo, can you give an example of how a regex would be used to say com.foo.bar.Baz is allowed to be a duplicate in jar-1 and jar-2, but not in any other JARs? |
We tend to use it like this (which is why I wrote the changes):
I don't care if we have duplicate classes from jars that aren't ours...as long as the content matches. We are mostly concerned w/ our stuff. That might not be exactly what you want given that latest comment though. -Michael |
There is #16 merged a long time ago and this thread has gone quiet, so I assume that what is in duplicate finder now is good enough. Closing this thread, please reopen if necessary |
Often duplicates exist between two JARs and those duplicates need to be ignored, but it is not desirable to ignore either JAR entirely. We just want to ignore their mutual dependencies, while still catching other duplications (for example, a third JAR that introduces unwanted duplicates between it and the two JARs with allowed duplicates).
In our homegrown duplicate finder, we can define JAR-to-JAR whitelisted pairs, and also class-to-JAR whitelisted pairs.
For example:
Whitelisted JAR pairs:
jre/lib/rt.jar:
----rt/lib/endorsed/webservices-api-2.0.1.jar
----rt/tomcat/lib/tomcat-annotations-api-7.0.39.jar
----rt/tomcat/shared/lib/webservices-extra-2.0.1.jar
----rt/tomcat/shared/lib/webservices-rt-2.0.1.jar
rt/lib/endorsed/webservices-api-2.0.1.jar:
----jre/lib/rt.jar
rt/tomcat/lib/tomcat-annotations-api-7.0.39.jar:
----jre/lib/rt.jar
----rt/tomcat/shared/lib/webservices-extra-2.0.1.jar
Whitelisted class/JAR pairs:
com.intuit.ims.shared.enums.ImsOffering:
----rt/lib/ims-shared-1.0.14-SNAPSHOT.jar
----rt/lib/ipsaccount-3.2.0-rel-0.jar
javax.transaction.TransactionRequiredException:
----jre/lib/rt.jar
----rt/lib/jboss-transaction-api-1.0.1.GA.jar
javax.transaction.TransactionRolledbackException:
----jre/lib/rt.jar
----rt/lib/jboss-transaction-api-1.0.1.GA.jar
org.aspectj.internal.lang.reflect.StringToType:
----rt/lib/aspectjrt-1.7.4.jar
----rt/lib/aspectjtools-1.8.4.jar
----rt/lib/aspectjweaver-1.8.4.jar
org.bouncycastle.jcajce.DefaultJcaJceHelper:
----rt/lib/bcmail-jdk16-1.46.jar
----rt/lib/bcprov-jdk15on-1.49.jar
We want to replace our homegrown duplicate finder with duplicate-finder-maven-plugin, but don't want to give up the fine-grained ignore controls.
The text was updated successfully, but these errors were encountered: