From mboxrd@z Thu Jan 1 00:00:00 1970 X-Google-Language: ENGLISH,ASCII-7-bit X-Google-Thread: f678f,607935dda9b15b31 X-Google-Attributes: gidf678f,public X-Google-Thread: 111308,607935dda9b15b31 X-Google-Attributes: gid111308,public X-Google-ArrivalTime: 1994-02-08 09:04:21 PST Xref: gmd.de comp.client-server:2424 comp.unix.osf.misc:971 Path: gmd.de!xlink.net!howland.reston.ans.net!vixen.cso.uiuc.edu!sdd.hp.com!think.com!paperboy.osf.org!rsalz From: rsalz@osf.org (Rich Salz) Newsgroups: comp.client-server,comp.unix.osf.misc Subject: Re: DCE Questions. Date: 8 Feb 1994 17:04:21 GMT Organization: Open Software Foundation Message-ID: <2j8gml$fk1@paperboy.osf.org> References: <2ijd6k$69t@news.tamu.edu> NNTP-Posting-Host: sulphur.osf.org Some other folks have answered some of these questions, let me try to give some additional info. >1. Is it possible in DCE RPC to have one piece of code > act as both server and client? Yes, but there is one mildly tricky point. Suppose the IDL file defines an operation foo(). By default, both the client and server stubs will have a routine named foo, but they do different things: the auto-generated client foo() makes the RPC call, while the server stub expects to call the programmer-written foo() routine to do the real work. Linking the "cstub" file into your server will either get "ld: multiply defined" errors at compile-time, or (most likely) infinite recursion at run-time. Use end-point vectors. Easiest thing to do is use the -no_mepv flag on your IDL line. Then you will have to define a global structure that contains function pointers for your server's functions. Use that global in your rpc_register_if() call. (This paragraph is probably too terse and confusing; see the DCE docs.) >2. Is it possible to have same server code running on > different processors/hosts? Sure. You can create an RPC group that contains the names of a set of servers; the import call will pick one server from the group. >3. Finally, can marshaling totally overruled by 'out_of_line' > attributes? Can it by substituted by some other user > defined packing? out_of_line means that rather then doing the marshalling in the stub by calling low-level routines directly, the IDL compiler generates "aux" files that contain subroutines to marshall each data type. So, out_of_line won't do what you want. You might like at the transmit_as attribute, or just pass your data as a conformant array of bytes. /r$