Uploaded image for project: 'TinkerPop'
  1. TinkerPop
  2. TINKERPOP-3061

Concurrent queries will break authentication on javascript driver

VotersWatch issueWatchersLinkCloneUpdate Comment AuthorReplace String in CommentUpdate Comment VisibilityDelete Comments
    XMLWordPrintableJSON

Details

    • Bug
    • Status: Closed
    • Major
    • Resolution: Fixed
    • 3.6.6, 3.7.1
    • 3.7.2
    • javascript, server
    • None

    Description

      Reported by tien on Discord:

      import gremlin from "gremlin";
      
      const g = gremlin.process.AnonymousTraversalSource.traversal().withRemote(
        new gremlin.driver.DriverRemoteConnection("ws://localhost:8182/gremlin", {
          authenticator: new gremlin.driver.auth.PlainTextSaslAuthenticator(
            "admin",
            "administrator"
          ),
        })
      );
      
      // This will throws: Failed to authenticate (401)
      await Promise.all([g.V().toList(), g.V().toList()]);
      
      // This works as expected
      await g.V().toList();
      await g.V().toList(); 

      Attachments

        Issue Links

        Activity

          This comment will be Viewable by All Users Viewable by All Users
          Cancel

          People

            xiazcy Yang Xia
            xiazcy Yang Xia
            Votes:
            0 Vote for this issue
            Watchers:
            4 Start watching this issue

            Dates

              Created:
              Updated:
              Resolved:

              Slack

                Issue deployment