Attribute Naming

David Arnold arnold at dstc.monash.edu.au
Wed Apr 10 15:50:02 EST 2002


i'll comment on these two, since i have spent some thinking time on it
over the years.

   Protocol-Name
   Protocol-Version

my favourite way of doing this at the moment is

   name: version

the benefit of having the name as a field name, rather than a value,
is that you can have multiple standards supported in the same
notification, and you can select using require(), which is more
efficient than a string comparison.

the version is an int32 value calculated like:

   major * 1000 + minor

the advantage of this scheme is that it allows simple checks for known
incompatible versions,

   XXXX >= 1003 && XXXX < 4000

which seems easier than string tests or using floating point values.

an example of this is in the presence protocol,

  Presence-Protocol: 1000

although i tend to prefer less collision-prone format names




d





More information about the ticker-dev mailing list