agwibowo wrote:
Does anyone know what could be happening? These two files are located in the directory where i run the jar file, hence they should be in the classpath.
Seems you don't understand how class loading works...
If build an 'executable' jar and execute it with a command like
java -jar <jarfile>, then your classpath is limited to this jar and what is specified in its meta-inf. Therefore, if your properties and hbm config files are located *outside* of the jar (in the same directory as you say) - they won't be accessible to your application.
Quote:
I did try adding these two files into the actual application jar file, and that worked, however this surely is not the correct method, since they would become uneditable.
As per what I said above - that's the correct way to do it: include them in your jar file.
If you wan't them outside, then don't use such 'executable' jar and start your application the 'normal' way...