==== TMockDiscovery server started on port 37263
==== TMockDiscovery add endpoints, firstNodeId 9999, nodeCount 1, port 1665
====TYdbPqTestRetryPolicy()
====ExpectBreakDown
=== Create write session
==== ListEndpoints request: database: "local"
==== ListEndpoints response: operation { ready: true status: SUCCESS result { [type.googleapis.com/Ydb.Discovery.ListEndpointsResult] { endpoints { address: "localhost" port: 1665 node_id: 9999 } } } }
2025-12-12T11:55:18.623324Z :DEBUG: [local]  TraceId []  SessionId []  PartitionId [0]  Generation [0] Write session: try to update token
2025-12-12T11:55:18.623531Z :INFO: [local]  TraceId []  SessionId []  PartitionId [0]  Generation [0] Get partition location async, partition 0, delay 0.000000s
=== Wait for retries
2025-12-12T11:55:18.623563Z :DEBUG: [local]  TraceId []  SessionId []  PartitionId [0]  Generation [0]  Getting partition location, partition 0
2025-12-12T11:55:18.626598Z :INFO: [local]  TraceId []  SessionId []  PartitionId [0]  Generation [0] Got PartitionLocation response. Status SUCCESS, proto:
partition {
  active: true
  partition_location {
    node_id: 1
    generation: 1
  }
}
2025-12-12T11:55:18.626621Z :ERROR: [local]  TraceId []  SessionId []  PartitionId [0]  Generation [0] GetPreferredEndpoint: partitionId 0, nodeId 1 does not exist in the endpoint pool.
====CreateRetryState
====CreateRetryState Initialized
Test retry state: get retry delay
2025-12-12T11:55:18.626858Z :INFO: [local]  TraceId []  SessionId []  PartitionId [0]  Generation [0] Got error. Status: UNAVAILABLE, Description: <main>: Error: Partition preferred endpoint is not found 
2025-12-12T11:55:18.626863Z :INFO: [local]  TraceId []  SessionId []  PartitionId [0]  Generation [0] Write session will restart in 2.000000s
2025-12-12T11:55:18.626870Z :INFO: [local]  TraceId []  SessionId []  PartitionId [0]  Generation [0] Get partition location async, partition 0, delay 2.000000s
==== ListEndpoints request: database: "local"
==== ListEndpoints response: operation { ready: true status: SUCCESS result { [type.googleapis.com/Ydb.Discovery.ListEndpointsResult] { endpoints { address: "localhost" port: 1665 node_id: 9999 } } } }
2025-12-12T11:55:20.627391Z :DEBUG: [local]  TraceId []  SessionId []  PartitionId [0]  Generation [0]  Getting partition location, partition 0
2025-12-12T11:55:20.629014Z :INFO: [local]  TraceId []  SessionId []  PartitionId [0]  Generation [0] Got PartitionLocation response. Status SUCCESS, proto:
partition {
  active: true
  partition_location {
    node_id: 1
    generation: 1
  }
}
2025-12-12T11:55:20.629033Z :ERROR: [local]  TraceId []  SessionId []  PartitionId [0]  Generation [0] GetPreferredEndpoint: partitionId 0, nodeId 1 does not exist in the endpoint pool.
Test retry state: get retry delay
2025-12-12T11:55:20.629290Z :INFO: [local]  TraceId []  SessionId []  PartitionId [0]  Generation [0] Got error. Status: UNAVAILABLE, Description: <main>: Error: Partition preferred endpoint is not found 
2025-12-12T11:55:20.629295Z :INFO: [local]  TraceId []  SessionId []  PartitionId [0]  Generation [0] Write session will restart in 2.000000s
2025-12-12T11:55:20.629302Z :INFO: [local]  TraceId []  SessionId []  PartitionId [0]  Generation [0] Get partition location async, partition 0, delay 2.000000s
==== ListEndpoints request: database: "local"
==== ListEndpoints response: operation { ready: true status: SUCCESS result { [type.googleapis.com/Ydb.Discovery.ListEndpointsResult] { endpoints { address: "localhost" port: 1665 node_id: 9999 } } } }
2025-12-12T11:55:22.630472Z :DEBUG: [local]  TraceId []  SessionId []  PartitionId [0]  Generation [0]  Getting partition location, partition 0
2025-12-12T11:55:22.633038Z :INFO: [local]  TraceId []  SessionId []  PartitionId [0]  Generation [0] Got PartitionLocation response. Status SUCCESS, proto:
partition {
  active: true
  partition_location {
    node_id: 1
    generation: 1
  }
}
2025-12-12T11:55:22.633058Z :ERROR: [local]  TraceId []  SessionId []  PartitionId [0]  Generation [0] GetPreferredEndpoint: partitionId 0, nodeId 1 does not exist in the endpoint pool.
Test retry state: get retry delay
2025-12-12T11:55:22.633371Z :INFO: [local]  TraceId []  SessionId []  PartitionId [0]  Generation [0] Got error. Status: UNAVAILABLE, Description: <main>: Error: Partition preferred endpoint is not found 
2025-12-12T11:55:22.633376Z :INFO: [local]  TraceId []  SessionId []  PartitionId [0]  Generation [0] Write session will restart in 2.000000s
==== TMockDiscovery set good endpoint nodes 2025-12-12T11:55:22.633385Z :INFO: [local]  TraceId []  SessionId []  PartitionId [0]  Generation [0] Get partition location async, partition 0, delay 2.000000s
==== TMockDiscovery add endpoints, firstNodeId 1, nodeCount 1, port 1665
=== Wait for repair
==== ListEndpoints request: database: "local"
==== ListEndpoints response: operation { ready: true status: SUCCESS result { [type.googleapis.com/Ydb.Discovery.ListEndpointsResult] { endpoints { address: "localhost" port: 1665 node_id: 1 } } } }
2025-12-12T11:55:24.634492Z :DEBUG: [local]  TraceId []  SessionId []  PartitionId [0]  Generation [0]  Getting partition location, partition 0
2025-12-12T11:55:24.636772Z :INFO: [local]  TraceId []  SessionId []  PartitionId [0]  Generation [0] Got PartitionLocation response. Status SUCCESS, proto:
partition {
  active: true
  partition_location {
    node_id: 1
    generation: 1
  }
}
2025-12-12T11:55:24.636793Z :DEBUG: [local]  TraceId []  SessionId []  PartitionId [0]  Generation [0] GetPreferredEndpoint: partitionId 0, partitionNodeId 1 exists in the endpoint pool.
2025-12-12T11:55:24.636799Z :INFO: [local]  TraceId []  SessionId []  PartitionId [0]  Generation [1] Start write session. Will connect to nodeId: 1
2025-12-12T11:55:24.637114Z :DEBUG: [local]  TraceId []  SessionId []  PartitionId [0]  Generation [1] Write session: direct write to partition: 0, generation 1
2025-12-12T11:55:24.637147Z :DEBUG: [local]  TraceId []  SessionId []  PartitionId [0]  Generation [1] Write session: send init request: init_request { path: "sdk_tests/LocalPartition-DirectRead_DiscoveryServiceBadNodeId/test-topic" producer_id: "test-producer" partition_with_generation { generation: 1 } }
2025-12-12T11:55:24.637289Z :DEBUG: [local]  TraceId []  SessionId []  PartitionId [0]  Generation [1] Write session: OnWriteDone gRpcStatusCode: 0
2025-12-12T11:55:24.649566Z :DEBUG: [local]  TraceId []  SessionId []  PartitionId [0]  Generation [1] Write session: OnReadDone gRpcStatusCode: 0
2025-12-12T11:55:24.649594Z :INFO: [local]  TraceId []  SessionId []  PartitionId [0]  Generation [1] Counters: { Errors: 3 CurrentSessionLifetimeMs: 1765540524649 BytesWritten: 0 MessagesWritten: 0 BytesWrittenCompressed: 0 BytesInflightUncompressed: 0 BytesInflightCompressed: 0 BytesInflightTotal: 0 MessagesInflight: 0 }
2025-12-12T11:55:24.649627Z :INFO: [local]  TraceId []  SessionId []  PartitionId [0]  Generation [1] Write session established. Init response: session_id: "test-producer|b1a593fd-10844a43-6af28761-276db48_0"
====StateDestroyed
=== Close write session
2025-12-12T11:55:24.649772Z :INFO: [local]  TraceId []  SessionId [test-producer|b1a593fd-10844a43-6af28761-276db48_0]  PartitionId [0]  Generation [1] Write session: close. Timeout 18446744073709.551615s
2025-12-12T11:55:24.649776Z :INFO: [local]  TraceId []  SessionId [test-producer|b1a593fd-10844a43-6af28761-276db48_0]  PartitionId [0]  Generation [1] Write session will now close
2025-12-12T11:55:24.649782Z :DEBUG: [local]  TraceId []  SessionId [test-producer|b1a593fd-10844a43-6af28761-276db48_0]  PartitionId [0]  Generation [1] Write session: aborting
2025-12-12T11:55:24.649929Z :INFO: [local]  TraceId []  SessionId [test-producer|b1a593fd-10844a43-6af28761-276db48_0]  PartitionId [0]  Generation [1] Write session: gracefully shut down, all writes complete
2025-12-12T11:55:24.649937Z :DEBUG: [local]  TraceId []  SessionId [test-producer|b1a593fd-10844a43-6af28761-276db48_0]  PartitionId [0]  Generation [1] Write session: destroy
