worryg0d commented on code in PR #1793:
URL:
https://github.com/apache/cassandra-gocql-driver/pull/1793#discussion_r1851888122
##########
query_executor.go:
##########
@@ -83,7 +83,28 @@ func (q *queryExecutor) speculate(ctx context.Context, qry
ExecutableQuery, sp S
}
func (q *queryExecutor) executeQuery(qry ExecutableQuery) (*Iter, error) {
- hostIter := q.policy.Pick(qry)
+ type hostGetter interface {
Review Comment:
I updated the implementation by adding `GetHost()` to `ExecutableQuery`.
Also, I looked over my implementation and found a bug leading to endless
query execution... It appears when the host passed to `SetHost()` is not UP. I
changed the behavior
[here](https://github.com/worryg0d/gocql/blob/c1e46be251fc5779a2cb6a8a52cee03a8a161275/query_executor.go#L148)
not to pick the next `selectedHost` when the selected one is not up and
`GetHost()` returned no host.
--
This is an automated message from the Apache Git Service.
To respond to the message, please log on to GitHub and use the
URL above to go to the specific comment.
To unsubscribe, e-mail: [email protected]
For queries about this service, please contact Infrastructure at:
[email protected]
---------------------------------------------------------------------
To unsubscribe, e-mail: [email protected]
For additional commands, e-mail: [email protected]