My web method kept faulting and investigations eventually revealed the following:
The formatter threw an exception while trying to deserialize the message: Error in deserializing body of request message for operation 'SendFirmware'. The maximum array length quota (16384) has been exceeded while reading XML data. This quota may be increased by changing the MaxArrayLength property on the XmlDictionaryReaderQuotas object used when creating the XML reader.
The array in question is a byte[]
containing the firmware image mentioned in the method name. This is why it has so many elements. OK, marvellous, now I know what's wrong, and if I were explicitly managing the XML it wouldn't be a problem. But I'm not, it's all implicit.
How does one set this in the config file for a web service?