vanilladb / vanillacore

The core engine of VanillaDB
Apache License 2.0
196 stars 41 forks source link

Cannot find the specified record #24

Closed SLMT closed 4 years ago

SLMT commented 7 years ago

While running TPC-C using VanillaBench with multiple RTEs, it is possible that transactions might not find the required records, which actually exist in the database.

What I Did

Running TPC-C benchmarks with following configurations:

Buffer Pool Size: 102400
# of RTEs: 25
Connection Mode: 2 (Stored Procedures)
Benchmarks: TPC-C (only New-Order transactions)
All other configurations remains default.

What I Expected To See

No exception.

Instead, what actually happened

This exception shows:

java.lang.RuntimeException: Query: 'SELECT d_tax, d_next_o_id FROM district WHERE d_w_id = 1 AND d_id = 9' fails.
    at org.vanilladb.bench.server.procedure.BasicStoredProcedure.executeQuery(BasicStoredProcedure.java:73)
    at org.vanilladb.bench.server.procedure.tpcc.NewOrderProc.executeSql(NewOrderProc.java:58)
    at org.vanilladb.bench.server.procedure.BasicStoredProcedure.execute(BasicStoredProcedure.java:44)
    at org.vanilladb.core.remote.storedprocedure.RemoteConnectionImpl.callStoredProc(RemoteConnectionImpl.java:47)
    at sun.reflect.GeneratedMethodAccessor3.invoke(Unknown Source)
    at sun.reflect.DelegatingMethodAccessorImpl.invoke(Unknown Source)
    at java.lang.reflect.Method.invoke(Unknown Source)
    at sun.rmi.server.UnicastServerRef.dispatch(Unknown Source)
    at sun.rmi.transport.Transport$1.run(Unknown Source)
    at sun.rmi.transport.Transport$1.run(Unknown Source)
    at java.security.AccessController.doPrivileged(Native Method)
    at sun.rmi.transport.Transport.serviceCall(Unknown Source)
    at sun.rmi.transport.tcp.TCPTransport.handleMessages(Unknown Source)
    at sun.rmi.transport.tcp.TCPTransport$ConnectionHandler.run0(Unknown Source)
    at sun.rmi.transport.tcp.TCPTransport$ConnectionHandler.lambda$run$0(Unknown Source)
    at java.security.AccessController.doPrivileged(Native Method)
    at sun.rmi.transport.tcp.TCPTransport$ConnectionHandler.run(Unknown Source)
    at java.util.concurrent.ThreadPoolExecutor.runWorker(Unknown Source)
    at java.util.concurrent.ThreadPoolExecutor$Worker.run(Unknown Source)
    at java.lang.Thread.run(Unknown Source)

If it used a lower buffer pool size, there would be higher chance to happen this.