Discussion:
questions about LMDB
Shu, Xinxin
2015-03-19 07:48:56 UTC
Permalink
Content preview: Hi list , Recently I read docs about lmdb , there are two
sentences 1) readers do not block writers 2) writers do not block readers
I can understand 'readers do not block writers' , but cannot understand the
second one , can someone help explain , how lmdb achieve 'writers do not
block readers', below is my understandings , please correct me if anything
wrong. if the access pattern is write - read, since lmdb only support two
version of data , when the write has been started but not committed , the
concurrent read may read stale data since write has not been committed. [...]


Content analysis details: (-6.9 points, 5.0 required)

pts rule name description
---- ---------------------- --------------------------------------------------
-5.0 RCVD_IN_DNSWL_HI RBL: Sender listed at http://www.dnswl.org/, high
trust
[192.55.52.93 listed in list.dnswl.org]
-0.0 T_RP_MATCHES_RCVD Envelope sender domain matches handover relay
domain
-0.0 SPF_PASS SPF: sender matches SPF record
-1.9 BAYES_00 BODY: Bayes spam probability is 0 to 1%
[score: 0.0000]

Hi list ,

Recently I read docs about lmdb , there are two sentences
1) readers do not block writers
2) writers do not block readers
I can understand 'readers do not block writers' , but cannot understand the second one , can someone help explain , how lmdb achieve 'writers do not block readers', below is my understandings , please correct me if anything wrong.
if the access pattern is write - read, since lmdb only support two version of data , when the write has been started but not committed , the concurrent read may read stale data since write has not been committed.

Cheers,
xinxin
Shu, Xinxin
2015-03-19 10:51:22 UTC
Permalink
Content preview: Several other questions about lmdb 1) does lmdb store one
key-value pair in a single page? How lmdb organizes these key-value pairs
in a single page 2) if size is larger than single page size , how lmdb process
this request? [...]

Content analysis details: (-1.9 points, 5.0 required)

pts rule name description
---- ---------------------- --------------------------------------------------
0.0 RCVD_IN_DNSWL_BLOCKED RBL: ADMINISTRATOR NOTICE: The query to DNSWL
was blocked. See
http://wiki.apache.org/spamassassin/DnsBlocklists#dnsbl-block
for more information.
[192.55.52.88 listed in list.dnswl.org]
0.0 URIBL_BLOCKED ADMINISTRATOR NOTICE: The query to URIBL was blocked.
See
http://wiki.apache.org/spamassassin/DnsBlocklists#dnsbl-block
for more information.
[URIs: openldap.org]
-0.0 T_RP_MATCHES_RCVD Envelope sender domain matches handover relay
domain
-0.0 SPF_PASS SPF: sender matches SPF record
-1.9 BAYES_00 BODY: Bayes spam probability is 0 to 1%
[score: 0.0000]

Several other questions about lmdb

1) does lmdb store one key-value pair in a single page? How lmdb organizes these key-value pairs in a single page
2) if size is larger than single page size , how lmdb process this request?

Any help will be appreciated ? thanks

Cheers,
xinxin

-----Original Message-----
From: Shu, Xinxin
Sent: Thursday, March 19, 2015 3:49 PM
To: openldap-***@openldap.org
Cc: Shu, Xinxin
Subject: questions about LMDB

Hi list ,

Recently I read docs about lmdb , there are two sentences
1) readers do not block writers
2) writers do not block readers
I can understand 'readers do not block writers' , but cannot understand the second one , can someone help explain , how lmdb achieve 'writers do not block readers', below is my understandings , please correct me if anything wrong.
if the access pattern is write - read, since lmdb only support two version of data , when the write has been started but not committed , the concurrent read may read stale data since write has not been committed.

Cheers,
xinxin
Howard Chu
2015-03-19 15:51:38 UTC
Permalink
Content preview: Shu, Xinxin wrote: > Several other questions about lmdb >
Post by Shu, Xinxin
1) does lmdb store one key-value pair in a single page? How lmdb organizes
these key-value pairs in a single page > 2) if size is larger than single
page size , how lmdb process this request? [...]

Content analysis details: (-4.2 points, 5.0 required)

pts rule name description
---- ---------------------- --------------------------------------------------
-2.3 RCVD_IN_DNSWL_MED RBL: Sender listed at http://www.dnswl.org/, medium
trust
[69.43.206.106 listed in list.dnswl.org]
0.0 URIBL_BLOCKED ADMINISTRATOR NOTICE: The query to URIBL was blocked.
See
http://wiki.apache.org/spamassassin/DnsBlocklists#dnsbl-block
for more information.
[URIs: highlandsun.com]
-1.9 BAYES_00 BODY: Bayes spam probability is 0 to 1%
[score: 0.0000]
Post by Shu, Xinxin
Several other questions about lmdb
1) does lmdb store one key-value pair in a single page? How lmdb organizes these key-value pairs in a single page
2) if size is larger than single page size , how lmdb process this request?
This list is for developers to discuss actual coding issues inside the OpenLDAP code; your questions are too elementary and don't belong here. Use the -technical list for user-oriented questions.
Post by Shu, Xinxin
Any help will be appreciated ? thanks
Cheers,
xinxin
-----Original Message-----
From: Shu, Xinxin
Sent: Thursday, March 19, 2015 3:49 PM
Cc: Shu, Xinxin
Subject: questions about LMDB
Hi list ,
Recently I read docs about lmdb , there are two sentences
1) readers do not block writers
2) writers do not block readers
I can understand 'readers do not block writers' , but cannot understand the second one , can someone help explain , how lmdb achieve 'writers do not block readers', below is my understandings , please correct me if anything wrong.
if the access pattern is write - read, since lmdb only support two version of data , when the write has been started but not committed , the concurrent read may read stale data since write has not been committed.
Cheers,
xinxin
--
-- Howard Chu
CTO, Symas Corp. http://www.symas.com
Director, Highland Sun http://highlandsun.com/hyc/
Chief Architect, OpenLDAP http://www.openldap.org/project/
Shu, Xinxin
2015-03-20 00:50:22 UTC
Permalink
Content preview: Sorry for the wrong mail list , I will forward this request
to technical list Cheers, xinxin

Content analysis details: (-1.9 points, 5.0 required)

pts rule name description
---- ---------------------- --------------------------------------------------
0.0 RCVD_IN_DNSWL_BLOCKED RBL: ADMINISTRATOR NOTICE: The query to DNSWL
was blocked. See
http://wiki.apache.org/spamassassin/DnsBlocklists#dnsbl-block
for more information.
[192.55.52.115 listed in list.dnswl.org]
0.0 URIBL_BLOCKED ADMINISTRATOR NOTICE: The query to URIBL was blocked.
See
http://wiki.apache.org/spamassassin/DnsBlocklists#dnsbl-block
for more information.
[URIs: highlandsun.com]
-0.0 T_RP_MATCHES_RCVD Envelope sender domain matches handover relay
domain
-0.0 SPF_PASS SPF: sender matches SPF record
-1.9 BAYES_00 BODY: Bayes spam probability is 0 to 1%
[score: 0.0000]

Sorry for the wrong mail list , I will forward this request to technical list

Cheers,
xinxin

-----Original Message-----
From: Howard Chu [mailto:***@symas.com]
Sent: Thursday, March 19, 2015 11:52 PM
To: Shu, Xinxin; openldap-***@openldap.org
Subject: Re: questions about LMDB
Post by Shu, Xinxin
Several other questions about lmdb
1) does lmdb store one key-value pair in a single page? How lmdb organizes these key-value pairs in a single page
2) if size is larger than single page size , how lmdb process this request?
This list is for developers to discuss actual coding issues inside the OpenLDAP code; your questions are too elementary and don't belong here. Use the -technical list for user-oriented questions.
Post by Shu, Xinxin
Any help will be appreciated ? thanks
Cheers,
xinxin
-----Original Message-----
From: Shu, Xinxin
Sent: Thursday, March 19, 2015 3:49 PM
Cc: Shu, Xinxin
Subject: questions about LMDB
Hi list ,
Recently I read docs about lmdb , there are two sentences
1) readers do not block writers
2) writers do not block readers
I can understand 'readers do not block writers' , but cannot understand the second one , can someone help explain , how lmdb achieve 'writers do not block readers', below is my understandings , please correct me if anything wrong.
if the access pattern is write - read, since lmdb only support two version of data , when the write has been started but not committed , the concurrent read may read stale data since write has not been committed.
Cheers,
xinxin
--
-- Howard Chu
CTO, Symas Corp. http://www.symas.com
Director, Highland Sun http://highlandsun.com/hyc/
Chief Architect, OpenLDAP http://www.openldap.org/project/
Howard Chu
2015-03-19 15:49:27 UTC
Permalink
Content preview: Shu, Xinxin wrote: > Hi list , > > Recently I read docs about
lmdb , there are two sentences > 1) readers do not block writers > 2) writers
do not block readers > I can understand 'readers do not block writers' ,
but cannot understand the second one , can someone help explain , how lmdb
achieve 'writers do not block readers', below is my understandings , please
correct me if anything wrong. > if the access pattern is write - read, since
lmdb only support two version of data , when the write has been started but
not committed , the concurrent read may read stale data since write has not
been committed. [...]

Content analysis details: (-4.2 points, 5.0 required)

pts rule name description
---- ---------------------- --------------------------------------------------
-2.3 RCVD_IN_DNSWL_MED RBL: Sender listed at http://www.dnswl.org/, medium
trust
[69.43.206.106 listed in list.dnswl.org]
0.0 URIBL_BLOCKED ADMINISTRATOR NOTICE: The query to URIBL was blocked.
See
http://wiki.apache.org/spamassassin/DnsBlocklists#dnsbl-block
for more information.
[URIs: highlandsun.com]
-1.9 BAYES_00 BODY: Bayes spam probability is 0 to 1%
[score: 0.0000]
Post by Shu, Xinxin
Hi list ,
Recently I read docs about lmdb , there are two sentences
1) readers do not block writers
2) writers do not block readers
I can understand 'readers do not block writers' , but cannot
understand the second one , can someone help explain , how lmdb achieve
'writers do not block readers', below is my understandings , please
correct me if anything wrong.
Post by Shu, Xinxin
if the access pattern is write - read, since lmdb only support two
version of data , when the write has been started but not committed ,
the concurrent read may read stale data since write has not been committed.

This is fundamental to ACID transactions. The reader's data is not "stale" because in ACID, data doesn't actually exist until it's committed. This is what Atomicity and Isolation are all about.

Sounds to me like you have never used a real transactional database before; you need to do more reading on them because this is a very basic principle.
--
-- Howard Chu
CTO, Symas Corp. http://www.symas.com
Director, Highland Sun http://highlandsun.com/hyc/
Chief Architect, OpenLDAP http://www.openldap.org/project/
Loading...