Java error: java.lang.NoSuchMethodError

The Java runtime reports an error
the postman test reports an error of 500. The exception information is displayed as follows:


reason: first, check whether there is a method of this attribute in the previous class. If so, it is mostly a problem of dependency conflict. In general, it may be that classes with the same package name and class name are introduced. The order in which dependencies are introduced in the POM file of the project is inconsistent, resulting in the use of other people’s classes with the same package and the same name, and there is no corresponding entity class attribute paramscheckresult. An error will be reported in the result. Query the full path name of the class you introduced.

 

Methods:

ProtectionDomain pd = Response.class.getProtectionDomain();
CodeSource cs = pd.getCodeSource();
System.out.println(cs.getLocation().toString());

Print result: the full path name of the imported class will be displayed

Read More: