Mapserver Plug-in Infrastructure: RFC and PATCH
Jani Averbach
javerbach at EXTENDTHEREACH.COM
Fri Aug 19 14:22:42 EDT 2005
Hello,
Steve and Frank, thank you for your support for this plug-in idea.
> -----Original Message-----
> [mailto:MAPSERVER-DEV at LISTS.UMN.EDU]On Behalf Of Steve Lime
>
...
> What are some of the benefits and costs associated with the
> approach? Simplification and extensibility for sure, any significant
> performance hit (I wouldn't think so, not relative to making a map)?
As you said, the benefits should be code simplification (for internal
layers) and architecture/API for layer plug-ins.
I haven't done any performance testing with the prototype, but I think
that this vtable solution won't bring any noticeable performance
hit. The layer's vtable is cached in the layerObj, so it will add two
pointer access and a branch (testing if function pointer exists) per
function call. All of this should be insignificant compared to all
else what is going on.
> I like the idea of using the same approach for internal vs. external
> plugins.
I also think it is good thing to do, then we have only one code path
to do the same thing, which is goodness.
> We'd have to take some of the default shapefile code that
> lives in the switch statements and move to properly named functions-
> no biggie, but just another thing to be done.
I have found also few other place which might need some refactoring.
> I dunno about mucking with the build process though which is
> convoluted enough. In theory you could have 2 Oracle Spatial drivers
> available, one internal and one custom.
Yes.
> Couldn't just different names be used for connection type (which is
> used as a lookup in the vtable)?
The problem, as far as I can see it, is that the parser (lexer) is
looking for fixed tokens after "CONNECTIONTYPE" and we are using in
fixed enums for layers around the code. If we fix the lexer, get rid
of non-core layers, and start using generic interfaces for layers
all around the code, then it should be possible to create totally
flexible layer architecture. However this is more complicated
change to do, and maybe not worth as the first step.
> Finally, there really should be a formal RFC (following the WKT
> format) for something of this maginitude.
Yes, I noticed that and I am writing a MS RFC at this very moment.
I used MS RFC2 <http://ms.gis.umn.edu/development/rfc/ms-rfc-2> as a
template/model, and I am also using restructured text as markup. Is
this OK? I hope that I have something ready during this afternoon or
Monday morning.
BR, Jani
--
Jani Averbach
More information about the mapserver-dev
mailing list