4 ms·
> That is completely unsurprising, attributes suck ass for data, > what would XML-RPC even have used them for? Instead of this: <struct> <member>
by jmillikin 4y ago
> That is completely unsurprising, attributes suck ass for data,
> what would XML-RPC even have used them for?
Instead of this:
<struct>
<member>
<name>faultCode</name>
<value><int>-123</int></value>
</member>
<member>
<name>faultString</name>
<value><string>some fault</string></value>
</member>
</struct>
It could have been:
<struct>
<member name="faultCode"><int>-123</int></member>
<member name="faultString"><string>some fault</string></member>
</struct>
or even:
<struct>
<int name="faultCode">-123</int>
<string name="faultString">some fault</string>
</struct>
--
> An issue which, which very much unfortunate, is not exactly shocking.
> Json would have the same if it had integers in the first place.
XDR (used in Sun RPC) was defined in the '80s and had 64-bit integers. The DEC Alpha line had been out for 5 years or so when XML-RPC was published. It's not like 64-bit integers were unusual at the time.
> Nul is a perfectly valid UTF8 character.
NUL is not permitted in XML documents. The XML-RPC spec's explicit directive to allow NUL puts it at odds with standards-conforming XML parsers.
- ytch 4y agoThis reminds me that Apple's Plist[1] is similar too: <array> <dict> <key>CFBundleTypeName</key> <string>ShapeEditDocument</string> <key>LSHandlerRank</key> <string>Owner</string> <key>LSItemContentTypes</key> <array> <string>com.example.shape-doc</string> </array> </dict> </array> ( Taken from[2] ) Maybe it's common to design XML schema like this at that time? [1] https://en.wikipedia.org/wiki/Property_list https://en.wikipedia.org/wiki/Property_list [2] https://github.com/robovm/apple-ios-samples/blob/1f6b14ef6e2bda610ef8f1c93b16bf76b8594fbb/ShapeEditBuildingaSimpleiCloudDocumentApp/ShapeEdit/Info.plist https://github.com/robovm/apple-ios-samples/blob/1f6b14ef6e2...
- i386 4y agoYou’re absolutely correct. That’s how XML was written in the late 1990s.
- retrocryptid 4y agoMight be useful to look at what we did for the VWRAP abstract type system in the late 2000's. We generally eschewed attributes in XML and defined a subset of XML that could be automagically converted between JSON and a previously defined legacy binary format. I'm certainly not saying this is how you should do things, but it's interesting to look at and has the feature that messages in one format (like XML) could be automagically transmogrified into another (like JSON.) https://datatracker.ietf.org/doc/html/draft-ietf-vwrap-type-system-00 https://datatracker.ietf.org/doc/html/draft-ietf-vwrap-type-...
- no_circuit 4y agoI feel that the complaints about "old tech", like comparing XML-RPC to XDR or the DEC Alpha at the time isn't very helpful, and maybe lacks some context. The specification came out in 1999, which means that people were discussing the spec for months or even years beforehand. Was any Microsoft-associated engineer using a 64-bit computer during that time? Did they even care? It's a guess on my part, but I wouldn't be surprised they couldn't put 64-bit in the spec since their competitors may have had patents in that space, and some tech companies weren't being friendly with each other at the time. Also, messages that look like a HTML web page at the time also could have made it seemingly easier for developers to work with, and be attracted to use a new platform.
- masklinn 4y agoNT ran on Alpha and MIPS R4000, both of which were 64b architectures, though Windows only ran in 32b until XP64 (there was a 64b 2K prototype targeted at Itanium, but since Itanium ended up delayed it was shelved without release).
- jmillikin 4y agoAccording to a post on xml.com[0], development of the spec that would become XML-RPC started in 1998. Microsoft was selling (32-bit) NT for Alpha at that point, and according to Raymond Chen[1] they had an internal 64-bit build of it. I may be dating myself here, but a lot of folks new to the industry seem to think of anything pre-2000 as a dark time full of greyscale CRTs and dot-matrix printers. While those did exist in the home market, academic and business computing (where most of the advanced tech was being developed) was pretty advanced and a modern engineer would have felt right at home on a mid-90s UNIX workstation. If you go back further you'll start encountering things like CORBA, which were pretty bad, but had the legitimate excuse of being very early. Remember that the '90s moved fast by modern standards -- CORBA was contemporary with MS-DOS, while XML-RPC was after IE had dethroned Netscape. [0] https://www.xml.com/pub/a/ws/2001/04/04/soap.html https://www.xml.com/pub/a/ws/2001/04/04/soap.html [1] https://docs.microsoft.com/en-us/previous-versions/technet-magazine/cc718978(v=msdn.10) https://docs.microsoft.com/en-us/previous-versions/technet-m...
- fweimer 4y ago
- baskethead 4y agoAttributes suck when you're trying to write that data into a database. That's the main reason why lots of implementations enforced no attributes, because it made writing that data into a database table very hard.