Michael Schuster writes:
> this is a question about coding style/best practice, not about use.
> 
> According to our plan, the (initial?) implementation of "ilbadm 
> show-statistics" will in fact consist of a thin shim of check 
> arguments-style work in ilbadm, and a ksh script that calls kstat(1M) and 
> does some munging of the output before presenting it to the caller.

Why wouldn't you call the libkstat(3LIB) functions to read the values
directly?

> If we strictly follow the precedent all other ilbadm subcommands have set, 
> we'd have to pass the show-statistics command from ilbadm through libilb 
> into ilbd, which would then fork a process to run the script and pipe the 
> output all the way to the caller. While this is certainly feasible, it 
> looks like a non-trivial amount of overhead that we actually don't need - 
> I'd advocate that ilbadm directly exec() the script in question and be done.
> 
> I'd like to solicit your opinion on whether this sounds like an acceptable 
> approach, and if not, what the objections are.

Sure; that seems reasonable, as long as libilb itself doesn't really
need to be complete.

-- 
James Carlson, Solaris Networking              <james.d.carlson at sun.com>
Sun Microsystems / 35 Network Drive        71.232W   Vox +1 781 442 2084
MS UBUR02-212 / Burlington MA 01803-2757   42.496N   Fax +1 781 442 1677

Reply via email to