I am having some problems trying to work with PostgreSQL and Hibernate, more specifically, the issue mentioned in the title. I\'ve been searching the net for a few hours now
Your JDBC URL is "jdbc:postgresql:postgres/tommy" which is unusual. The documentation suggests "jdbc://hostname/databasename". Modern installations come with a "postgres" database that almost definitely isn't what you want to connect to; I don't know how strict the JDBC driver's URL parsing is.
What are you expecting your database name and hostname to be? e.g. what are your parameters to psql to connect to the database that way?
Tip: in postgresql.conf, some settings you may consider:
log_connections = on
log_disconnections = on
log_line_prefix = '%t %c %q%u@%h:%d '
If the error is what I think (you're connecting to the wrong database), this would log things like the database name along with the error in your postgresql.log file.