common/transport: some minor API cleanup, saner address resolving
authorKrisztian Litkey <krisztian.litkey@intel.com>
Mon, 7 May 2012 13:27:49 +0000 (16:27 +0300)
committerKrisztian Litkey <krisztian.litkey@intel.com>
Mon, 7 May 2012 13:27:49 +0000 (16:27 +0300)
commitea28019f6983abd2743f8196809a269db29b5759
treef23e22c3cbcf2db69fe3298774e4a7a962b12089
parent72990c3a8b239027eac575035da6a1c536be7308
common/transport: some minor API cleanup, saner address resolving

There's plenty of things to write and clean up in the transport layer.
For a starter,

1) The message API is not sane. Fields should be tagged by integers
   and not strings. It was a quick hack just to test the transports.
   The basic encoder/decoder needs to be changed to an integer-tagged,
   typed, TLV.

2) We also need unix-domain stream and dgram transports, maybe also IPv6
   TCP and UDP transports. Once we have those, it'd make sense to combine
   (or otherwise consolidate) the connection-oriented and connectionless
   transport code as largely they would end up being identical anyway...
   So IOW IPv4/v6 UDP, unix-domain dgram would share a large part of
   their code, and similarly IPv4/v6 TCP and unix-domain stream would
   share a large part of their code.

3) We need to write a DBUS transport to check if the current abstraction
   is generic enough (or rather how far it is from being generic enough
   and fix any remaining diffs).

4) While we're at it, an SHM-based transport wouldn't hurt either...
src/common/tcp-transport.c
src/common/tests/tcp-test.c
src/common/tests/udp-test.c
src/common/transport.c
src/common/transport.h
src/common/udp-transport.c