I'm doing a proof-of-concept to try to speed up a data service that accesses DB2 databases and a GeometryService on an ArcGIS server using the ADF and the SOAP API. I'm trying to speed up data access by getting features using a feature service.
The problem I'm running into is that ArcGIS Server's ADF doesn't seem to be able to convert its own data types. I have a PolylineN value object from a FeatureService that I need to convert to the same class for a GeometryService.
The documentation online says to use .NET XML serialization, but the examples only convert a service's value object to an ADF value object, not from ADF to a service's value object or one service to another.
Converting from one service's PolylineN to the other doesn't work. I tried a two-step process, converting from FeatureService.PolylineN to ADF.PolyLineN, then from ADF.PolylineN to GeometryService.PolylineN. On deserializing to GeometryService.PolylineN, I get this error:
System.InvalidOperationException: There is an error in XML document (9, 10). The Inner Exception is the same type, with the message: "The specified type was not recognized: name='PointN', namespace='http://www.esri.com/schemas/ArcGIS/10.0', at ."
According to the documentation, PolylineN is essentially identical in all of these namespaces. So why can't they understand each other's schema?
My workaround is to build a new GeometryService.PolylineN from the feature polyline. It works, but it seems unnecessary to me.
Does anybody have any hints on what I'm missing here?