Serious bug in IBCAlerter

Discussion of open issues, suggestions and bugs regarding IBDAC (InterBase Data Access Components) for Delphi, C++Builder, Lazarus (and FPC)
Post Reply
zd
Posts: 78
Joined: Sun 01 Jul 2007 13:16

Serious bug in IBCAlerter

Post by zd » Sat 20 Sep 2008 13:50

I'd like to report a serious bug with IBCAlerter component.

I'm using Delphi7/Firebird 2.1/Windows XP/IBDAC 2.50.0.37

Create a new project in Delphi 7. Drop an IBCConnection on the form, and give the parameters of a test database and set connected to true (so the program autoconnects on startup).

Put an IBCAlert component on the form. Use the following code:

Code: Select all

unit Unit1;

interface

uses
  Windows, Messages, SysUtils, Variants, Classes, Graphics, Controls, Forms,
  Dialogs, IBCAlerter, DB, DBAccess, IBC;

type
  TForm1 = class(TForm)
    IBCConnection1: TIBCConnection;
    IBCAlerter1: TIBCAlerter;
    procedure FormShow(Sender: TObject);
    procedure IBCConnection1Error(Sender: TObject; E: EDAError;
      var Fail: Boolean);
  private
    { Private declarations }
  public
    { Public declarations }
  end;

var
  Form1: TForm1;

implementation

{$R *.dfm}

procedure TForm1.FormShow(Sender: TObject);
var
    I: Integer;
begin
    for I:=0 to 31 do
        IBCAlerter1.Events.Add('Event' + IntToStr(I));

    IBCAlerter1.Start;
end;

procedure TForm1.IBCConnection1Error(Sender: TObject; E: EDAError;
  var Fail: Boolean);
begin
    Fail:=false;
    ShowMessage('Error occured!');
end;

end.
Make sure that the Firebird server the application is connected to is on the same machine.

Launch the application in debug mode.

Now, once the application is running, stop the Firebird server. Here is what happens for me (error messages in order):
---------------------------
Debugger Exception Notification
---------------------------
Project Project1.exe raised exception class EIBCError with message '
unknown ISC error 0'. Process stopped. Use Step or Run to continue.
---------------------------

---------------------------
Debugger Exception Notification
---------------------------
Project Project1.exe raised exception class EIBCError with message '
unknown ISC error 0'. Process stopped. Use Step or Run to continue.
---------------------------

---------------------------
Debugger Exception Notification
---------------------------
Project Project1.exe raised exception class EIBCError with message '
unknown ISC error 0'. Process stopped. Use Step or Run to continue.
---------------------------

---------------------------
Project1
---------------------------
Error occured!
---------------------------

---------------------------
Application Error
---------------------------
Exception EAbort in module Project1.exe at 000CA744.

Operation aborted.
---------------------------

---------------------------
Debugger Exception Notification
---------------------------
Project Project1.exe raised exception class EIBCError with message '
Error writing data to the connection.'. Process stopped. Use Step or Run to continue.
---------------------------

---------------------------
Debugger Exception Notification
---------------------------
Project Project1.exe raised exception class EIBCError with message '
Error writing data to the connection.'. Process stopped. Use Step or Run to continue.
---------------------------

---------------------------
Project1
---------------------------
Error occured!
---------------------------

---------------------------
Application Error
---------------------------
Exception EAbort in module Project1.exe at 000CA744.

Operation aborted.
---------------------------

At this point, the application terminates.
Please note that if I launch the application outside Delphi (without debug mode) the application terminates abnormally by Windows saying that the application had to be closed due to an error.

Please also note that the error occurs if there are many events registered for the IBCAlerter component. If you register 5 events for example, there is no such error. If you register more events, the "Unknown ISC error 0" message appears twice, and for this many events it appears trice!

Please investigate this error and fix it in next IBDAC release.

Thank you!

zd
Posts: 78
Joined: Sun 01 Jul 2007 13:16

Post by zd » Wed 24 Sep 2008 08:51

Any news regarding this?

Plash
Devart Team
Posts: 2844
Joined: Wed 10 May 2006 07:09

Post by Plash » Fri 26 Sep 2008 10:35

We cannot reproduce the problem. In our test only "normal" exceptions raised and the application does not terminate.

Maybe this depends on version of Firebird client library. We have tested with Firebird 2.1.1.17910. Please specify the exact version of your Firebird server and client library.

zd
Posts: 78
Joined: Sun 01 Jul 2007 13:16

Post by zd » Sun 28 Sep 2008 07:52

Dear Plash,

I've sent a compiled test project (with source code) to ibdac at devart.com.

Please check it out.

And yes, I've tested it with Fb2.1.1.17910.

Thank you,
Zd

Plash
Devart Team
Posts: 2844
Joined: Wed 10 May 2006 07:09

Post by Plash » Mon 29 Sep 2008 08:40

We have fixed the problem. Now you will get the error messages "Unknown ISC error" but the program continues running.

zd
Posts: 78
Joined: Sun 01 Jul 2007 13:16

Post by zd » Mon 29 Sep 2008 13:11

Thank you Plash!

Will I get 3 error messages (of unknown isc error) or only 1? Because with a few events now you get one, and with a lot you get 3...

When can you make the new version available for download?

Thanks again!

Plash
Devart Team
Posts: 2844
Joined: Wed 10 May 2006 07:09

Post by Plash » Tue 30 Sep 2008 13:05

You will get several error messages if you have registered a lot of events. When you stop the server, Firebird client notifies IBDAC that some event occurs. If a lot of events are registered, Firebird client sends notifications several times. So you will get several errors.

We are planning to release new IBDAC build with the fix in two weeks.

zd
Posts: 78
Joined: Sun 01 Jul 2007 13:16

Post by zd » Tue 30 Sep 2008 16:04

Thank you Plash, now I understand why multiple events occur.

Is there a change that you could release the new version earlier?

I've developped a commercial application based on IBDAC that I'd need this fix for. Two weeks is a lot of time for my clients...

Thank you!

Plash
Devart Team
Posts: 2844
Joined: Wed 10 May 2006 07:09

Post by Plash » Wed 01 Oct 2008 10:40

Please contact us by e-mail ibdac*devart*com and specify your license number.

zd
Posts: 78
Joined: Sun 01 Jul 2007 13:16

Post by zd » Thu 02 Oct 2008 06:43

E-mail sent, thank you!

Post Reply