Open crimsonskyrem opened 2 years ago
I read this relative snippet in src/Builder/Component/Model.php:166 Now I figured out that whole schema scan mainly serves to find relations of the table which need to be generated So I was considering to add some options like "--no-relation" to skip this whole schema scan ? Is this solution acceptable ?
Expected and Actual Behavior
when I run phalcon to generate some model , like user_table in my database:
it will stuck in output and no more message
I check the database , SHOW_PROCESSLIST shows the process are checking some other tables,
then this sql goes again to generate the model
since my database has 800+ tables, it always take a long time to generate one model
I have no idea what is this scan running for, but when I generate only one model , it should scan only this table ?
Details
Phalcon DevTools (4.2.0)
Environment: OS: Linux debox 4.19.0-17-amd64 #1 SMP Debian 4.19.194-3 (2021-07-18) x86_64 PHP Version: 7.3.31-1+0~20210923.88+debian10~1.gbpac4058 PHP SAPI: cli PHP Bin: /usr/bin/php7.3 PHP Extension Dir: /usr/lib/php/20180731 PHP Bin Dir: /usr/bin Loaded PHP config: /etc/php/7.3/cli/php.ini
Versions: Phalcon DevTools Version: 4.2.0 Phalcon Version: 4.1.2 AdminLTE Version: 3.0.1
Server: Nginx
Other related info (Database, table schema): Mysql5.7