Page 1 of 1

bug RetryMode:=rmRaise;

Posted: Sat 30 Oct 2010 13:14
by halenpolen
I found a bug

I tried to set RetryMode:=rmRaise; when connection lost. but Tuniconnection still to try connect again. it's happen the first time of connection lost, the second is not happen

procedure TMainForm.ConnectionConnectionLost(Sender: TObject;
Component: TComponent; ConnLostCause: TConnLostCause;
var RetryMode: TRetryMode);
begin
RetryMode:=rmRaise;
end;

Posted: Mon 01 Nov 2010 14:42
by AlexP
Hello,

Please tell me how you checked that TUniConnection tries to connect again after connection loss? I can not reproduce this behaviour.

Posted: Tue 02 Nov 2010 02:58
by halenpolen
[quote="AlexP"]
Please tell me how you checked that TUniConnection tries to connect again after connection loss? [/quote]

i used this demo
Demos\Win32\Miscellaneous\FailOver,

I set RetryMode:=rmRaise

I checked event AfterConnect, the program run this event

procedure TMainForm.ConnectionAfterConnect(Sender: TObject);
begin
btConnect.Enabled := False;
btDisconnect.Enabled := True;
btKillSession.Enabled := True;
end;

Posted: Tue 02 Nov 2010 09:47
by AlexP
Hello,

I can not reproduce the problem.
In the FailOver demo project when I check the Failover checkbox and select 'Raise' in the RetryMode combobox, AfterConnect event doesn't arise after connection loss.
Please check that you really set the following property as
DM.Connection.Options.LocalFailover = true
RetryMode = rmRaise

Posted: Tue 02 Nov 2010 13:43
by halenpolen
AlexP wrote:Hello,

I can not reproduce the problem.
In the FailOver demo project when I check the Failover checkbox and select 'Raise' in the RetryMode combobox, AfterConnect event doesn't arise after connection loss.
Please check that you really set the following property as
DM.Connection.Options.LocalFailover = true
RetryMode = rmRaise
I know the problem, because I set quDetail.Options.LocalMasterDetail:=false;
when I refresh the master,the detail try to refresh too. and Tuniconnetion run Event ConnectionAfterConnect. Although I set RetryMode with rmRaise, How to stop it??

Posted: Thu 04 Nov 2010 10:45
by AlexP
Hello,

I experience such behaviour only if I set the RetryMode variable to the rmReconnect value, if I set it to the rmRaise value the AfterConnect event doesn't arise even if the LocalMasterDetail property is set to false.