Re: Reg: SimpleDBM Control Flow and its working

4 views
Skip to first unread message

Dibyendu Majumdar

unread,
Jul 30, 2007, 8:32:26 PM7/30/07
to @<<RaMaVtAr>>@, simp...@googlegroups.com
Hi,

I shall be happy to help.
Please let me know exactly what you want to understand.
The main resources for understanding SimpleDBM are:

https://simpledbm.dev.java.net/servlets/ProjectDocumentList?folderID=4214&expandFolder=4214&folderID=0
http://code.google.com/p/simpledbm/downloads/list
http://simpledbm.blogspot.com/

Please would you join the SimpleDBM user mailing list
(http://groups.google.co.uk/group/simpledbm?hl=en-GB) and post your
questions there.

Thanks

@<<RaMaVtAr>>@ wrote:
>
>
>
>
> Respected Sir,
>
> I am Ramavtar Choudhary doing my Btech in computer science from
> IIIT-Hyderabad, India. As a part of my final year project , i have to
> compare
> performance of two phase locking protocol with a new protocol
> proposed by my
> professor, in some DBMS .We chose Derby but were not able to
> understand its
> control flow completely(interaction between various modules). We
> found out
> that SImpleDBM is similar to derby and so we decided to understand the
> functioning of SImpleDBM first created by you.
>
> It will be very kind of you if you suggest/provide some useful
> resources
> related to SimpleDBM control flow.
> We looked at src code of modules at following link:
> http://simpledbm.googlecode.com/svn/trunk/
>
>
> Thank you in anticipation
>
> Regards..
>
> Ramavtar Choudhary
> CSE, IIIT-Hyderabad
>
>
>
>
>
>
>

Ramavtar

unread,
Jul 31, 2007, 3:08:33 PM7/31/07
to SimpleDBM User Group

Sir

My project objective is to compare performance of two-phase locking
protocol and speculative locking protocol for read only transaction in
any DBMS.

Speculative Locking: http://portal.acm.org/citation.cfm?id=962744

In 2PL,even though a transaction produces a after image during its
exexcution, lock on data objects are released only after the
completion of 2PC.In Speclative locking, waiting transaction is
allowed
to access locked data objects whenever lock-holding transaction
produces corresponding after images during execution. By accessing
both before-and after-image , waiting transaction carries out
speculative executions and retains one execution based on termination
decision of preceding transaction.In this protocol, we have one more
locking mode, apart from S(share) and X(exclusive), called
'SPW'(speculative)

As of now , I have to implement this for 1 update and many-read
concurrent transactions.

I have chosen to work on SimpleDBM for this.Will it be possible to
implement in it and test peformance in SimpleDBM.

How can i get after-image of data object as soon as it is created.

Regards..

Ramavtar

1 Jul, 05:32, Dibyendu Majumdar <dibye...@mazumdar.demon.co.uk>
wrote:


> Hi,
>
> I shall be happy to help.
> Please let me know exactly what you want to understand.
> The main resources for understanding SimpleDBM are:
>

> https://simpledbm.dev.java.net/servlets/ProjectDocumentList?folderID=...http://code.google.com/p/simpledbm/downloads/listhttp://simpledbm.blogspot.com/

d.maj...@gmail.com

unread,
Aug 1, 2007, 6:13:55 AM8/1/07
to SimpleDBM User Group
> Speculative Locking: http://portal.acm.org/citation.cfm?id=962744

Cannot access the document ... but I assume you can fill me in with
the details.

> In 2PL,even though a transaction produces a after image during its
> exexcution, lock on data objects are released only after the
> completion of 2PC.In Speclative locking, waiting transaction is
> allowed
> to access locked data objects whenever lock-holding transaction
> produces corresponding after images during execution. By accessing
> both before-and after-image , waiting transaction carries out
> speculative executions and retains one execution based on termination
> decision of preceding transaction.In this protocol, we have one more
> locking mode, apart from S(share) and X(exclusive), called
> 'SPW'(speculative)
>
> As of now , I have to implement this for 1 update and many-read
> concurrent transactions.
>

> How can i get after-image of data object as soon as it is created.

I don't know whether you will be able to modify SimpleDBM to implement
the speculative locking model. But I will help with you with
understanding
how SimpleDBM works so that you can judge for yourself.

SimpleDBM uses standard 2PL. Locks are released when the transaction
commits or aborts.

Transaction log records are created when SimpleDBM makes a change
to any of the pages in the database. However, the logging is
physiological.
This means that log records are page specific, but they describe the
page
level changes in a logical way. Also, in the case of BTree indexes,
the pages can be split or merged even during a transaction - so that
means
that the log records may no longer be related to the original page.

I think that in order for me to help you, you will first need to
understand
how the logging works, how transaction redo/undo works. Once you have
a
good understanding, you can then determine what changes will be needed
to support speculative locking.

Regards

Ramavtar

unread,
Aug 1, 2007, 6:39:45 AM8/1/07
to SimpleDBM User Group
Sir

I have uploaded speculative locking pdf. In this pdf, SL is for
distributed database.

Regards..

Link: http://groups.google.co.uk/group/simpledbm/web/tkde_spec.pdf

d.maj...@gmail.com

unread,
Aug 1, 2007, 9:29:13 AM8/1/07
to SimpleDBM User Group
> I have uploaded speculative locking pdf. In this pdf, SL is for
> distributed database.

Thanks. I have had a quick look. My first impression is that the paper
describes at a very high level the principles behind the speculative
locking protocol, but it does not really go into the detail of how
this protocol will work.

Given this situation, it will not be easy for you to implement this
in SimpleDBM because you will have to work out modifications
to many algorithms. I would therefore suggest that you take a
simpler approach for this. Use only parts of SimpleDBM - such as
the transaction manager, the lock manager, the log manager, etc.
But then create your own simple transactional resource - maybe
a file containing fixed size records, and then work on that. This
will make it easier for you because the transaction recovery for a
simple fixed size record file will be easier to handle.

Once you have implemented something simple like this - you will
be able to then extend it with speculative locking.

Let me know how this sounds.

Regards

Dibyendu

Ramavtar

unread,
Aug 7, 2007, 10:05:22 AM8/7/07
to SimpleDBM User Group
Hello,
We gone through different modules in SimpleDBM. We will be able to
implement
our protocol in your system, but we have just one doubt. Since sql
module is not there, how we will test
performance of SL protocol and compare it with strict 2pl.

d.maj...@gmail.com

unread,
Aug 9, 2007, 2:52:38 PM8/9/07
to SimpleDBM User Group
Hi,

You can test by writing some client programs. See the samples - such
as tupledemo.

Regards

> > Dibyendu- Hide quoted text -
>
> - Show quoted text -

Reply all
Reply to author
Forward
0 new messages