2

Could you tell me how to detect difference between (same) .class files?

I have a java class compilated with Maven2 on my local computer => works good! I jave the same java class compilated with Maven2 on Apache Continuum => doesn't work!

The two class file are the same when i decompilated them! Same size, same code and same byte come (javap -verbose) .... how to detect the difference between them ?

Thank you!

  • 6
    If the classfiles are the same, then the problem is obviously elsewhere. Most likely you have different/missing libraries or a different OS. – Antimony Mar 9 '14 at 2:42
  • Could you give a little more context in regards to what you're looking for? If you ran the command "diff class1.class class2.class it should tell you the first byte where the files differ. – avgvstvs Mar 10 '14 at 20:56
  • I want to know why there is a difference between the class file from my local workspace (target) (compile by maven2) and the class file compile by maven2 by remote apache continuum. I needed to remplace only this class file in the jar to run my app. When decompiling it there is no difference! When decompiling in bytecode there are two little difference! (out of the context of my error) ... I tried to run diff unix command with no really success. Can I send you the bad and the good class files please ? – user1929504 Mar 13 '14 at 17:25
  • What was the output from the diff command? – avgvstvs Mar 19 '14 at 2:47
1

i didnt find differences with the diff command... But I solved the problem... It was from the @Async annotation. The solution was to isolate the @Async method in a new class. Now I can use the .jar archive from my nexus repository. Thank you for your help.

Your Answer

By clicking “Post Your Answer”, you agree to our terms of service, privacy policy and cookie policy

Not the answer you're looking for? Browse other questions tagged or ask your own question.