Hi Lennart,

I don't know how to test this, probably repeatedly sending notification 
during failover.
The code is quite clear to see the only place that server state changes 
to NTFA_NTFS_NEW_ACTIVE is at switch-case of NTFA_NTFS_NONE.
Can you please help to push this? This bug makes agent bad state since 
agent has no way to get out of NTFA_NTFS_NEW_ACTIVE

Thanks,
Minh

On 30/04/16 00:38, Lennart Lund wrote:
> Ack
>
> But how to test this?
>
> Thanks
> Lennart
>
>> -----Original Message-----
>> From: Minh Hon Chau [mailto:minh.c...@dektech.com.au]
>> Sent: den 27 april 2016 18:52
>> To: Lennart Lund; praveen.malv...@oracle.com
>> Cc: opensaf-devel@lists.sourceforge.net
>> Subject: [PATCH 1 of 1] NTFA: Update server state
>> NTFA_NTFSV_NEW_ACTIVE to NTFA_NTFSV_UP at failover [#1785]
>>
>>   osaf/libs/agents/saf/ntfa/ntfa_util.c |  6 +++++-
>>   1 files changed, 5 insertions(+), 1 deletions(-)
>>
>>
>> If NTF client initializes and sends notification while failover happening, 
>> Agent
>> could possibly update server state as NTFA_NTFSV_NEW_ACTIVE. This
>> server state
>> NTFA_NTFSV_NEW_ACTIVE currently treats as NTFA_NTFSV_UP, but in this
>> scenario
>> server state is udpated as NTFA_NTFSV_NEW_ACTIVE which is not
>> supported in
>> ntfa_update_ntfsv_state() and checkNtfServerState().
>>
>> Patch make sures server state will not dropped into
>> NTFA_NTFSV_NEW_ACTIVE
>>
>> diff --git a/osaf/libs/agents/saf/ntfa/ntfa_util.c
>> b/osaf/libs/agents/saf/ntfa/ntfa_util.c
>> --- a/osaf/libs/agents/saf/ntfa/ntfa_util.c
>> +++ b/osaf/libs/agents/saf/ntfa/ntfa_util.c
>> @@ -1504,7 +1504,11 @@ void ntfa_update_ntfsv_state(ntfa_ntfsv_
>>
>>      switch (ntfa_cb.ntfa_ntfsv_state){
>>      case NTFA_NTFSV_NONE:
>> -            ntfa_cb.ntfa_ntfsv_state = changedState;
>> +            if (changedState ==
>> NTFA_NTFSV_NEW_ACTIVE) {
>> +                    ntfa_cb.ntfa_ntfsv_state =
>> NTFA_NTFSV_UP;
>> +            } else {
>> +                    ntfa_cb.ntfa_ntfsv_state =
>> changedState;
>> +            }
>>              break;
>>      case NTFA_NTFSV_DOWN:
>>              if (changedState == NTFA_NTFSV_NEW_ACTIVE
>> ||


------------------------------------------------------------------------------
Find and fix application performance issues faster with Applications Manager
Applications Manager provides deep performance insights into multiple tiers of
your business applications. It resolves application problems quickly and
reduces your MTTR. Get your free trial!
https://ad.doubleclick.net/ddm/clk/302982198;130105516;z
_______________________________________________
Opensaf-devel mailing list
Opensaf-devel@lists.sourceforge.net
https://lists.sourceforge.net/lists/listinfo/opensaf-devel

Reply via email to