Skip to content
Merged
Show file tree
Hide file tree
Changes from all commits
Commits
File filter

Filter by extension

Filter by extension

Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view
4 changes: 4 additions & 0 deletions be/src/olap/rowset/alpha_rowset.cpp
Original file line number Diff line number Diff line change
Expand Up @@ -277,6 +277,10 @@ int64_t AlphaRowset::txn_id() const {
return _rowset_meta->txn_id();
}

int64_t AlphaRowset::partition_id() const {
return _rowset_meta->partition_id();
}

bool AlphaRowset::delete_flag() {
return _rowset_meta->delete_flag();
}
Expand Down
2 changes: 2 additions & 0 deletions be/src/olap/rowset/alpha_rowset.h
Original file line number Diff line number Diff line change
Expand Up @@ -105,6 +105,8 @@ class AlphaRowset : public Rowset {

int64_t txn_id() const override;

int64_t partition_id() const override;

// flag for push delete rowset
bool delete_flag() override;

Expand Down
2 changes: 2 additions & 0 deletions be/src/olap/rowset/rowset.h
Original file line number Diff line number Diff line change
Expand Up @@ -112,6 +112,8 @@ class Rowset : public std::enable_shared_from_this<Rowset> {
virtual PUniqueId load_id() const = 0;

virtual int64_t txn_id() const = 0;

virtual int64_t partition_id() const = 0;

// flag for push delete rowset
virtual bool delete_flag() = 0;
Expand Down
2 changes: 1 addition & 1 deletion be/src/olap/schema_change.cpp
Original file line number Diff line number Diff line change
Expand Up @@ -1425,7 +1425,7 @@ OLAPStatus SchemaChangeHandler::schema_version_convert(
RowsetWriterContext writer_context;
writer_context.rowset_id = rowset_id;
writer_context.tablet_id = new_tablet->tablet_id();
writer_context.partition_id = new_tablet->partition_id();
writer_context.partition_id = (*base_rowset)->partition_id();
writer_context.tablet_schema_hash = new_tablet->schema_hash();
writer_context.rowset_type = ALPHA_ROWSET;
writer_context.rowset_path_prefix = new_tablet->tablet_path();
Expand Down
10 changes: 6 additions & 4 deletions be/src/olap/txn_manager.cpp
Original file line number Diff line number Diff line change
Expand Up @@ -124,10 +124,12 @@ OLAPStatus TxnManager::commit_txn(
OlapMeta* meta, TPartitionId partition_id, TTransactionId transaction_id,
TTabletId tablet_id, SchemaHash schema_hash,
const PUniqueId& load_id, RowsetSharedPtr rowset_ptr, bool is_recovery) {
DCHECK(partition_id > 0);
DCHECK(transaction_id > 0);
DCHECK(tablet_id > 0);
DCHECK(rowset_ptr != nullptr);
if (partition_id < 1 || transaction_id < 1 || tablet_id < 1) {
LOG(FATAL) << "invalid commit req "
<< " partition_id=" << partition_id
<< " transaction_id=" << transaction_id
<< " tablet_id=" << tablet_id;
}
pair<int64_t, int64_t> key(partition_id, transaction_id);
TabletInfo tablet_info(tablet_id, schema_hash);
if (rowset_ptr == nullptr) {
Expand Down
1 change: 1 addition & 0 deletions build.sh
Original file line number Diff line number Diff line change
Expand Up @@ -32,6 +32,7 @@ ROOT=`dirname "$0"`
ROOT=`cd "$ROOT"; pwd`

export DORIS_HOME=${ROOT}
export BUILD_TYPE=DEBUG
#export BUILD_TYPE=ASAN

. ${DORIS_HOME}/env.sh
Expand Down