Hi everybody
Something is wrong in my JBOSS server.
I've developed a program that uses a mySQL database as follows:
public class C1Bean implements SessionBean {
.........
public int activate(){
try {
Class.forName("com.mysql.jdbc.Driver").newInstance();
}
catch (Exception ex) {
return ( -1);
}
return (0);
}
..........
The imported library is : mysql-connector-java-3.1.7.bin.jar
The program is deployed ok, but when the method is invoked, always returns -1.
If the program is used locally, that is, calling this method locally (no Jboss), the program runs ok.
Does JBOSS run Ok if a database connector is needed?. Do I need to add something else to the JBOSS configuration?
Regards
Pepe
Hi Pepe,
have you put an e.printStackTrace inside the catch to know the exception that is being throwed?
If not, try this, maybe can help you.