Network Tables Rev. 2.0 Questions

Hi! I was reading the Network Tables Protocol Specification (Revision 2.0), and I have a few questions about things that seem vague or missing from the document, if anyone could possibly answer them.

  1. Once an entry is created, can it be removed, or does it persist for the life of the server?
  2. If a server sends an Entry Assignment message to a client whose local network table already contains the ID, what is the client expected to do? Drop the request? Replace the existing entry?
  3. Can the length of arrays of values change?
  4. Is there a maximum length to arrays?

Thanks a bunch!

  1. There is no delete. It actually persists if the server or a client holds onto the value.
  2. I agree that the spec is loose. I chose to reassign and let the latest win. This can even happen with updates.
  3. Yes
  4. The LV implementation seems to limit it to 255 elements. This is done at the update transfer. So local arrays could technically be larger, but wouldn’t transfer to the other client/server(s). Similarly, string size is limited to a two byte integer.

Greg McKaskle

Cool, thanks!

Alright, one more question. Can there be multiple entries with the same name?

I don’t believe that should happen. LV looks up the fully qualified name in the map and retrieves the field ID. If we wanted, we could add the type to the name and allow for a number, a Boolean, and a String with the same name. My interp of the spec was that if the name matches, it can change type and value and it would be better to have only one field with a given name. I can’t speak as confidently of the Java implementation.

Greg McKaskle

It was meant more as a question of the spec, not a specific implementation (as I’m in the process of writing my own implementation). But it does seem unreasonable to have two entries with the same name.

Hah, so much for there only being one more question. If a client receives an Entry Update or Entry Assignment message with a sequence number less than the sequence number it has recorded, is it supposed to just drop it? I know a server ought to, but I’m not sure about a client.

I know how it goes. I must have asked the WPI folks twenty questions while implementing the LV one. And I’m typically telling you what the implementation does because honestly it is quicker for me to read than the spec.

So, in the same vein, for the LV implementation, the client takes the value update from the server no matter what, but the server takes client updates only if they have a newer seq#. Local updates increment the sequence number and protocol updates don’t. The assignments are basically the same, but they don’t ever increment.

Greg McKaskle