Skip to content

[BUG] SearchOptions.SessionId is not passed to the service #27549

Closed
@Mohit-Chakraborty

Description

Library name and version

Azure.Search.Documents

Describe the bug

When a user sets the SessionId in SearchOptions for a query, the service does not receive the property.

Expected behavior

We expect to see SessionId passed to the service.

Actual behavior

Service-side logs show that SessionId was not passed.

Reproduction Steps

      private static void RunQueries(SearchClient srchclient)
      {
          SearchOptions options;
          SearchResults<Hotel> response;

          Console.WriteLine("Query #1: Search on empty term '*' to return all documents, showing a subset of fields...\n");

          options = new SearchOptions()
          {
              IncludeTotalCount = true,  
              SessionId = "123",
          };

          options.Select.Add("HotelId");
          options.Select.Add("HotelName");
          options.Select.Add("Rating");

          while (true)
          {
              response = srchclient.Search<Hotel>("*", options);
              WriteDocuments(response);
          }
      }

Environment

No response

Activity

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Metadata

Metadata

Labels

Type

No type

Projects

No projects

Milestone

No milestone

Relationships

None yet

Development

No branches or pull requests

Issue actions