Comments (3)
Hi, can you give a small example of your purpose?
from dbreeze.
I try to replace LevelDb (or Rocksdb) with DBreeze. I really like it. Seems to be really fast and realible.
However, my datastructures are binary only.
First 16 bits describe the table, next 8 some attributes, then indexnumber, later on a keytype and the byte[] value of something. maybe a rowident for an index-entry.
To maintain an order and to produce some secundary indexes, I have to compare my bytearray. In LevelDb this is possible by obening a Database and pass a option:
options.Comparator = Comparator.Create(
"MyCompare",
(xs, ys) => Compare.Comparer.BinaryCompare(((NativeArray<byte>)xs).Select(x => x),
((NativeArray<byte>)ys).Select(y => y)));
Maybe that's not the intended way to use dbreeze, however a custom comparator might be comfortable sometimes.
from dbreeze.
I understand, this meaning you took from LevelDb and I am not sure it is possible so directly in DBreeze. Here keys are lexicographically sorted for maximal efficient search. There are some special functions to help to covert numerical data types into "lexicographically" sortable.
Here are some docs, like How DBreeze index works, to have understanding about the fact that we create indexes depending upon queries we are going to apply and Object-DBreeze to see that query types can be so different that leads to rearranging of the key and appearance of the secondary indices.
Keys are created for different types of range search and traversing and can be created manually by using functions from
DBreeze.Utils.BytesProcessing that contains rich library to work with byte[]: conatenating, comparation (_ByteArrayEquals), cutting and so on...
Please reopen that issue if you have practical advices that are really implementable concerning your question.
from dbreeze.
Related Issues (20)
- Why duplicated projects? HOT 5
- Guide on how to fail-over with Raft and DBreeze HOT 10
- TextSearch bug HOT 6
- Getting "Getting table "@utCoins" from the schema failed!" when calling Technical_SetTable_OverwriteIsNotAllowed HOT 2
- DBreeze sorts by ID HOT 4
- DBreeze.Exceptions.DBreezeException: Creation of the database folder failed! ---> DBreeze.Exceptions.DBreezeException: Database is not operable, please find out the problem and restart the engine! FSR INIT FAILED HOT 5
- What's wrong with transactions? HOT 4
- Multiple DBreezeEngine instances to the same db files HOT 1
- Custom Serializator for Biser? HOT 4
- Biser Objectifies classes using different namespace than DBreeze's version HOT 6
- Text Search of items < minimum size not possible? HOT 4
- Count of documents ids 0 with data being in the table HOT 3
- .net core 5 HOT 4
- Serialize/Deserialize should not be static
- Reading from multiple tables at once and returning sorted results HOT 2
- TextSearch Tables still contains internal/external references, after using TextRemoveAll HOT 5
- RemoveSession is not called on "DBreeze.Exceptions.DBreezeException: One transaction can be used from one thread only!" HOT 1
- What happens to Old DataBlocks? HOT 7
- Memory mode insert slower than writes on disk HOT 1
- Database insert speed HOT 4
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 dbreeze.