Initialize the servlet.
try {
// Get a Properties to load from
FileProperties fp = new FileProperties(PROPS_FILE);
// Load the database driver
DRIVER = fp.getProperty("driver");
Class.forName(DRIVER);
// Get the connection
log(getClass() + ": Getting Connection");
Connection conn = DriverManager.getConnection (
fp.getProperty("dburl"),
fp.getProperty("user"),
fp.getProperty("password"));
log(getClass() + ": Creating Statement");
stmt = conn.createStatement();
} catch (IOException ex) {
log(getClass() + ": init: could not load props file " + PROPS_FILE);
} catch (ClassNotFoundException ex) {
log(getClass() + ": init: Could not load SQL driver " + DRIVER);
} catch (SQLException ex) {
log(getClass() + ": init: SQL Error: " + ex);
}