Discussion:
[omniORB] logging incoming requests
Michael Kilburn
2009-06-17 11:07:28 UTC
Permalink
Hi,

I was wondering if there is any existing mechanism in omniORB to receive
information about incoming requests
(module::interface::function::arguments)? We have existing logging framework
and would like to log requests in the order they are processed.

I spent 30 mins digging around omniORB code and found smth:

- register *serverReceiveRequest* interceptor

- in interceptor you?ll receve a reference to *
omni::omniInterceptors::serverReceiveRequest_T::info_T* structure that
has *GIOP_S&
giop_s* member

- that might be used to get a lot various pieces of info, among them:

* omniCallDescriptor* calldescriptor()*

- and that structure contains something that looks useful, e.g.:

inline const char* op() const { return pd_op; }

inline _CORBA_Boolean is_oneway() const { return pd_is_oneway; }

etc.
Am I looking in the right direction or there is already something that I can
leverage?
--
Sincerely yours,
Michael.
-------------- next part --------------
An HTML attachment was scrubbed...
URL: http://www.omniorb-support.com/pipermail/omniorb-list/attachments/20090617/54d60029/attachment.htm
Duncan Grisby
2009-07-02 14:36:13 UTC
Permalink
Post by Michael Kilburn
I was wondering if there is any existing mechanism in omniORB to receive
information about incoming requests (module::interface::function::arguments)?
We have existing logging framework and would like to log requests in the order
they are processed.
Have you looked at the traceInvocations and traceInvocationReturns
configuration parameters? They log all calls, and you can override how
the log messages are output.

What that doesn't do is log argument values, because in general you
can't do that if you don't know the types of the arguments.
Post by Michael Kilburn
- register serverReceiveRequest interceptor
[...]

You certainly could use that, and it would allow you to access the
arguments if you cast the call descriptor to the right omniidl-defined
type.

Cheers,

Duncan.
--
-- Duncan Grisby --
-- ***@grisby.org --
-- http://www.grisby.org --
Michael Kilburn
2009-07-06 06:56:44 UTC
Permalink
Hi,
Post by Michael Kilburn
I was wondering if there is any existing mechanism in omniORB to receive
Post by Michael Kilburn
information about incoming requests
(module::interface::function::arguments)?
Post by Michael Kilburn
We have existing logging framework and would like to log requests in the
order
Post by Michael Kilburn
they are processed.
Have you looked at the traceInvocations and traceInvocationReturns
configuration parameters? They log all calls, and you can override how
the log messages are output.
Does not look like it is going to help me -- I need something more than just
dump to stdout. I'll try variant with interceptors...

Thanks!
--
Sincerely yours,
Michael.
-------------- next part --------------
An HTML attachment was scrubbed...
URL: http://www.omniorb-support.com/pipermail/omniorb-list/attachments/20090705/55658c3a/attachment.htm
Peter Klotz
2009-07-06 10:39:29 UTC
Permalink
Hello Michael
Post by Michael Kilburn
Post by Michael Kilburn
I was wondering if there is any existing mechanism in omniORB to
receive
Post by Michael Kilburn
information about incoming requests
(module::interface::function::arguments)?
Post by Michael Kilburn
We have existing logging framework and would like to log requests
in the order
Post by Michael Kilburn
they are processed.
Have you looked at the traceInvocations and traceInvocationReturns
configuration parameters? They log all calls, and you can override how
the log messages are output.
Does not look like it is going to help me -- I need something more than
just dump to stdout. I'll try variant with interceptors...
By using the Tracing API of omniORB you are able to define where you
would like the messages logged.

This text is taken from omniORB.pdf, section 4.2.1:

"Log messages can be sent somewhere other than stderr by registering a
logging function which is called with the text of each log message:"

Regards, Peter.

Loading...