Bitcoin Forum
May 11, 2024, 09:52:12 PM *
News: Latest Bitcoin Core release: 27.0 [Torrent]
 
   Home   Help Search Login Register More  
Pages: [1]
  Print  
Author Topic: What advantages does using LevelDB offer?  (Read 1399 times)
FPoBA (OP)
Newbie
*
Offline Offline

Activity: 6
Merit: 1


View Profile
August 20, 2014, 06:06:41 PM
Merited by ABCbits (1)
 #1

What are the advantages? Why was it implemented?

 Huh
1715464332
Hero Member
*
Offline Offline

Posts: 1715464332

View Profile Personal Message (Offline)

Ignore
1715464332
Reply with quote  #2

1715464332
Report to moderator
1715464332
Hero Member
*
Offline Offline

Posts: 1715464332

View Profile Personal Message (Offline)

Ignore
1715464332
Reply with quote  #2

1715464332
Report to moderator
1715464332
Hero Member
*
Offline Offline

Posts: 1715464332

View Profile Personal Message (Offline)

Ignore
1715464332
Reply with quote  #2

1715464332
Report to moderator
"The nature of Bitcoin is such that once version 0.1 was released, the core design was set in stone for the rest of its lifetime." -- Satoshi
Advertised sites are not endorsed by the Bitcoin Forum. They may be unsafe, untrustworthy, or illegal in your jurisdiction.
1715464332
Hero Member
*
Offline Offline

Posts: 1715464332

View Profile Personal Message (Offline)

Ignore
1715464332
Reply with quote  #2

1715464332
Report to moderator
1715464332
Hero Member
*
Offline Offline

Posts: 1715464332

View Profile Personal Message (Offline)

Ignore
1715464332
Reply with quote  #2

1715464332
Report to moderator
CIYAM
Legendary
*
Offline Offline

Activity: 1890
Merit: 1078


Ian Knowles - CIYAM Lead Developer


View Profile WWW
August 20, 2014, 06:09:56 PM
Merited by ABCbits (2)
 #2

When you are dealing with data that is mostly *binary* in nature a SQL DB doesn't really offer much advantage over a DB that is more "object based".

Basically you end up having to do *more work* with a SQL DB than a non-SQL DB to store/retrieve the records - so if you don't need SQL then it is actually going to be *faster* to not use it.

Understand that the *simplest* way to do things will always be the *fastest*.

With CIYAM anyone can create 100% generated C++ web applications in literally minutes.

GPG Public Key | 1ciyam3htJit1feGa26p2wQ4aw6KFTejU
ScripterRon
Full Member
***
Offline Offline

Activity: 136
Merit: 120


View Profile
August 20, 2014, 07:59:32 PM
Merited by ABCbits (2)
 #3

What are the advantages? Why was it implemented?
I've used LevelDB, H2, Firebird and PostgreSQL with my JavaBitcoin node.  LevelDB wins hands-down on both performance and database size.  It is ideal for a bitcoin database where you have a small number of keys (usually just the transaction or block hash) and don't need the complexity of the SQL SELECT statement.  It is easy to implement a secondary index (such as block height->block) using a separate map.

Ron
azeteki
Member
**
Offline Offline

Activity: 96
Merit: 10

esotericnonsense


View Profile WWW
August 20, 2014, 08:47:06 PM
 #4

The UXTO db as implemented stores unspent outputs, serialized, keyed by txid.

That's it. Want to know if a txid has unspent outputs? Look in the DB and deserialize the information.

Nothing more advanced than that is really required.

FPoBA (OP)
Newbie
*
Offline Offline

Activity: 6
Merit: 1


View Profile
August 21, 2014, 06:25:12 AM
 #5

Thanks for all your replies, I have a clearer picture now.  Smiley
Pages: [1]
  Print  
 
Jump to:  

Powered by MySQL Powered by PHP Powered by SMF 1.1.19 | SMF © 2006-2009, Simple Machines Valid XHTML 1.0! Valid CSS!