Aynı anda birkaç Python komut dosyalarını yürütmek php / apache askıda kalmasına neden olur?

0 Cevap php

Benim web som görüntüleri işlemek amacıyla birkaç python komut dosyalarını çalıştırmak için çalışıyorum. Harici program / aracı Python ile yazılmış ve PHATCH denir. Windows altında söyliyim benim webserver olarak WAMP kullanarak değilim.

Ancak, yürütme sadece tek bir script iyi iş gibi görünüyor, ama ben aynı anda 4 komut (4 farklı görüntüler oluşturmak için) yürütmek gerekiyor, ve ben bu yüzden benim tarayıcı sadece yük olacak ve ne zaman apache / php donuyor ... Ve Ive sorunun ne olduğunu anlamaya çalışın her şeyi denedim ama sorun aslında daha ne, herhangi bir çözüm yok bulamıyorum?

Php yürütme dondurma gibi görünüyor ve nedeniyle birkaç sistemini kapattı () birbirinden sonrası çağırır. İşte ben bunu kullanıyorum nasıl bir örnek:

system("C:\\python\\python.exe C:\\phatch\\phatch.py script1.phatch");
system("C:\\python\\python.exe C:\\phatch\\phatch.py script2.phatch");
system("C:\\python\\python.exe C:\\phatch\\phatch.py script3.phatch");
system("C:\\python\\python.exe C:\\phatch\\phatch.py script4.phatch");

If I would only do the first one, its fine, but as soon as I add the others, it all freezez \: And I've searched through the manual/google for hours but haven't found anything that solves it. Maybe I should structure it in another way? I don't know, thereof this question.

Eğer ortak bir sorunu yaşadım Yani, repond lütfen! Şimdiden teşekkürler.

0 Cevap