crclark / foundationdb-haskell

Haskell FFI bindings to the FoundationDB C API
https://crclark.github.io/foundationdb-haskell/
BSD 3-Clause "New" or "Revised" License
36 stars 5 forks source link

Error when cluster file includes comment lines #55

Closed xnomagichash closed 1 year ago

xnomagichash commented 1 year ago

Trying to open a cluster that has been modified using fdbcli, this error comes up:

Error: Invalid input

/etc/foundationdb/fdb.cluster:1:1:
  |
1 | # DO NOT EDIT!
  | ^^^^^^^^
unexpected "# DO NOT"
expecting expression or whitespace

You can trivially reproduce by using fdbcli to modify your cluster file:

fdbcli --exec 'coordinators description=12345'
xnomagichash commented 1 year ago

Testing indicates this only happens when explicit clusterFile specified on linux.

xnomagichash commented 1 year ago

Further information...can't reproduce on a different linux machine with 7.1.25 and a mac with 7.1.24. Only a red hat machine with 7.1.23 exhibits this behavior. For now I would treat this error report as erroneous. We'll keep trying to narrow down the exact issue.

crclark commented 1 year ago

If you see this again, I’d open it against foundationdb itself. This library doesn’t contain any code to parse the cluster file; it simply passes the path to the FDB C library. If you are able to reproduce again, try also reproducing with a simple Python script — I’d bet the same thing will happen there.

Closing, but feel free to reopen if you find more evidence that it’s a problem in this library.