Hi, I’m on 6.3.15 and having trouble using the conflicting keys special keyspace with Go bindings. Following the special-key-space doc I tried this range:
I fetch the whole range without any limits or options (tx.GetRange(fdbConflictKeysRange, fdb.RangeOptions{})), but I still get the error FoundationDB error code 2004 (Key outside legal range).
Initially I got the error Operation issued while a commit was outstanding so following this I am getting the future prior to commit and reading the future after commit. (I also tried getting the future and reading it after commit, which didn’t work either.)
So to summarize my logic does:
Open transaction
Set SetReportConflictingKeys option (also tried adding SetAccessSystemKeys and SetSpecialKeySpaceRelaxed, as suspected it didn’t make a difference)
Read/write transaction operations
Get the conflicting keys range future (GetRange)
Commit (Errors due to conflict, as expected in my test)
Read future (GetSliceWithError) - This errors.
Is there something wrong with my range query? I believe for special key spaces your query must exactly match what FDB is looking for so I’m guessing my query is off. Could the go bindings be unexpectedly altering the range query? (I looked at the range code and couldn’t find anything obvious?)
In fdbcli I can read that range (it’s empty) without any errors, so I am guessing my version is fine.
@leonliao What version are you on? I tried your code (using those commented out lines for the conflicting keys range) and still got the 2004 error code.
My understanding is that “system keys” is [\xff, \xff\xff) and the Access/Read System Keys options won’t grant access to the special keyspace (prefix \xff\xff )
@jkominek Were you able to read the conflicting keys with that option? If so, what version are you on? I still get the 2004 error code with that option.