I have a fresh "installation" of yii with a mysql database in the background.
If i want to get the db connection from the app:
$connection = Yii::app()->db;
it needs about 1 second to this.
Is there any trick to speed it up?
I have a fresh "installation" of yii with a mysql database in the background.
If i want to get the db connection from the app:
$connection = Yii::app()->db;
it needs about 1 second to this.
Is there any trick to speed it up?
Debug to find the time used in Connecting to a database.
Test it using WebGrind.
I have tested it takes around 10ms for my case.