This should be exposed up through the params->globals layers, so you can set it once forever. That way no matter what operations a user uses, we can tap a variable that points at the default database.

This is also how pe_postgresql works, it sets up the necessary PE specific package defaults so the rest of the postgresql module 'just works'.

I'm wondering though if this even needs to be a server parameter. Remember, validate_db_connection can be used without a server, and so you should be really modifying validate_db_connection to use the passed down 'params' paremeter instead of passing it through later on like you have.

Also - you've added a parameter without updating README.md.