Compilation of templates under safe_mode [message #1535] |
Thu, 18 April 2002 12:23 |
|
basse
Messages: 164 Registered: March 2002 Location: Åbo, Finland
Karma: 0
|
Senior Member |
|
|
Just a thought...
The compilation process is quite slow at the moment. On my server it takes about 8 minutes to recompile the forum templates.
Problem is that even though my production server is very much faster, it php runs in safe_mode. One of safe_modes "curses" is that there is a maximum allowed time for a php process. How will this work with the compilation?
[Updated on: Fri, 19 April 2002 10:14] Report message to a moderator
|
|
|
Re: Compilation of templates under safe_mode [message #1539 is a reply to message #1535] |
Thu, 18 April 2002 14:47 |
Ilia
Messages: 13241 Registered: January 2002
Karma: 0
|
Senior Member Administrator Core Developer |
|
|
I am aware that the compilation process is somewhat slow, we intend to optimize the process by 2.0 release.
As for timing out, the compile script includes a set_time_limit(6000); parameter that should prevent the script from timing out.
FUDforum Core Developer
[Updated on: Thu, 18 April 2002 14:47] Report message to a moderator
|
|
|
Re: Compilation of templates under safe_mode [message #1553 is a reply to message #1539] |
Thu, 18 April 2002 18:49 |
|
basse
Messages: 164 Registered: March 2002 Location: Åbo, Finland
Karma: 0
|
Senior Member |
|
|
prottoss wrote on Thu, 18 April 2002 5:47 PM | As for timing out, the compile script includes a set_time_limit(6000); parameter that should prevent the script from timing out.
|
This is exactly the problem. Under safe_mode, the set_time_limit function seems to be disabled (at least this is the case on my server). So, the compilation process will probably not finish.
[Updated on: Fri, 19 April 2002 10:15] Report message to a moderator
|
|
|
|
Re: Compilation of templates under safe_mode [message #1584 is a reply to message #1558] |
Fri, 19 April 2002 10:16 |
|
basse
Messages: 164 Registered: March 2002 Location: Åbo, Finland
Karma: 0
|
Senior Member |
|
|
prottoss wrote on Thu, 18 April 2002 10:09 PM | Hmm...
Okie we'll consider those issues once we got our new compiler...
|
Could it be done like this? You have a php script that compiles say 1/4 of all the templates. This script then starts the next script that will compile another 1/4. And so on. I've seen things like this done in that way elsewhere.
[Updated on: Fri, 19 April 2002 10:17] Report message to a moderator
|
|
|
Re: Compilation of templates under safe_mode [message #1600 is a reply to message #1584] |
Fri, 19 April 2002 15:33 |
Ilia
Messages: 13241 Registered: January 2002
Karma: 0
|
Senior Member Administrator Core Developer |
|
|
Possibly, right now we are working on a new compiler which is entirely regex free. Our ultimate goal would be to get the compilation process <30 seconds thus making sure we won't trigger a timeout.
If that proves impossible, we'll add a workaround, so that compilation is done in sections.
FUDforum Core Developer
|
|
|
Re: Compilation of templates under safe_mode [message #1612 is a reply to message #1600] |
Fri, 19 April 2002 22:08 |
Ilia
Messages: 13241 Registered: January 2002
Karma: 0
|
Senior Member Administrator Core Developer |
|
|
The new compiler has been finally completed. Since I am too lazy to optimize it, you'll have to live with its current speed, which is about
3 seconds
to recompile entire forum on a celeron 433.
It can be optimized further, to 1-2 seconds, but I don't see a reason to spend the time on that.
FUDforum Core Developer
[Updated on: Fri, 19 April 2002 22:12] Report message to a moderator
|
|
|
|
|
|
Re: Compilation of templates under safe_mode [message #1627 is a reply to message #1622] |
Sat, 20 April 2002 15:12 |
Ilia
Messages: 13241 Registered: January 2002
Karma: 0
|
Senior Member Administrator Core Developer |
|
|
correct, we dumped the entire regex and rewrote it from scratch, to use our own tokernizer.
now, the compiler is still being tested and there is 1 problem with it, which occurs on certain forms, but all of this should be fixed by monday.
FUDforum Core Developer
|
|
|