Hi there,
Under WO5.3.3 I had this in my abstract super-component class...
public WOElement template()
{
if ( allowsCustomTemplatingForRequestSite() )
{
WOElement template =
WOComponent.templateWithHTMLString( templateElement( "html" ),
templateElement( "wod" ), null );
if ( template != null )
{
return template;
}
}
return super.template();
}
protected String templateElement( String suffix )
{
<...>
bytes =
ishApplication
().ishResourceManager().bytesForResourceNamed( resourceName,
frameworkName(), null );
try
{
return bytes == null ? "" : new String( bytes, "UTF-8" );
}
catch ( UnsupportedEncodingException e )
{
throw new NSForwardException( "Failed to convert component bytes to
UTF-8 string", e );
}
}
This performed reasonably well. Now, however, under WO5.4
bytesForResourceNamed is a real bottleneck (it appears from
profiling). i.e., if I do
if ( false && allowsCustomTemplatingForRequestSite() ) then things are
really quick, but otherwise very very slow :-/
Any thoughts (Pierre)?? Is anyone doing anything similar with WO5.4?
Thanks.
I realise the above method (WOCOmponent.templateWithHTMLString) is now
deprecated and the underlying mechanism for this has changed
underneath (peaking on the source for WOComponent etc) but the problem
appears to be with the resource manager.
with regards,
--
Lachlan Deck
_______________________________________________
Do not post admin requests to the list. They will be ignored.
Webobjects-dev mailing list ([email protected])
Help/Unsubscribe/Update your Subscription:
http://lists.apple.com/mailman/options/webobjects-dev/archive%40mail-archive.com
This email sent to [email protected]