Comments (8)
I will try to contribute some worked examples of different use cases, having just spent a few hours going through the Go API this evening. No ETA though, so if someone else gets there first, then great! :-)
from foundationdb.
+1
from foundationdb.
+1
from foundationdb.
+1
from foundationdb.
would appreciate a watch sample. I have a fairly nice one, but it only runs for few dozen watches and then bombs with FoundationDB error code 1009 (Request for future version).
from foundationdb.
One thing that wasn't clear to me when starting out with FDB was that transaction timeouts are on a per-transaction basis. The docs don't set them and I think they should. Here's an example of checking whether or not a key exists w/ timeouts:
var exists bool
keyToFind := "testing-key"
ret, err := db.Transact(func(tr fdb.Transaction) (interface{}, error) {
tr.Options().SetTimeout(2000) // Set a 2 second timeout (you may want less)
if tr.Get(fdb.Key(keyToFind)).MustGet() != nil {
return true, nil
}
return false, nil
})
if err != nil {
log.Printf("Error checking FDB for key: %v", err)
}
exists = ret.(bool)
from foundationdb.
The docs don't set them and I think they should.
See also #882
from foundationdb.
The docs don't set them and I think they should.
See also #882
Thanks AJ. Added a pull request to add them to the docs (at least for python and golang)
from foundationdb.
Related Issues (20)
- Add typing for FDB python binding package
- FoundationDB is unresponsive on MacOS ARM64 when disk usage is high HOT 1
- TestOpenNotExistTenant will always fail on release-7.3/release-7.1
- GetEstimatedRangeSizeBytes can cause PacketLimitExceeded error on commit proxies
- Benchmark `Trace.cpp:SuppressionMap`
- ASSERTion in flow may be improved by bringing in less branches HOT 3
- FDBLibTLS being used? HOT 1
- Use pathlib.Path in Directory layer in Python bindings if possible
- DR fails atomicity in 7.3.43 HOT 4
- Use std::filesystem::path in Platform.h HOT 7
- Remove path code in platform.h
- Automatic idempotency ids have insufficient entropy
- release package for linux arm64 HOT 10
- Batch GRV Rate Limit Exceeded is not always thrown HOT 2
- Add an API to support splitting a given range into shards individually HOT 6
- Apple analysis
- Client side does not merge conflict ranges HOT 2
- Problems in retrieving conflicting keys after setting transaction option ReportConflictingKeys HOT 1
- SQLite in StorageServer deadlocked after the node was disconnected and resumed. HOT 4
- fbcli in python
Recommend Projects
-
React
A declarative, efficient, and flexible JavaScript library for building user interfaces.
-
Vue.js
🖖 Vue.js is a progressive, incrementally-adoptable JavaScript framework for building UI on the web.
-
Typescript
TypeScript is a superset of JavaScript that compiles to clean JavaScript output.
-
TensorFlow
An Open Source Machine Learning Framework for Everyone
-
Django
The Web framework for perfectionists with deadlines.
-
Laravel
A PHP framework for web artisans
-
D3
Bring data to life with SVG, Canvas and HTML. 📊📈🎉
-
Recommend Topics
-
javascript
JavaScript (JS) is a lightweight interpreted programming language with first-class functions.
-
web
Some thing interesting about web. New door for the world.
-
server
A server is a program made to process requests and deliver data to clients.
-
Machine learning
Machine learning is a way of modeling and interpreting data that allows a piece of software to respond intelligently.
-
Visualization
Some thing interesting about visualization, use data art
-
Game
Some thing interesting about game, make everyone happy.
Recommend Org
-
Facebook
We are working to build community through open source technology. NB: members must have two-factor auth.
-
Microsoft
Open source projects and samples from Microsoft.
-
Google
Google ❤️ Open Source for everyone.
-
Alibaba
Alibaba Open Source for everyone
-
D3
Data-Driven Documents codes.
-
Tencent
China tencent open source team.
from foundationdb.