Connect to an external database from a Craft 2.x plugin
If only the service will be connecting to it and only one method, then your example works fine.

If only the service will be connecting to, but you use it across multiple methods, then you might want to move the bootstrapping part to the service init() method and save the database connection as a private instance variable in the service so everything in the service can access it.


  Do I need to manually "close" this connection


I wouldn't worry about it.