Skip to content

Commit e9c04db

Browse files
add comment about cassandra nil vs empty struct
1 parent a338232 commit e9c04db

File tree

2 files changed

+2
-1
lines changed

2 files changed

+2
-1
lines changed

common/persistence/nosql/nosqlplugin/cassandra/tasks.go

+1
Original file line numberDiff line numberDiff line change
@@ -90,6 +90,7 @@ func toTaskListPartitionConfig(v interface{}) *persistence.TaskListPartitionConf
9090
numRead := partition["num_read_partitions"].(int)
9191
numWrite := partition["num_write_partitions"].(int)
9292

93+
// even if null is stored in cassandra, gocql will return empty struct instead of nil
9394
if version == 0 && numRead == 0 && numWrite == 0 {
9495
return nil
9596
}

idls

Submodule idls updated from 0ff0916 to b527eeb

0 commit comments

Comments
 (0)