Phalanger 4.0: OutOfMemoryException running wordpress

Discussion about the open-source Phalanger [?] project.

Phalanger 4.0: OutOfMemoryException running wordpress

Postby johnc » April 9th, 2014, 4:34 pm

Running a wordpress request on Phalanger 4.0 is throwing an OOM Exception performing some regex.

I've dumped the stack trace here: http://privatepaste.com/9edf63a2a7

The code in question:

Code: Select all
function remove_accents($string) {
   if ( !preg_match('/[\x80-\xff]/', $string) )
      return $string;


The preg_match is what causes the exception.
Last edited by johnc on April 9th, 2014, 5:35 pm, edited 2 times in total.
johnc
 
Posts: 45
Joined: March 24th, 2013, 9:17 pm

Re: Phalanger 4.0: OutOfMemoryException running wordpress

Postby johnc » April 9th, 2014, 4:44 pm

I disabled the preg to watch the request some more and it hits another OOM Exception on a preg_replace.

Thinking the regex code in Phalanger is a bit memory hungry?
johnc
 
Posts: 45
Joined: March 24th, 2013, 9:17 pm

Re: Phalanger 4.0: OutOfMemoryException running wordpress

Postby Jakub Misek » April 9th, 2014, 10:08 pm

Sadly .NET regular expressions are very slow and memory consuming ... We are planning to use some 3rd party component instead.
Jakub Misek │ DEVSENSE s.r.o. │ Email: jakub@devsense.com
User avatar
Jakub Misek
 
Posts: 2062
Joined: January 4th, 2012, 2:42 pm
Location: Prague

Re: Phalanger 4.0: OutOfMemoryException running wordpress

Postby johnc » April 10th, 2014, 11:21 pm

I wonder what's different now. I remember being able to run Wordpress on Phalanger 3.0 :/

How incredibly frustrating, now that I have the tools to work on my project I can't work on my project.
johnc
 
Posts: 45
Joined: March 24th, 2013, 9:17 pm

Re: Phalanger 4.0: OutOfMemoryException running wordpress

Postby Jakub Misek » April 15th, 2014, 10:25 pm

There were no changes in this area. Maybe the regular expression is different?
Jakub Misek │ DEVSENSE s.r.o. │ Email: jakub@devsense.com
User avatar
Jakub Misek
 
Posts: 2062
Joined: January 4th, 2012, 2:42 pm
Location: Prague

Re: Phalanger 4.0: OutOfMemoryException running wordpress

Postby johnc » May 6th, 2014, 6:26 am

The regex looks fine to me, though WP uses them in a few places.

AFAIK this should be working, it's very disappointing that phalanger can't seem to run a single wordpress request from Visual Studio.

We're also getting System.FormatException's when wordpress tries to run it's cron:

[FormatException: Input string was not in a correct format.]
System.Number.StringToNumber(String str, NumberStyles options, NumberBuffer& number, NumberFormatInfo info, Boolean parseDecimal) +10689507
System.Number.ParseInt32(String s, NumberStyles style, NumberFormatInfo info) +145
System.Int32.Parse(String s) +23
PHP.Library.StreamSocket.SplitSocketAddressPort(String& socket, Int32& port) +200

So far I'm very disappointed by my purchase.
johnc
 
Posts: 45
Joined: March 24th, 2013, 9:17 pm

Re: Phalanger 4.0: OutOfMemoryException running wordpress

Postby Jakub Misek » May 9th, 2014, 11:15 am

Please note, Phalanger is free opensource project; we are helping by fixing bugs reported at phalanger.codeplex.com or github.com/DEVSENSE/Phalanger

We'll take a look at the OOM exception.

Thanks,
Jakub Misek │ DEVSENSE s.r.o. │ Email: jakub@devsense.com
User avatar
Jakub Misek
 
Posts: 2062
Joined: January 4th, 2012, 2:42 pm
Location: Prague

Re: Phalanger 4.0: OutOfMemoryException running wordpress

Postby johnc » May 9th, 2014, 3:29 pm

I wonder if the OOM is actually a simple error and the error reporting is causing an OOM condition.
johnc
 
Posts: 45
Joined: March 24th, 2013, 9:17 pm


Return to Phalanger project

Who is online

Users browsing this forum: No registered users and 2 guests

cron

User Control Panel

Login

Who is online

In total there are 2 users online :: 0 registered, 0 hidden and 2 guests (based on users active over the past 5 minutes)
Most users ever online was 62 on January 7th, 2012, 10:54 pm

Users browsing this forum: No registered users and 2 guests
Phalanger