ice icon indicating copy to clipboard operation
ice copied to clipboard

C# Ice/binding Out of memory failure

Open pepone opened this issue 1 year ago • 3 comments

.NET 8 and macOS arm64

testing binding with multiple random endpoints... Out of memory.
Out of memory.
Out of memory.
Out of memory.
-! 22/1/2024 16:04:34:013 client: warning: connection exception:

pepone avatar Jan 22 '24 15:01 pepone

Any other detail to reproduce this failure?

The binding test succeeds and runs fast for me in the same environment.

*** [1/1 loop=197] Running csharp/Ice/binding tests ***
[ running client/server test - 01/26/24 15:07:20 ]
testing binding with single endpoint... ok
testing binding with multiple endpoints... ok
testing binding with multiple random endpoints... ok
testing binding with multiple endpoints and AMI... ok
testing random endpoint selection... ok
testing ordered endpoint selection... ok
testing per request binding with single endpoint... ok
testing per request binding with multiple endpoints... ok
testing per request binding with multiple endpoints and AMI... ok
testing per request binding and ordered endpoint selection... ok
testing per request binding and ordered endpoint selection and AMI... ok
testing endpoint mode filtering... ok
testing ipv4 & ipv6 connections... ok

Ran 1 tests in 0.54 seconds
1 succeeded
*** [1/1 loop=198] Running csharp/Ice/binding tests ***

bernardnormier avatar Jan 26 '24 20:01 bernardnormier

You need --all to reproduce it:

*** [1/1] Running csharp/Ice/binding tests ***
[ running client/server test - 01/26/24 15:08:31 ]
- Config: ssl,mx
testing binding with single endpoint... ok
testing binding with multiple endpoints... ok
testing binding with multiple random endpoints... Out of memory.
Unhandled exception. -! 1/26/2024 15:08:32:658 client: warning: connection exception:
   Ice.ConnectionLostException
       error = 0
      at IceSSL.TransceiverI.finishRead(Buffer buf) in /Users/bernard/builds/ice/csharp/src/IceSSL/TransceiverI.cs:line 194
      at Ice.ConnectionI.finishAsync(Int32 operation) in /Users/bernard/builds/ice/csharp/src/Ice/ConnectionI.cs:line 1114
   local address = 127.0.0.1:51362
   remote address = 127.0.0.1:12010
-! 1/26/2024 15:08:32:660 client: warning: connection exception:
   Ice.ConnectionLostException
       error = 0
      at IceSSL.TransceiverI.finishRead(Buffer buf) in /Users/bernard/builds/ice/csharp/src/IceSSL/TransceiverI.cs:line 194
      at Ice.ConnectionI.finishAsync(Int32 operation) in /Users/bernard/builds/ice/csharp/src/Ice/ConnectionI.cs:line 1114
   local address = 127.0.0.1:51384
   remote address = 127.0.0.1:12024
Ice.ConnectionRefusedException
    error = 0
   at Ice.binding.Test.RemoteObjectAdapterPrxHelper.getTestIntf(OptionalContext context) in /Users/bernard/builds/ice/csharp/test/Ice/binding/msbuild/client/generated/Test.cs:line 487
   at Ice.binding.AllTests.createTestIntfPrx(List`1 adapters) in /Users/bernard/builds/ice/csharp/test/Ice/binding/AllTests.cs:line 64
   at Ice.binding.AllTests.allTests(TestHelper helper) in /Users/bernard/builds/ice/csharp/test/Ice/binding/AllTests.cs:line 257
   at Ice.binding.Client.run(String[] args) in /Users/bernard/builds/ice/csharp/test/Ice/binding/Client.cs:line 17
   at Test.TestDriver.runTest[T](String[] args) in /Users/bernard/builds/ice/csharp/test/TestCommon/TestHelper.cs:line 227
Caused by: System.Net.Sockets.SocketException: Connection refused

unexpected exit status: expected: 0, got 1


test in Ice/binding failed:
unexpected exit status: expected: 0, got 1

bernardnormier avatar Jan 26 '24 20:01 bernardnormier

The issue is caused by: https://github.com/zeroc-ice/ice/blob/ac98b4fcb9979f0709f1524fde28937cc521fe3d/scripts/tests/Ice/binding.py#L17

Without the setrlimit, it works fine.

Despite the comment, it's not clear to me why we set this limit.

bernardnormier avatar Jan 26 '24 22:01 bernardnormier

Fixed in #2520

pepone avatar Aug 05 '24 12:08 pepone