thrift-dev mailing list archives

Site index · List index
Message view « Date » · « Thread »
Top « Date » · « Thread »
From "James E. King III (JIRA)" <j...@apache.org>
Subject [jira] [Commented] (THRIFT-4405) Proper use of sequence IDs in all clients and servers
Date Mon, 28 Jan 2019 05:44:00 GMT

    [ https://issues.apache.org/jira/browse/THRIFT-4405?page=com.atlassian.jira.plugin.system.issuetabpanels:comment-tabpanel&focusedCommentId=16753713#comment-16753713
] 

James E. King III commented on THRIFT-4405:
-------------------------------------------

Finally I have some data on this... I modified the cpp language ProtocolEventHandler and the
TestServer for cpp to check and make sure that it does not get the same two sequence IDs in
a test run.  Many failures.  Many languages are sending zero or duplicates:
{noformat}
Mon Jan 28 05:40:47 2019
===============================================================================
server-client:          protocol:         transport:               result:
cpp-cl                  binary            buffered-ip              success
cpp-c_glib              binary            buffered-ip              failure(-13)
cpp-d                   binary            buffered-ip-ssl          success
cpp-d                   binary            buffered-ip              success
cpp-go                  binary            buffered-ip-ssl          success
cpp-go                  binary            buffered-ip              success
cpp-java                binary            buffered-ip              success
cpp-java                binary            buffered-ip-ssl          success
cpp-nodejs              binary            buffered-ip-ssl          success
cpp-nodejs              binary            buffered-ip              success
cpp-hs                  binary            buffered-ip              failure(1)
cpp-py                  binary            buffered-ip-ssl          failure(1)
cpp-py                  binary            buffered-ip              failure(1)
cpp-py3                 binary            buffered-ip-ssl          failure(1)
cpp-py3                 binary            buffered-ip              failure(1)
cpp-cpp                 binary            buffered-ip-ssl          failure(-6)
cpp-cpp                 binary            buffered-ip              failure(-6)
cpp-c_glib              binary            buffered-ip-ssl          failure(timeout)
cpp-rb                  binary            buffered-ip-ssl          failure(1)
cpp-rb                  binary            buffered-ip              failure(1)
cpp-csharp              binary            buffered-ip-ssl          failure(64)
cpp-csharp              binary            buffered-ip              failure(64)
cpp-perl                binary            buffered-ip-ssl          failure(255)
cpp-perl                binary            buffered-ip              failure(255)
cpp-php                 binary            buffered-ip              failure(255)
cpp-netcore             binary            buffered-ip              success
cpp-netcore             binary            buffered-ip-ssl          success
cpp-erl                 binary            buffered-ip-ssl          failure(1)
cpp-erl                 binary            buffered-ip              failure(1)
cpp-rs                  binary            buffered-ip              success
cpp-lua                 binary            buffered-ip              failure(1)
cpp-nodets              binary            buffered-ip              success
cpp-dart                binary            buffered-ip              success
===============================================================================
*** Following 19 failures were unexpected ***:
If it is introduced by you, please fix it before submitting the code.
===============================================================================
server-client:          protocol:         transport:               result:
cpp-c_glib              binary            buffered-ip              failure(-13)
cpp-hs                  binary            buffered-ip              failure(1)
cpp-py                  binary            buffered-ip-ssl          failure(1)
cpp-py                  binary            buffered-ip              failure(1)
cpp-py3                 binary            buffered-ip-ssl          failure(1)
cpp-py3                 binary            buffered-ip              failure(1)
cpp-cpp                 binary            buffered-ip-ssl          failure(-6)
cpp-cpp                 binary            buffered-ip              failure(-6)
cpp-c_glib              binary            buffered-ip-ssl          failure(timeout)
cpp-rb                  binary            buffered-ip-ssl          failure(1)
cpp-rb                  binary            buffered-ip              failure(1)
cpp-csharp              binary            buffered-ip-ssl          failure(64)
cpp-csharp              binary            buffered-ip              failure(64)
cpp-perl                binary            buffered-ip-ssl          failure(255)
cpp-perl                binary            buffered-ip              failure(255)
cpp-php                 binary            buffered-ip              failure(255)
cpp-erl                 binary            buffered-ip-ssl          failure(1)
cpp-erl                 binary            buffered-ip              failure(1)
cpp-lua                 binary            buffered-ip              failure(1)
===============================================================================
{noformat}

> Proper use of sequence IDs in all clients and servers
> -----------------------------------------------------
>
>                 Key: THRIFT-4405
>                 URL: https://issues.apache.org/jira/browse/THRIFT-4405
>             Project: Thrift
>          Issue Type: Improvement
>          Components: Test Suite
>    Affects Versions: 0.10.0
>         Environment: docker ubuntu-xenial
>            Reporter: James E. King III
>            Assignee: James E. King III
>            Priority: Major
>
> Create a feature test that verifies sequence numbers are used properly.  Write a server
that verifies clients are generating unique sequence IDs.  Write a client that makes sure
servers return the same sequence ID that was given.
> To do this, I enhanced the C++ TProcessorEventHandler class to include a preReadSeq,
which is like preRead but carries the sequence ID.
> In the C++ TestServer, I check to see if the sequence numbers are unique and do not repeat;
if any of them do, the cpp test fails.
> The following languages properly send sequence IDs (for the binary protocol):
> * dart
> * go
> * nodejs
> * java
> * rs
> The rest of the languages do not.  Now, one could argue that unless a language has a
concurrent-safe client and server, sequence IDs are unnecessary.  While that is true, all
languages should respect that the protocol has a sequence ID and there could be future implementations
that will require all clients are well-behaved, which is why I am putting this test in.
> Languages fixed up so unique sequence IDs are sent by the client, and verified by the
tests:
> * cpp (was only sending unique sequence IDs for Concurrent clients, now it does for the
regular one too)
> * csharp (seqid_ was not bring incremented with each use)
> * lua (seqid_ was not bring incremented with each use)
> * perl (seqid_ was not bring incremented with each use)
> * ruby (seqid_ was not bring incremented with each use and a unit test was updated to
no longer be pending)
> Languages left to do:
> * c_glib
> * erlang
> * haskell
> * php
> * python
> * python3
> * any non-cross tested languages



--
This message was sent by Atlassian JIRA
(v7.6.3#76005)

Mime
View raw message