FUDforum
Fast Uncompromising Discussions. FUDforum will get your users talking.

Home » FUDforum Development » FUDforum 3.0+ » Compilation of templates under safe_mode
Show: Today's Messages :: Polls :: Message Navigator
Switch to threaded view of this topic Create a new topic Submit Reply
Compilation of templates under safe_mode [message #1535] Thu, 18 April 2002 12:23 Go to next message
basse is currently offline  basse   Finland
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 Go to previous messageGo to next message
Ilia is currently offline  Ilia   Canada
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 Go to previous messageGo to next message
basse is currently offline  basse   Finland
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 #1558 is a reply to message #1553] Thu, 18 April 2002 19:09 Go to previous messageGo to next message
Ilia is currently offline  Ilia   Canada
Messages: 13241
Registered: January 2002
Karma: 0
Senior Member
Administrator
Core Developer
Hmm...

Okie we'll consider those issues once we got our new compiler...


FUDforum Core Developer
Re: Compilation of templates under safe_mode [message #1584 is a reply to message #1558] Fri, 19 April 2002 10:16 Go to previous messageGo to next message
basse is currently offline  basse   Finland
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 Go to previous messageGo to next message
Ilia is currently offline  Ilia   Canada
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 Go to previous messageGo to next message
Ilia is currently offline  Ilia   Canada
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. Twisted Evil

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 #1616 is a reply to message #1612] Sat, 20 April 2002 01:22 Go to previous messageGo to next message
Olliver   Germany
Messages: 443
Registered: March 2002
Karma: 0
Senior Member
Hello Prottoss,
these are great news, since I already was a bit worried, because I have to use safemode at rokopsecurity and the timeout cannot be set (seemed to be restricted by the hoster) so after 30 secs the party would have been over. But this way I can get it to work there Smile The next days I will put up a german alpha board on a different server (luckily without safe mode Smile) so I may provide u with some bug reports if u don't mind Wink
bye
Ken
Re: Compilation of templates under safe_mode [message #1617 is a reply to message #1616] Sat, 20 April 2002 01:27 Go to previous messageGo to next message
Ilia is currently offline  Ilia   Canada
Messages: 13241
Registered: January 2002
Karma: 0
Senior Member
Administrator
Core Developer
Ken Kizaki wrote on Fri, 19 April 2002 9:22 PM

Hello Prottoss,
these are great news, since I already was a bit worried, because I have to use safemode at rokopsecurity and the timeout cannot be set (seemed to be restricted by the hoster) so after 30 secs the party would have been over. But this way I can get it to work there Smile The next days I will put up a german alpha board on a different server (luckily without safe mode Smile) so I may provide u with some bug reports if u don't mind Wink
bye
Ken


Sure, actually if you grab the latest CVS the german msg file needs quite a few translations for text added at various points after you've made the initial translation. So, if you could translate them it would be MUCH appriciated Smile


FUDforum Core Developer
Re: Compilation of templates under safe_mode [message #1622 is a reply to message #1612] Sat, 20 April 2002 05:51 Go to previous messageGo to next message
basse is currently offline  basse   Finland
Messages: 164
Registered: March 2002
Location: Åbo, Finland
Karma: 0
Senior Member
prottoss wrote on Sat, 20 April 2002 1:08 AM

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. Twisted Evil



Evil you... Very Happy

OK. How the heck did you go from 1,5 minutes to 3 second??? Just by dumping the regex?
Re: Compilation of templates under safe_mode [message #1627 is a reply to message #1622] Sat, 20 April 2002 15:12 Go to previous message
Ilia is currently offline  Ilia   Canada
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
  Switch to threaded view of this topic Create a new topic Submit Reply
Previous Topic: How to upgrade?
Next Topic: RC-2
Goto Forum:
  

-=] Back to Top [=-
[ Syndicate this forum (XML) ] [ RSS ]

Current Time: Sun Nov 24 20:17:16 GMT 2024

Total time taken to generate the page: 0.02512 seconds