No proper error message when id is missing from app-schema mapping file
-----------------------------------------------------------------------

                 Key: GEOT-3060
                 URL: http://jira.codehaus.org/browse/GEOT-3060
             Project: GeoTools
          Issue Type: Improvement
          Components: data app-schema
            Reporter: Rini Angreani
            Assignee: Rini Angreani
             Fix For: 2.6.4


In app-schema mapping file, top level elements in FeatureTypeMappings required 
to be identified (as they should be a feature type, or non feature types that 
are feature-chained, therefore needs some sort of uniqueness identification). 
This is done by specifying <idExpression> tag on the element.
This is not required if the table being mapped to the type has a primary 
key/unique index, as it will automatically assume them as the id. 
However, users sometimes forget about this requirement, and would encounter 
random errors, such as: IndexOutofBoundException, IllegalStateException or 
NullPointerException.

Only after we debug it, we'd realize that it's a config issue.
Ideally, we should check for id presence, and throw appropriate error message.  

-- 
This message is automatically generated by JIRA.
-
If you think it was sent incorrectly contact one of the administrators: 
http://jira.codehaus.org/secure/Administrators.jspa
-
For more information on JIRA, see: http://www.atlassian.com/software/jira

        

------------------------------------------------------------------------------
_______________________________________________
Geotools-devel mailing list
Geotools-devel@lists.sourceforge.net
https://lists.sourceforge.net/lists/listinfo/geotools-devel

Reply via email to