Bug in V4.1.5.1?

The following code hangs on the last Close operation
this is strange since when I run it via proxy on localhost
(
set a proxy on localhost:88 to tamino:80 and
change the URL to
const String C_DB_URL = “http://localhost:80/tamino/MyDB”;
)
it will then work fine.

const String C_DB_URL = “http://tamino/tamino/MyDB”;
transConnection = new TaminoConnection(C_DB_URL);
transConnection.Open(
TaminoConnectionMode.LocalTransaction,
TaminoIsolationLevel.StableDocument ,
TaminoLockMode.Shared,
TaminoLockwait.No
);

transaction = transConnection.BeginTransaction();
transaction.Rollback();
transConnection.Close();
Console.WriteLine(“First transaction roolback and connection closed”);

transConnection = new TaminoConnection(C_DB_URL);
transConnection.Open(
TaminoConnectionMode.LocalTransaction,
TaminoIsolationLevel.StableDocument ,
TaminoLockMode.Shared,
TaminoLockwait.No
);
transaction = transConnection.BeginTransaction();
transaction.Rollback();
Console.WriteLine(“Second transaction roolback, closing connection…”);
transConnection.Close();
Console.WriteLine(“Second connection closed”);

Why can’t you just use “http://localhost/tamino/mydb” or “http://machine/tamino/mydb” or are you saying that your machine is named “tamino”? My only suspicion would be the communication layer and not the API or Tamino.

  1. The machine name is Tamino.
    2. The same client and server machines runs the above code correctly with the Api4DotNet 4.1.4.2

The following code runs fine for me against a local and a remote Tamino. This is using .NET API 4.1.5.1 as shipped.

Console.WriteLine("DBUrl: "+DBUrl);

for (int i=0 ; i < 50 ; ++i)
{
    connection = new TaminoConnection(DBUrl);

    connection.Open(TaminoConnectionMode.LocalTransaction, TaminoIsolationLevel.StableDocument, TaminoLockMode.Shared, TaminoLockwait.No);

    Console.WriteLine("Opened["+i+"]");

    TaminoTransaction transaction = connection.BeginTransaction();

    transaction.Rollback();
				
    connection.Close();
    Console.WriteLine("Closed["+i+"]");
}



I have seen problems of inexplicable “hangs” when IIS was configured to support “Connection: Keep-Alive” requests.

There were no code changes that should have affected communications. There was some tracing added + performance counters. However, to enable these code paths you need to explicitly request them using configuration files. This means that by default they are disabled.

Note that I am using .NET Framework 1.1 in my environment.

We would like to be able to view a trace file from the TaminoAPI.dll. To be able to do that we would need to send you an appropriate configuration file. Unfortunately, your profile [user name->My Space->Profile] has the selection “I do NOT wish to receive email from the administrators of this bulletin board.” selected which means that nobody can email the configuration file to you. Please don’t publish your email address.

I have changed my profile settings,
and you are most welcome to send me trace configuration file.

Thanks
Ran

Many thanks for the trace files. We have a suspicion of what the problem could be. It looks like a resource problem to us. The “operation timed out” exception appears to happen on a “WebRequest.Create()” call. We suspect that streams are not being closed because object handles are being held for too long or the garbage collector is not being run (e.g. you have a very FAST machine)? What happens if you precede “new TaminoConnection” calls with “GC.Collect()” calls?

My client machine is only 800MHZ.
I have tried adding GC.Collect(); but it didn’t have any effect.

Could you please email the FULL source code of the test program that fails?

Does the program fail from within VS.NET? Command line or another environment?

I am attaching the code and commented out the irelevent parts.

The test program fails in both visual studio and command line.

I think you should take a second look into the fact that the the program worked fine when I was setting it to connect to localhost port 88 and then used a proxy (a utility ‘TcpTrace’) on localhost port 88 to communicate with the tamino server port 80.

Ran
TaminoTransactionTest.cs (7.73 KB)

Is your web server IIS or Apache?

If IIS do you have “Connection: Keep-Alive” turned on?

We are using IIS 5,
Keep alive was on, but disabling it didn’t change anything.

Ran

Please contact customer support and quote problem number 244158. Ask for the test DLL to be provided.