apache / apache/cassandra-gocql-driver

session.Closed returns false when cassandra went down or stopped after client made a successful session.

Open
#1,601 4 comments 0 reactions 0 assignees View on GitHub
Dominant language
Go
Stars
2.7k
Forks
658
PR merge metrics
No merged PRs in 30d

Description

### What version of Cassandra are you using?
3.11.3

### What version of Gocql are you using?
v0.0.0-20200221113847-372a19b1a852

### What version of Go are you using?
1.14

### What did you do?
I tried getting the metadata of keyspace to check the table existence while gocql client is connected to cassandra. After I stopped the cassandra, gocql wasn't throwing any error and returning cached metadata to check the table existence.
Also, when I checked session.Closed it returns false when cassandra wasn't running.

### What did you expect to see?
Error should have been thrown.
session.Closed should have returned true, when cassandra went down or stopped after client made a successful session.

### What did you see instead?
session.Closed it returns false when cassandra wasn't running.
---

Contributor guide

Open the contributing guide

Research direction

No source file or test is named in the issue. Start by reproducing the metadata lookup after stopping Cassandra 3.11.3, then trace the session.Closed behavior in the Go driver. Done means the outage is surfaced as an error and session.Closed returns true after the connected Cassandra instance stops.

Written by the indexing model from the issue text.

Assessment

Tech stack
cassandra, go
Domain
databases
Issue type
Bug
Difficulty
4/5
Estimated time
3-5 days
Activity status
Stale
Clarity
Mostly clear
Newbie friendliness
35/100

Get new issues in your inbox

A short digest of beginner-friendly GitHub issues.