Skip to content

Commit

Permalink
add comment about cassandra nil vs empty struct
Browse files Browse the repository at this point in the history
  • Loading branch information
mantas-sidlauskas committed Nov 21, 2024
1 parent a338232 commit e9c04db
Show file tree
Hide file tree
Showing 2 changed files with 2 additions and 1 deletion.
1 change: 1 addition & 0 deletions common/persistence/nosql/nosqlplugin/cassandra/tasks.go
Original file line number Diff line number Diff line change
Expand Up @@ -90,6 +90,7 @@ func toTaskListPartitionConfig(v interface{}) *persistence.TaskListPartitionConf
numRead := partition["num_read_partitions"].(int)
numWrite := partition["num_write_partitions"].(int)

// even if null is stored in cassandra, gocql will return empty struct instead of nil
if version == 0 && numRead == 0 && numWrite == 0 {
return nil
}
Expand Down
2 changes: 1 addition & 1 deletion idls
Submodule idls updated from 0ff091 to b527ee

0 comments on commit e9c04db

Please sign in to comment.