This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
// LogicalPlan is a logical representation of a query. Each LogicalPlan is a | |
// sub-tree of the query. It is built recursively. | |
type LogicalPlan struct { | |
Input *LogicalPlan | |
// Each LogicalPlan struct must only have one of the following. | |
SchemaScan *SchemaScan | |
TableScan *TableScan | |
Filter *Filter | |
Distinct *Distinct |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
/** | |
* Returns a heap-allocated iterator over the contents of the | |
* database. | |
* <p> | |
* Caller should close the iterator when it is no longer needed. | |
* The returned iterator should be closed before this db is closed. | |
* <p> | |
* <pre> | |
* KVIterator it = unsafeLocalIterator(); | |
* try { |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
public class DefaultRheaKVStore implements RheaKVStore { | |
private static final Logger LOG = LoggerFactory | |
.getLogger(DefaultRheaKVStore.class); | |
static { | |
ExtSerializerSupports.init(); | |
} | |
private final StateListenerContainer<Long> stateListenerContainer = new StateListenerContainer<>(); |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
* <pre> | |
* 1. The first step is to filter out region1, region2, and region3 from the routing table. | |
* | |
* ┌─────────────────┐ ┌─────────────────┐ | |
* │ scan startKey │ │ scan endKey │ | |
* └────────┬────────┘ └────────┬────────┘ | |
* │ │ | |
* │ │ | |
* │ │ | |
* ┌ ─ ─ ─ ─ ─ ─ ─ ─ ─ │ ┌ ─ ─ ─ ─ ─ ─ ┐ ┌ ─ ─ ─ ─ ─ ─ ┐ │ ┌ ─ ─ ─ ─ ─ ─ ┐ |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
/** | |
* Returns current placement driver client instance. | |
*/ | |
PlacementDriverClient getPlacementDriverClient(); |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
/** | |
* Add a listener for the state change of the leader with | |
* this region. | |
* <p> | |
* In a special case, if that is a single region environment, | |
* then regionId = -1 as the input parameter. | |
*/ | |
void addLeaderStateListener(final long regionId, final LeaderStateListener listener); | |
/** |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
/** | |
* Creates a distributed lock implementation that provides | |
* exclusive access to a shared resource. | |
* <p> | |
* <pre> | |
* DistributedLock<byte[]> lock = ...; | |
* if (lock.tryLock()) { | |
* try { | |
* // manipulate protected state | |
* } finally { |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
* <pre> | |
* ┌────────────────────────────┐ | |
* │ │ | |
* │ RheaKVStore │────────────────┐ | |
* │ │ │ | |
* └────────────────────────────┘ ▼ | |
* │ ▲ ┌────────────────────────────┐ | |
* │ │ │ PlacementDriverClient │ | |
* │ │ └────────────────────────────┘ | |
* │ │ │ |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
struct MinStack { | |
stack: Vec< (i32, i32) >, | |
min: i32, | |
} | |
/** | |
* `&self` means the method takes an immutable reference. | |
* If you need a mutable reference, change it to `&mut self` instead. | |
*/ |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
use crate::{Connection, Frame}; | |
use tracing::{debug, instrument}; | |
/// Represents an "unknown" command. This is not a real `Redis` command. | |
#[derive(Debug)] | |
pub struct Unknown { | |
command_name: String, | |
} |
NewerOlder