So before there was a mix of saflog and syslog usage. Upfront errors used was 
logged using syslog and later discovered 
errors logged using saflog. The OK case went to saflog only. TRYAGAIN errors 
was logged in syslog.

So first we should unify on using saflog for all errors, done.

Second include or filter out TRYAGAIN type of errors?

I think you have a point, since they we logged previously we should continue 
doing it.

Which basically leaves the logging of error string from my extra patch:

> +
> +       // log error string separately to maintain some backwards 
> compatibility
> +       saflog(LOG_NOTICE, amfSvcUsrName,
> +                       "Admin op invocation: %llu, err: '%s'", invocation, 
> ao_err_string);
> +
>         saflog(LOG_NOTICE, amfSvcUsrName, "Admin op done for invocation: 
> %llu, result %u",

What do you think?

Thanks,
Hans



On 11/20/2013 09:32 AM, Nagendra Kumar wrote:
> Wont we miss corresponding "try again" result as part of admin request ?
>
> Thanks
> -Nagu
>
> -----Original Message-----
> From: Hans Feldt [mailto:hans.fe...@ericsson.com]
> Sent: 20 November 2013 12:59
> To: Nagendra Kumar; hans.nordeb...@ericsson.com
> Cc: opensaf-devel@lists.sourceforge.net
> Subject: Re: [devel] [PATCH 1 of 1] amfd: Add support for admin op result 
> strings [#85]
>
>
> On 11/20/2013 08:23 AM, Nagendra Kumar wrote:
>> Hi Hans,
>>      Sure. Would you like to combine two saflog into one ?
>
> No, please check my patch. I have 2 logs for two reasons 1) to keep "some" 
> backwards compatibility and 2) not to create
> too long lines in the log.
>
> Example output in saflog:
>
>>          69 07:57:41 11/20/2013 NO safApp=safAmfService "Admin op "UNLOCK" 
>> initiated for 'safSu=SC-2,safSg=2N,safApp=OpenSAF', invocation: 47244640257
>>          70 07:57:41 11/20/2013 NO safApp=safAmfService "Admin op 
>> invocation: 47244640257, err: 'Admin operation (1) has no effect on current 
>> state (1)'
>>          71 07:57:41 11/20/2013 NO safApp=safAmfService "Admin op done for 
>> invocation: 47244640257, result 28
>
> So please review and comment my patch and I will push.
>
> Thanks,
> Hans
>
>>
>> Thanks
>> -Nagu
>> -----Original Message-----
>> From: Hans Feldt [mailto:hans.fe...@ericsson.com]
>> Sent: 20 November 2013 12:34
>> To: Nagendra Kumar; hans.nordeb...@ericsson.com
>> Cc: opensaf-devel@lists.sourceforge.net
>> Subject: Re: [devel] [PATCH 1 of 1] amfd: Add support for admin op result 
>> strings [#85]
>>
>> I can see you have pushed but I have some minor improvements that can give 
>> us problems if not fixed now:
>>
>> 1) the saflog call in report_admin_op_error() needs to be protected so it is 
>> not called when the error code is TRYAGAIN
>>
>> 2) the error string should be logged to saflog, otherwise on case of SMF 
>> doing the admin op there will be nothing logged
>> and troubleshooting will be hard.
>>
>> Patch attached, please review and I can push.
>>
>> Thanks,
>> Hans
>>

------------------------------------------------------------------------------
Shape the Mobile Experience: Free Subscription
Software experts and developers: Be at the forefront of tech innovation.
Intel(R) Software Adrenaline delivers strategic insight and game-changing 
conversations that shape the rapidly evolving mobile landscape. Sign up now. 
http://pubads.g.doubleclick.net/gampad/clk?id=63431311&iu=/4140/ostg.clktrk
_______________________________________________
Opensaf-devel mailing list
Opensaf-devel@lists.sourceforge.net
https://lists.sourceforge.net/lists/listinfo/opensaf-devel

Reply via email to