Not quite.  There are 2 root users, 'root'@'localhost' and 'root'@%

When you set a root password through the Cloud Console, it only changes the password for 'root'@'%'  

You can use the normal MySQL commands to update the password for 'root'@'localhost'  - you can also create additional mysql users and assign them different permissions - so the username and password should not be hardcoded in the driver.  

When I go back through and document the steps of setting of the CMS on Joomla,  I need to make sure to include steps to:
1) Update the root userid password for ALL connection methods
2) Create the database for Joomla
3) Create a joomla installation userid with admin access to ONLY the Joomla database
4) Create a joomla cms userid with access to the Joomla tables in the Joomla database only

For normal execution, using a userid with limited table access is most secure.