Date: Fri, 29 Jan 1999 17:41:40 -0800 (PST) From: Julian Elischer <julian@whistle.com> To: Archie Cobbs <archie@whistle.com> Cc: Poul-Henning Kamp <phk@critter.freebsd.dk>, net@FreeBSD.ORG Subject: Re: netgraph... Message-ID: <Pine.BSF.3.95.990129172125.17781D-100000@current1.whistle.com> In-Reply-To: <199901292354.PAA01659@bubba.whistle.com>
next in thread | previous in thread | raw e-mail | index | archive | help
On Fri, 29 Jan 1999, Archie Cobbs wrote: > > Poul- > What did you think of the idea of having each node contain two > new methods for encoding and decoding ASCII strings? I say methods > but really they would just understand two new generic message types. > > Then ngctl could send control messages to encode and decode, while > 'normal' control messages between nodes stayed in binary form. The whole idea of asking the kernel to translate a message destined for the kernel makes me feel a little ill. My personal thoughts are: Either the module can just translate it itself, (I'm not sure of argc/argv or just a string), Or maybe it can send out a "format string" type template that allows an interpretter to pack structs to its specifications. e.g. "23=[-A %d.%d.%d.%d]->8:8:8:8" (message 23 is recognosed by the -A flag and wants the following 4 decimal entities packed into 4 8bit fields) A single standard message could deliver all the messages a node is expecting. and we could probably do a better 'language' if we spent more than the 60 seconds I did on this one.. kind of liek an RPC specification, but human->RPC rather than native-binary->RPC. The cost of the interpretter would be born (shared) by all the nodes The first is really simple but I don't really like interpeters in the kernel. The 2nd is not quite as simple (though from the node's point of view it is even simpler), but to my mind is even more elegant. This in addition to other suggestions already made.. julian > > It also respects KISS, by keeping all the node-specific code > together. As I said.. it makes my hair stand on end, but I cant put my finger on the reason. > > -Archie > > ___________________________________________________________________________ > Archie Cobbs * Whistle Communications, Inc. * http://www.whistle.com > To Unsubscribe: send mail to majordomo@FreeBSD.org with "unsubscribe freebsd-net" in the body of the message
Want to link to this message? Use this URL: <https://mail-archive.FreeBSD.org/cgi/mid.cgi?Pine.BSF.3.95.990129172125.17781D-100000>