Hi all!
At this moment I have a slow connection to my remote database servers (ping to hosts is about 600ms). And when I type an SQL query on the SQL tab I get a lot of frozen autocomplete queries (I see them in the Fiddler). And when I press the button to execute query I get stopped responding UI showing popup "executing..." and for something waiting for a long time (waiting for the second Jesus coming I think) and finally fails with JS error. I temporarily solved this placing the die() operator at first line in db_sql_autocomplete.php but hope to see a more graceful solution.
Thanks.
I hav implemented this request for table name suggestions :
Please check : https://github.com/phpmyadmin/phpmyadmin/pull/1587
Let me know if there should be any changes.
https://github.com/phpmyadmin/phpmyadmin/pull/1589
I was thinking more about a timer than another configuration option. I wonder if we could time the request and cancel the autocomplete interface if it takes longer than...I don't know, a second maybe?
I wonder also if we could optimize this process a bit more and fetch more information in one trip.
So by optimisation you mean to change all the suggestions in query box or just the suggestion for table names?
I'm really just thinking out loud rather than making a broad policy statement or even speaking for the team; these are just my ideas.
I'm not sure about your question, I guess it depends on how heavy traffic or a slow server affect access. I'm curious what other developers think about your patch.
Thanks!
Well i thought it would be better to just give user the one time option to disable the autocomplete.
Thanks for you opinion anyways.
I'll wait for team suggestions and make the necessary changes if needed.
I am in favor of this patch, because autocomplete is really a non-essential feature.
I think the main problem in my case is that my database contain 118 tables and few views. But one view based on very large table with millions of records and old 3.x version of the phpMyAdmin always died by execution timeout when tried to show tables list (in left or center panel). New phpMyAdmin version show tables and views separately so UI work good but autocomplete can fail by the same problem as previous version - trying to obtain info on a view which is too heavy to work with in usual way.
Also, timeout is not a good way because php session will not end and will occupy the local webserver's connections pool and connections limit canbe reached. So, as for me, I think turning autocomplete off at all will be the best solution.
https://github.com/phpmyadmin/phpmyadmin/pull/1601