KVell icon indicating copy to clipboard operation
KVell copied to clipboard

About the YCSB+T benchmark

Open morcelicaio opened this issue 2 years ago • 5 comments

Hi, @BLepers .

I have a question about the implementation of YCSB+T.

Where did you get the latest YCSB+T project?

The only place I can find to fork it is on Akon Dey's github. https://github.com/akon-dey/YCSB

Could you help me to implement the ycsb+t benchmark correctly?

In his article he reports having such methods:

" • doTransactionInsert() creates a new account with an initial balance captured from doTransactionDelete() operation described below.

• doTransactionRead() reads a set of account balances determined by the key generator.

• doTransactionScan() scans the database given the start key and the number of records and fetches them from the data base.

• doTransactionUpdate() reads a record and add $1 from the balance captured from delete operations to it and write it back.

• doTransactionDelete() reads an account record, add the amount to the captured the balance (capture used in doTransactionInsert()) and then deletes the record.

• doTransactionReadModifyWrite() reads two records, subtracts $1 from the one of the two and adds $1 to the other before writing them both back. "

In the akon repository where I made the fork, I didn't find the implementation of the methods doTransactionInsert() , doTransactionRead() , doTransactionScan() , doTransactionUpdate() and doTransactionDelete().

I just noticed that the doTransactionReadModifyWrite() method is implemented, where it subtracts the value 1 from account A and assigns that value to account B.

Could you help me understand this part of the implementation?

Regards, Caio

morcelicaio avatar Dec 03 '22 02:12 morcelicaio

The implementation of YCSB-T is in the OSDI branch -- https://github.com/BLepers/KVell/blob/osdi/workload-transactions.c#L92

Basically we just wrapped batches of 16 YCSB queries in transactions. YCSB-T is not an official benchmark, so there's a bit of room for implementation. The goal is just to have a simple workload to understand the performance/overhead of transactions :)

BLepers avatar Dec 03 '22 09:12 BLepers

Thanks for the feedback, @BLepers .

So, in my case, I took the code from Akon's repository and didn't make any changes because in his paper he already says that he extended ycsb already with the transactional layer. In case I need to change something in the code? Can I use the way it is there and call the workloads?

Can you help me ? I really need to get this to work. I know it's not a scary thing to do, but it would really help me if someone helped me.

In my case I'm going to do tests with MongoDB.

I'm calling the MongoDBclient.java class (which already comes in the repository) to make calls to my cluster (it's in MongoDB Atlas).

I'm managing to use the benchmark normally, but I don't know if the default implementation of YCSB+T is working with transactions in MongoDB.

Regards, Caio

morcelicaio avatar Dec 03 '22 14:12 morcelicaio

Hi, @BLepers.

Do you have any suggestions about what I told you?

Regards, Caio

morcelicaio avatar Dec 16 '22 00:12 morcelicaio

I pointed you to our implementation. If you want anything more you'll have to implement it yourself and/or hire someone to do it for you.

BLepers avatar Dec 16 '22 06:12 BLepers

Hi, @BLepers .

In my case, I'm going to use the YCSB+T closed economy workload to do consistency testing on MongoDB.

As I understand it, this workload is already implemented. I also noticed that it has those start() , commit() and abort() methods.

Did you ever notice these methods when you did your tests? I noticed that they were empty and I didn't understand what they were there for.

Do you have any idea why?

I'd just like to understand better because I'll do the implementation myself if I need to.

For now, I'm just clearing up these doubts even with the people who got to work with the YCSB+T.

Regards, Caio

morcelicaio avatar Dec 17 '22 14:12 morcelicaio