Skip to content
This repository was archived by the owner on Sep 27, 2019. It is now read-only.
This repository was archived by the owner on Sep 27, 2019. It is now read-only.

Mark Transaction as Read-Only When Executing Single-Statement SELECT #1395

Open
@apavlo

Description

@apavlo

If we get SELECT query in a single-statement txn, we should mark it as 'read-only'. This will avoid conflicts with other txns that are running at the same time.

I think the only place that we need to change is TrafficCop::ExecuteHelper():

https://github.com/cmu-db/peloton/blob/master/src/traffic_cop/traffic_cop.cpp#L163

I'm not sure how we can write a test case to prove that this is working correctly. I don't know whether we have test cases for running single-stmt txns in the TrafficCop and then being able to see the TransactionContext after the txn commits.

Metadata

Metadata

Assignees

No one assigned

    Labels

    Type

    No type

    Projects

    No projects

    Milestone

    No milestone

    Relationships

    None yet

    Development

    No branches or pull requests

    Issue actions