[C++] [Windows] Sporadic "Stream removed" errors

56 views
Skip to first unread message

Antoine Pitrou

unread,
May 28, 2019, 11:36:18 AM5/28/19
to grp...@googlegroups.com

Hello,

When trying to run our gRPC unit tests on Windows, I frequently get
spurious errors of the kind:

gRPC failed with error code 2 and message: Stream removed

Our tests are quite simple and do not feature a lot of traffic. They
work flawlessly on Linux. Our only specific settings are:

- GRPC_ARG_ALLOW_REUSEPORT set to 0 on the server
- GRPC_ARG_INITIAL_RECONNECT_BACKOFF_MS set to 100 on the client

Any idea what might cause this? Each unit test spawns a fresh server
on the same TCP port and shuts it down at the end.

Regards

Antoine.


Juanli Shen

unread,
May 29, 2019, 5:18:18 PM5/29/19
to grpc.io
By error code, do you mean https://github.com/grpc/grpc/blob/master/src/core/lib/iomgr/error.h#L125?

If you want to run each unit test on the same port, shouldn't you set GRPC_ARG_ALLOW_REUSEPORT to 1?

I suggest opening a reproducible issue on https://github.com/grpc/grpc/issues.

Antoine Pitrou

unread,
May 30, 2019, 5:05:59 AM5/30/19
to grp...@googlegroups.com

Hi,

On Wed, 29 May 2019 14:18:18 -0700 (PDT)
"'Juanli Shen' via grpc.io" <grp...@googlegroups.com> wrote:
> By error code, do you mean
> https://github.com/grpc/grpc/blob/master/src/core/lib/iomgr/error.h#L125?

No, I mean gRPC::StatusCode
(https://grpc.github.io/grpc/cpp/namespacegrpc.html#aff1730578c90160528f6a8d67ef5c43b)

> If you want to run each unit test on the same port, shouldn't you set
> GRPC_ARG_ALLOW_REUSEPORT to 1?

That didn't change anything. I finally solved the issue by using a
different port on each test. IIRC the semantics of port reuse are
different on Windows compared to POSIX systems.

Regards

Antoine.


Reply all
Reply to author
Forward
0 new messages