new AsyncSqlService()
Represents an asynchronous MySQL or PostgreSQL service.
Methods
getConnection(handler)
Returns a connection that can be used to perform SQL operations on. It's important to remember to close the
connection when you are done, so it is returned to the pool.
Parameters:
Name | Type | Description |
---|---|---|
handler |
function | the handler which is called when the JdbcConnection object is ready for use. |
start(whenDone)
Called to start the service
Parameters:
Name | Type | Description |
---|---|---|
whenDone |
function |
stop(whenDone)
Called to stop the service
Parameters:
Name | Type | Description |
---|---|---|
whenDone |
function |