Before returning service available, make sure port is connectable

Is CREATE EXTENSION postgis idempotent?