[Laszlo-dev] Re: serverless operation toplevel attribute

Adam Wolff adam at laszlosystems.com
Wed Jan 19 09:54:17 PST 2005


I can easily accomodate this. I still think that I should be able to 
make media requests bypass the proxy on a request-by-request basis.

Consider the case where I have some gif resources and some jpg 
resources. I need the server to transcode the gifs, but I would 
probably want to bypass the server for the jpgs.

I also think that overloading the 'cache' argument to setSource(and 
renaming it) is the best entry point for this.

Adam

Oliver Steele wrote:
> [Moving to laszlo-dev:]
> 
> On Jan 18, 2005, at 6:39 PM, Henry Minsky wrote:
> 
>> The hack for 'serverless' http data sources right now is that if you
>> construct a dataset with the "transport=direct"  attribute, then
>> LzDataset constructs an anonymous XML datasource as its parent,
>> otherwise it constructs an LzHttpDatasource.
> 
> Here's how to bring this into line with the Compilation Switch+Toplevel 
> Attribute proposal:
> 
> - Add <canvas proxied="false|true|inherit"> to the schema.
> - Add LzCanvas.proxied.  Change CanvasCompiler to initialize this from 
> <canvas proxied>, when it is present.
> - When the application is initialized, if canvas.proxied=='inherit' 
> then set it to true or the value of the lzproxied query parameter.  
> (I'm thinking that the query parameter should be lzproxied instead of 
> proxied, as per "fake query parameter namespaces".)
> - Modify LzDataset.prototype.construct to test for (canvas.proxied || 
> args.transport=='direct').
> 
> Can something similar be done for media requests?
> 
> This implements the parts about libraries, compilation warnings, or 
> debug warnings, but it gets enough of the feature implemented to begin 
> using it.  It also leaves <datasource direct> in the schema; we can 
> remove or rename that once we have a final spec.
> 
>> There is actually at present no LZX tag to construct an
>> LzXMLDatasource from script.
>>
>> This implementation needs to be changed, although, does anyone
>> actually use <datasource> in their code anymore, or do they just
>> declare <dataset> for everything?
>>
>>
>> LzDataset.prototype.construct = function ( parent , args ){
>>     //Default datasource type is http
>>     if (! parent.instanceOf(_root.LzDatasource) ) {
>>         this.oncanvas = parent == _root.canvas || parent == null;
>>         if (args.transport == "direct") {
>>             parent = new _root.LzXMLDatasource( _root.canvas,
>>                 { name: "anonXMLDS" +
>>                   _root.LzDataset.anonDatasourceNum++});
>>         } else {
>>             parent = new _root.LzHTTPDatasource( _root.canvas,
>>                 { name: "anonHTTPDS" +
>>                   _root.LzDataset.anonDatasourceNum++});
>>         }
>>         parent.repset = true;
>>     }
> 
> 
> 
> ------------------------------------------------------------------------
> 
> _______________________________________________
> Laszlo-dev mailing list
> Laszlo-dev at openlaszlo.org
> http://www.openlaszlo.org/mailman/listinfo/laszlo-dev


More information about the Laszlo-dev mailing list