[CSHARP-1730] Implement The MongoDB Handshake Protocol Created: 29/Jul/16  Updated: 19/Oct/16  Resolved: 22/Sep/16

Status: Closed
Project: C# Driver
Component/s: Connectivity
Affects Version/s: None
Fix Version/s: 2.4

Type: New Feature Priority: Major - P3
Reporter: Rathi Gnanasekaran Assignee: Robert Stam
Resolution: Done Votes: 0
Labels: None
Remaining Estimate: Not Specified
Time Spent: Not Specified
Original Estimate: Not Specified

Issue Links:
Depends
is depended on by DRIVERS-304 MongoDB Handshake protocol Closed
Epic Link: MongoDB 3.4

 Description   

https://github.com/mongodb/specifications/blob/master/source/mongodb-handshake/handshake.rst

TL;DR: Every socket connecting to MongoDB MUST issue isMaster announcing itself to the server with the following pseudo document.
There is also new connection URI field appname the user can provide (client.application.name) which the server will write out in its logs and profile entries, making correlating server log entries to respective applications trivial.

isMaster({
    client: {
        /* OPTIONAL. If present, the "name" is REQUIRED */
        application: {
            name: "<string>"
        },
        /* REQUIRED, including all sub fields */
        driver: {
            name: "<string>",
            version: "<string>"
        },
        /* REQUIRED */
        os: {
            type: "<string>",         /* REQUIRED */
            name: "<string>",         /* OPTIONAL */
            architecture: "<string>", /* OPTIONAL */
            version: "<string>"       /* OPTIONAL */
        },
        /* OPTIONAL */
        platform: "<string>"
    }
})



 Comments   
Comment by Githook User [ 29/Sep/16 ]

Author:

{u'username': u'rstam', u'name': u'rstam', u'email': u'robert@robertstam.org'}

Message: CSHARP-1730: Added IsApplicationNameValid method.
Branch: master
https://github.com/mongodb/mongo-csharp-driver/commit/5dc1942bb0c2d1f338c9f046a10cb99280f3dbe6

Comment by Githook User [ 29/Sep/16 ]

Author:

{u'username': u'rstam', u'name': u'rstam', u'email': u'robert@robertstam.org'}

Message: CSHARP-1730: Add ClientDocumentHelper and enforce max sizes on ApplicationName and ClientDocument.
Branch: master
https://github.com/mongodb/mongo-csharp-driver/commit/f9d1fc46447e2374b58710cd091ad36ba2a8fd77

Comment by Githook User [ 29/Sep/16 ]

Author:

{u'username': u'rstam', u'name': u'rstam', u'email': u'robert@robertstam.org'}

Message: CSHARP-1730: Implement the client handshake protocol.
Branch: master
https://github.com/mongodb/mongo-csharp-driver/commit/bfc6c47f094d3395a091baa8ce9e9189eaba9bb6

Comment by Githook User [ 24/Sep/16 ]

Author:

{u'username': u'rstam', u'name': u'rstam', u'email': u'robert@robertstam.org'}

Message: CSHARP-1730: Added IsApplicationNameValid method.
Branch: v2.4.x
https://github.com/mongodb/mongo-csharp-driver/commit/5dc1942bb0c2d1f338c9f046a10cb99280f3dbe6

Comment by Githook User [ 24/Sep/16 ]

Author:

{u'username': u'rstam', u'name': u'rstam', u'email': u'robert@robertstam.org'}

Message: CSHARP-1730: Add ClientDocumentHelper and enforce max sizes on ApplicationName and ClientDocument.
Branch: v2.4.x
https://github.com/mongodb/mongo-csharp-driver/commit/f9d1fc46447e2374b58710cd091ad36ba2a8fd77

Comment by Githook User [ 24/Sep/16 ]

Author:

{u'username': u'rstam', u'name': u'rstam', u'email': u'robert@robertstam.org'}

Message: CSHARP-1730: Implement the client handshake protocol.
Branch: v2.4.x
https://github.com/mongodb/mongo-csharp-driver/commit/bfc6c47f094d3395a091baa8ce9e9189eaba9bb6

Comment by Githook User [ 22/Sep/16 ]

Author:

{u'username': u'rstam', u'name': u'rstam', u'email': u'robert@robertstam.org'}

Message: CSHARP-1730: Added IsApplicationNameValid method.
Branch: v2.4.x
https://github.com/mongodb/mongo-csharp-driver/commit/1806dbba533548c3a108edd495f78be6419759e6

Comment by Githook User [ 22/Sep/16 ]

Author:

{u'username': u'rstam', u'name': u'rstam', u'email': u'robert@robertstam.org'}

Message: CSHARP-1730: Add ClientDocumentHelper and enforce max sizes on ApplicationName and ClientDocument.
Branch: v2.4.x
https://github.com/mongodb/mongo-csharp-driver/commit/1c2cae1dd3c28f5b885954a6d1790ccc4b4f390e

Comment by Githook User [ 22/Sep/16 ]

Author:

{u'username': u'rstam', u'name': u'rstam', u'email': u'robert@robertstam.org'}

Message: CSHARP-1730: Implement the client handshake protocol.
Branch: v2.4.x
https://github.com/mongodb/mongo-csharp-driver/commit/0716894e375ab4c7ffea9dd169361019802064b0

Generated at Wed Feb 07 21:40:31 UTC 2024 using Jira 9.7.1#970001-sha1:2222b88b221c4928ef0de3161136cc90c8356a66.