• Open Menu Close Menu
  • Apple
  • Shopping Bag
  • Apple
  • Mac
  • iPad
  • iPhone
  • Watch
  • TV
  • Music
  • Support
  • Search apple.com
  • Shopping Bag

Lists

Open Menu Close Menu
  • Terms and Conditions
  • Lists hosted on this site
  • Email the Postmaster
  • Tips for posting to public mailing lists
Re: Webobjects-dev Digest, Vol 9, Issue 986
[Date Prev][Date Next][Thread Prev][Thread Next][Date Index][Thread Index]

Re: Webobjects-dev Digest, Vol 9, Issue 986


  • Subject: Re: Webobjects-dev Digest, Vol 9, Issue 986
  • From: Ernest Kwesi Agyepong <email@hidden>
  • Date: Wed, 16 Jan 2013 17:41:42 +0000




Sent from my iPhone

On Dec 10, 2012, at 20:00, email@hidden wrote:

Send Webobjects-dev mailing list submissions to
   email@hidden

To subscribe or unsubscribe via the World Wide Web, visit
   https://lists.apple.com/mailman/listinfo/webobjects-dev
or, via email, send a message with subject or body 'help' to
   email@hidden

You can reach the person managing the list at
   email@hidden

When replying, please edit your Subject line so it is more specific
than "Re: Contents of Webobjects-dev digest..."


Today's Topics:

  1. Re: Binary Plist generation very slow (amedeomantica)
  2. Re: Binary Plist generation very slow (Pascal Robert)
  3. Re: Binary Plist generation very slow (Alexander Spohr)
  4. WOComponent Function Call Order (Louis-Olivier Roof)
  5. Re: WOComponent Function Call Order (Alexander Spohr)


----------------------------------------------------------------------

Message: 1
Date: Mon, 10 Dec 2012 12:31:23 +0100
From: amedeomantica <email@hidden>
To: Jesse Tayler <email@hidden>
Cc: WebObjects-Dev List <email@hidden>
Subject: Re: Binary Plist generation very slow
Message-ID: <email@hidden>
Content-Type: text/plain; CHARSET=US-ASCII

The iOS parse is very fast

how much is big your plist ?

What did u put inside ?
Try to lookup what key/value is making it slow

Amedeo

On 06/dic/2012, at 17:37, Jesse Tayler <email@hidden> wrote:


something wrong there? I haven't done tests, that's great to get those digits, how?

my rather short testing some years back suggested that bplist was VERY fast, so I wonder?

keep us posted about what you find please!


On Dec 6, 2012, at 5:16 AM, Alexander Spohr <email@hidden> wrote:

Hi List,

we tried to switch from string based plists to binary ones. The clients love it but it almost kills the servers.

The binary plist generation is 26 times slower (for my test case):
Duration:  2881 ms NSPropertyListOpenStepFormat
Duration: 75008 ms NSPropertyListBinaryFormat_v1_0

Does anyone have a faster binary plist generator at hand before I try to roll my own?

   atze



_______________________________________________
Do not post admin requests to the list. They will be ignored.
Webobjects-dev mailing list      (email@hidden)
Help/Unsubscribe/Update your Subscription:

This email sent to email@hidden


_______________________________________________
Do not post admin requests to the list. They will be ignored.
Webobjects-dev mailing list      (email@hidden)
Help/Unsubscribe/Update your Subscription:

This email sent to email@hidden



------------------------------

Message: 2
Date: Mon, 10 Dec 2012 06:46:35 -0500
From: Pascal Robert <email@hidden>
To: amedeomantica <email@hidden>
Cc: WebObjects-Dev List <email@hidden>
Subject: Re: Binary Plist generation very slow
Message-ID: <email@hidden>
Content-Type: text/plain; charset=iso-8859-1


Le 2012-12-10 à 06:31, amedeomantica <email@hidden> a écrit :

The iOS parse is very fast

He did say that the iOS (client) part is fast, it's the generation of the binary plist on the WO side that is slow.

how much is big your plist ?

What did u put inside ?
Try to lookup what key/value is making it slow

Amedeo

On 06/dic/2012, at 17:37, Jesse Tayler <email@hidden> wrote:


something wrong there? I haven't done tests, that's great to get those digits, how?

my rather short testing some years back suggested that bplist was VERY fast, so I wonder?

keep us posted about what you find please!


On Dec 6, 2012, at 5:16 AM, Alexander Spohr <email@hidden> wrote:

Hi List,

we tried to switch from string based plists to binary ones. The clients love it but it almost kills the servers.

The binary plist generation is 26 times slower (for my test case):
Duration:  2881 ms NSPropertyListOpenStepFormat
Duration: 75008 ms NSPropertyListBinaryFormat_v1_0

Does anyone have a faster binary plist generator at hand before I try to roll my own?

   atze



_______________________________________________
Do not post admin requests to the list. They will be ignored.
Webobjects-dev mailing list      (email@hidden)
Help/Unsubscribe/Update your Subscription:

This email sent to email@hidden


_______________________________________________
Do not post admin requests to the list. They will be ignored.
Webobjects-dev mailing list      (email@hidden)
Help/Unsubscribe/Update your Subscription:

This email sent to email@hidden

_______________________________________________
Do not post admin requests to the list. They will be ignored.
Webobjects-dev mailing list      (email@hidden)
Help/Unsubscribe/Update your Subscription:

This email sent to email@hidden




------------------------------

Message: 3
Date: Mon, 10 Dec 2012 15:43:42 +0100
From: Alexander Spohr <email@hidden>
To: WebObjects-Dev List <email@hidden>
Subject: Re: Binary Plist generation very slow
Message-ID: <email@hidden>
Content-Type: text/plain; charset=windows-1252

Never use dicts or arrays as a hashtable’s keys!

I removed the uniquing of dicts, arrays and sets. I now use an int based hash table with object.hashCode() as the key. My binary property list generation is now faster than the string based version.

The test file is a 11MB string based property list, run over a 100 times each.
Duration: 15805ms NSPropertyListOpenStepFormat
Duration: 10084ms NSPropertyListBinaryFormat_v1_0

If java could provide the address of an object I would use that and unique the collections again. The address would be a nice hash key. Unfortunately you don’t get addresses in Java and the hashCode() of collections are unusable.

   atze


Original file (contains lots of spaces):
-rw-r--r--@  1 atze  atze  11786993  9 Dez 18:35 3500Attacks.plist

Binary:
-rw-r--r--   1 atze  atze   1270690 10 Dez 15:39 3500Attacks.plistb

Reverse test to ensure both (string & binary) generate the same output (using tabs instead of spaces):
-rw-r--r--   1 atze  atze   6819317 10 Dez 15:39 3500Attacks.plistx
-rw-r--r--   1 atze  atze   6819317 10 Dez 15:39 3500Attacks.plisty




Am 06.12.2012 um 11:16 schrieb Alexander Spohr <email@hidden>:

Hi List,

we tried to switch from string based plists to binary ones. The clients love it but it almost kills the servers.

The binary plist generation is 26 times slower (for my test case):
Duration:  2881 ms NSPropertyListOpenStepFormat
Duration: 75008 ms NSPropertyListBinaryFormat_v1_0

Does anyone have a faster binary plist generator at hand before I try to roll my own?

   atze



------------------------------

Message: 4
Date: Mon, 10 Dec 2012 13:41:20 -0500
From: Louis-Olivier Roof <email@hidden>
To: WebObjects Development <email@hidden>
Subject: WOComponent Function Call Order
Message-ID: <email@hidden>
Content-Type: text/plain; charset="iso-8859-1"

Hello WebObjects community, this is my first question so don't be too hard on me ;)

Lets say I have a wo:loop  in a component...

    <wo:loop list = "$dg.displayedObjects" item = "$aItem">
       <tr>
         <td> <wo:string value = "$~timeConsumingCallA()" /> </td>
         <td> <wo:string value = "$~timeConsumingCallB()" /> </td>
<td> <wo:string value = "$~callDependingOn_A_and_B()" /> </ td>
       </tr>
     </wo:loop>

Functions timeConsumingCallA() and timeConsumingCallB() are, as their name imply, costly calls. Function callDependingOn_A_and_B() depends on the results of the two first functions.

Is there any guarantee that the two function calls (timeConsumingCallA, timeConsumingCallB) will always be called in order and before callDependingOn_A_and_B() so I can set and depend on instance variables $timeConsumingCallA_result and $timeConsumingCallB_result in the callDependingOn_A_and_B() function?

If not, I can see a number of ways I could myself make sure the calls are made in the correct order in straight-Java, but I was wondering if there was a "Wonder/WebObjects" strategy to approach this.

Thanks for your time,

--
Louis-Olivier Roof, Eng.
Software Engineer
Obzerv Technologies Inc.
400, Jean-Lesage, suite 201,
Québec (Québec)
Canada, G1K 8W1
T. (418) 524-3522
F. (418) 524-6745
www.obzerv.com

-------------- next part --------------
An HTML attachment was scrubbed...
URL: <http://lists.apple.com/archives/webobjects-dev/attachments/20121210/7d168598/attachment.html >

------------------------------

Message: 5
Date: Mon, 10 Dec 2012 20:01:41 +0100
From: Alexander Spohr <email@hidden>
To: Louis-Olivier Roof <email@hidden>
Cc: WebObjects Development <email@hidden>
Subject: Re: WOComponent Function Call Order
Message-ID: <email@hidden>
Content-Type: text/plain; charset=windows-1252

WO runs from to to bottom of your page. So it should work.

A better way would be to do the calculations in appendToResponse() before you call super. Then all will be set before the page is rendered. If you can not do that because of your loop, you could do it in the displayedObjects call. Or in a method that calls displayedObjects and returns after your calculation for this item.

   atze


Am 10.12.2012 um 19:41 schrieb Louis-Olivier Roof <email@hidden >:

Hello WebObjects community, this is my first question so don't be too hard on me ;)

Lets say I have a wo:loop  in a component...

    <wo:loop list = "$dg.displayedObjects" item = "$aItem">
       <tr>
         <td> <wo:string value = "$~timeConsumingCallA()" /> </td>
         <td> <wo:string value = "$~timeConsumingCallB()" /> </td>
<td> <wo:string value = "$~callDependingOn_A_and_B()" /> </ td>
       </tr>
     </wo:loop>

• Functions timeConsumingCallA() and timeConsumingCallB() are, as their name imply, costly calls. • Function callDependingOn_A_and_B() depends on the results of the two first functions.

Is there any guarantee that the two function calls (timeConsumingCallA, timeConsumingCallB) will always be called in order and before callDependingOn_A_and_B() so I can set and depend on instance variables $timeConsumingCallA_result and $timeConsumingCallB_result in the callDependingOn_A_and_B() function?

If not, I can see a number of ways I could myself make sure the calls are made in the correct order in straight-Java, but I was wondering if there was a "Wonder/WebObjects" strategy to approach this.

Thanks for your time,




------------------------------

_______________________________________________
Webobjects-dev mailing list
email@hidden
https://lists.apple.com/mailman/listinfo/webobjects-dev

End of Webobjects-dev Digest, Vol 9, Issue 986
**********************************************

_______________________________________________
Do not post admin requests to the list. They will be ignored.
Webobjects-dev mailing list      (email@hidden)
Help/Unsubscribe/Update your Subscription:

This email sent to email@hidden


  • Prev by Date: Re: ERMODInspectPage and ERMODWizardCreationPage differences?
  • Next by Date: Unable to create page 'Main'
  • Previous by thread: Re: A fatal exception occurred: Bad version number in .class file
  • Next by thread: Unable to create page 'Main'
  • Index(es):
    • Date
    • Thread