JadiraOrg / jadira

Jadira Framework
Apache License 2.0
74 stars 44 forks source link

Use different classname to detect Mutability Detector #53

Closed Grundlefleck closed 8 years ago

Grundlefleck commented 8 years ago

Hi, I'm the author of Mutability Detector. In looking into an issue raised against MD that relates to Jadira cloning I noticed that the presence of MD is determined by checking for the existence of a class, like so:

try {
    Class.forName("org.mutabilitydetector.ThreadUnsafeAnalysisSession");
} catch (ClassNotFoundException e) {

This class has recently been removed (it's now thread safe) so it will always throw a ClassNotFoundException. I'm much less likely to remove Configurations, so this should be a safer check to make.