Rob Atkinson ha scritto:

> is there a consensus on how to do this?   currently we are hoping the 
> persistence schema maps directly onto an XML schema type, which is naive 
> and dangerous.
> 
> Generally, we want a separation between the Featuretype (actual model) 
> and the datastore (persistence schema) and the GML (encoding).  The key 
> thing is to allow a FeatureType to have some control over bindings from 
> the persistence layer into the object model, and into the GML encoding.  
> Any time we hardcode an assumption they are one and the same, we are 
> basically introducing a problem.
> 
> IMHO we need:
> 
> Explicit mappings from a FeatureType into the desired type
> Sensible defaults
> Ability to register plug-ins (Type handler libraries) that may add or 
> override defaults

I agree that we need to be able and disconnect from the actual
data structure, but I don't think the problem needs to be fixed in
our current data stores, not in GML encoding.

I see three layers, each with a clear cut responsibility:
* real datastores
* mapping datastore
* GML input/output

A real datastore should provide feature types that closely match the
actual data structures. It should be concerned with correctness and 
speed or data access, given that we do have queries, transactions,
and concurrent access to deal with, it's enough of a job.
Look at our current datastores, they are already quite complex,
no need to add another layer.

GML front is the same, it should not be concerned with mapping,
handling proper GML3 encoding and parsing is already a hell of a job.

A mapping datastore is what we miss. It's a man in the middle whose
sole purpose in live is to map between two views of data, in and out.
Given that mappings can be limited only by your imagination, this
one will have a complex job too.

My work today is only fixing GML encoding and provide enough information 
for the GML layer to properly encode a feature type and its features in 
a consistent and correct way.

Geotools is growing big. We need to tame its complexity by having
clear cut responsibilities, and go for the simplest solution that
can possibly work. The above is the simplest I can imagine. What's 
yours? :-)

Cheers
Andrea

-------------------------------------------------------------------------
Take Surveys. Earn Cash. Influence the Future of IT
Join SourceForge.net's Techsay panel and you'll get the chance to share your
opinions on IT & business topics through brief surveys-and earn cash
http://www.techsay.com/default.php?page=join.php&p=sourceforge&CID=DEVDEV
_______________________________________________
Geotools-devel mailing list
Geotools-devel@lists.sourceforge.net
https://lists.sourceforge.net/lists/listinfo/geotools-devel

Reply via email to