473,386 Members | 1,736 Online
Bytes | Software Development & Data Engineering Community
Post Job

Home Posts Topics Members FAQ

Join Bytes to post your question to a community of 473,386 software developers and data experts.

Warning: byte[], [XmlAttribute] and MTOM

Apologies if this is a known issue... I don't know if this is an intentional
feature change, or simply a bug...
but!

I recently upgraded a web service to WSE3, specifically to use MTOM in a
particular call. This worked, however something else unrelated went "snap"
in the process...

After much head-scratching, I identified it as a public byte[] property that
was marked with as [XmlAttribute] - i.e. to be serialized inline with the
containing object-element. Under vanilla .Net WS everything was fine, but
with MTOM enabled this field ceased working - it would be read as 0 instead.
As it happens this represented a database timestamp, so it (oddly enough)
stopped a few things from working.

Changing this property to [XmlElement] and regenerating my proxy class
resolved this; this was the only change.

For ref, the markers in the proxy class changed from:
[System.Xml.Serialization.XmlAttributeAttribute()]
[System.ComponentModel.DefaultValueAttribute(0)]

To
[System.Xml.Serialization.XmlElementAttribute(DataT ype="base64Binary")]

Also note that I generate the proxies via
@"C:\Program Files\Microsoft WSE\v3.0\Tools\WseWsdl3.exe" /edb
/type:webClient /nologo /l:CS /n:%2 /out:%1 %3

(with obvious %1...%3; just included to indicate full calling syntax)

I've resolved it now, so I'm not panicking, but does anybody know if this is
by design? As I wasn't expecting it!!! Normally I would have expected it to
either
work or throw an exception telling me it can't do it (like an int? marked as
[XmlAttribute])...

Marc

Feb 3 '06 #1
1 1933
For ref, I've reported this as bug FDBK45302

Marc
Feb 6 '06 #2

This thread has been closed and replies have been disabled. Please start a new discussion.

Similar topics

3
by: Anita C | last post by:
I have the foll. code to update the value of an attribute: xmlDocument.Load("abc.xml"); XmlAttribute xmlAttrib = xmlDocument.SelectSingleNode(root/web/theme/@desc); xmlAttrib.Value =...
4
by: Ced | last post by:
Hi, i'm not an expert in C but i try to compile BTNG software under linux kernel 2.4.2-2. I get these errors at the very first stage. Does someone could have a rapid look on this and tell me...
1
by: billa1972 | last post by:
Hi, I am trying to hook into Yellow Freight's rating webservice. Below is the wsdl. When i try and create a proxy file with wsdl.exe i get the following errors, see below. Also, when i...
1
by: Michael A Barnhart | last post by:
If there is a more appropriate group to post this in please comment. Given the lack of comments I feel I may not be looking in the correct groups. With the MTOM spec becoming "Offical" then end...
0
by: Tom | last post by:
When I am implementing MTOM in my web service using WSE 3.0. <s:element minOccurs="0" maxOccurs="1" name="buffer" type="s:base64Binary" /> The wsdl generated still refers to my buffer as...
8
by: Default User | last post by:
I'm working on a research and development project involving binary XML. I've been reading lots about the new MTOM and XOP recommendations put out by W3. I'm interested in trying to find a toolset...
7
by: russell.lane | last post by:
I've been looking at both MTOM and simple HTTP POST or PUT for file uploads. Some relevant details: ... We want to support programmatic file uploads from Winform apps. ... The files are large...
1
by: Ollie Riches | last post by:
Hi, I am recieving an exception when adding support for MTOM to a web config file that is using WSE3.0 to talk to a web service. when the following section is added: <messaging> <mtom...
1
by: compurhythms | last post by:
I'm having an issue calling a java-based web service from a C#/.NET 2.0 client that uses WSE 3.0. (No WCF) There is an operation on the web service that takes a single base64 encoded parameter...
0
by: taylorcarr | last post by:
A Canon printer is a smart device known for being advanced, efficient, and reliable. It is designed for home, office, and hybrid workspace use and can also be used for a variety of purposes. However,...
0
by: Charles Arthur | last post by:
How do i turn on java script on a villaon, callus and itel keypad mobile phone
0
by: ryjfgjl | last post by:
In our work, we often receive Excel tables with data in the same format. If we want to analyze these data, it can be difficult to analyze them because the data is spread across multiple Excel files...
0
by: emmanuelkatto | last post by:
Hi All, I am Emmanuel katto from Uganda. I want to ask what challenges you've faced while migrating a website to cloud. Please let me know. Thanks! Emmanuel
0
BarryA
by: BarryA | last post by:
What are the essential steps and strategies outlined in the Data Structures and Algorithms (DSA) roadmap for aspiring data scientists? How can individuals effectively utilize this roadmap to progress...
0
by: Hystou | last post by:
There are some requirements for setting up RAID: 1. The motherboard and BIOS support RAID configuration. 2. The motherboard has 2 or more available SATA protocol SSD/HDD slots (including MSATA, M.2...
0
by: Hystou | last post by:
Most computers default to English, but sometimes we require a different language, especially when relocating. Forgot to request a specific language before your computer shipped? No problem! You can...
0
Oralloy
by: Oralloy | last post by:
Hello folks, I am unable to find appropriate documentation on the type promotion of bit-fields when using the generalised comparison operator "<=>". The problem is that using the GNU compilers,...
0
jinu1996
by: jinu1996 | last post by:
In today's digital age, having a compelling online presence is paramount for businesses aiming to thrive in a competitive landscape. At the heart of this digital strategy lies an intricately woven...

By using Bytes.com and it's services, you agree to our Privacy Policy and Terms of Use.

To disable or enable advertisements and analytics tracking please visit the manage ads & tracking page.