Code Monkey home page Code Monkey logo

Comments (6)

hhblaze avatar hhblaze commented on July 24, 2024

Open in different threads different transactions and query the same table. It works out of the box

from dbreeze.

NicolasDorier avatar NicolasDorier commented on July 24, 2024

This is not exactly the same as overlapped IO. You can do several overlapped IO without having to spawn more threads. Also I noticed big perf hit if I make one transaction per query.

from dbreeze.

hhblaze avatar hhblaze commented on July 24, 2024

Of course, you create several transactions to execute in parallel fetching batches, not one select.
Try to write an example for me proving/showing me your fetching scenario.
Because, if you have logical batches to query, already now, you can make it in parallel.
If you don't have logical batches to split between fetching threads, you will always encounter waiting for the result, before starting new fetch.

from dbreeze.

NicolasDorier avatar NicolasDorier commented on July 24, 2024

Thanks, I'll try that. I receive one big batch to fetch, so indeed I can split it in smaller batch to several worker threads.

Might be good enough for my case, just that I think it is even more efficient to use BeginRead/BeginEnd on the file system, as it would not require several threads.

I let you know how it goes, thanks.

from dbreeze.

NicolasDorier avatar NicolasDorier commented on July 24, 2024

An example:

Here https://github.com/hhblaze/DBreeze/blob/master/DBreeze/Storage/FSR.cs#L833 you are looping and doing many write sequentially.
Instead you can BeginWrite them all, and wait for them all afterward.

I will try to do that and benchmark a bit, I have some crappy hard drive which make measuring that easy.

from dbreeze.

NicolasDorier avatar NicolasDorier commented on July 24, 2024

Forget what I said, you can't call several BeginRead without reading results sequentially. https://msdn.microsoft.com/en-us/library/zxt5ahzw(v=vs.110).aspx

from dbreeze.

Related Issues (20)

Recommend Projects

  • React photo React

    A declarative, efficient, and flexible JavaScript library for building user interfaces.

  • Vue.js photo Vue.js

    🖖 Vue.js is a progressive, incrementally-adoptable JavaScript framework for building UI on the web.

  • Typescript photo Typescript

    TypeScript is a superset of JavaScript that compiles to clean JavaScript output.

  • TensorFlow photo TensorFlow

    An Open Source Machine Learning Framework for Everyone

  • Django photo Django

    The Web framework for perfectionists with deadlines.

  • D3 photo 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.

  • Game

    Some thing interesting about game, make everyone happy.

Recommend Org

  • Facebook photo Facebook

    We are working to build community through open source technology. NB: members must have two-factor auth.

  • Microsoft photo Microsoft

    Open source projects and samples from Microsoft.

  • Google photo Google

    Google ❤️ Open Source for everyone.

  • D3 photo D3

    Data-Driven Documents codes.