mirror of
https://github.com/neondatabase/neon.git
synced 2025-12-22 21:59:59 +00:00
@@ -1539,7 +1539,7 @@ pub struct OffloadedTimelineInfo {
|
||||
pub archived_at: chrono::DateTime<chrono::Utc>,
|
||||
}
|
||||
|
||||
/// The state of the rel size migration. This is persisted in the DbDir key and index part. Do not change without considering
|
||||
/// The state of the rel size migration. This is persisted in the index part.
|
||||
/// compatibility.
|
||||
#[derive(Default, Debug, Clone, PartialEq, Eq, Serialize, Deserialize)]
|
||||
#[serde(rename_all = "camelCase")]
|
||||
|
||||
@@ -83,7 +83,6 @@ pub struct IndexPart {
|
||||
#[serde(skip_serializing_if = "Option::is_none", default)]
|
||||
pub(crate) last_aux_file_policy: Option<AuxFilePolicy>,
|
||||
|
||||
/// Deprecated: the field is not used anymore and the source of truth is now stored in the dbdir key.
|
||||
#[serde(skip_serializing_if = "Option::is_none", default)]
|
||||
pub(crate) rel_size_migration: Option<RelSizeMigration>,
|
||||
|
||||
@@ -116,7 +115,6 @@ pub struct IndexPart {
|
||||
#[serde(skip_serializing_if = "Option::is_none", default)]
|
||||
pub(crate) marked_invisible_at: Option<NaiveDateTime>,
|
||||
|
||||
/// Deprecated: the field is not used anymore and the source of truth is now stored in the dbdir key.
|
||||
#[serde(skip_serializing_if = "Option::is_none", default)]
|
||||
pub(crate) rel_size_migrated_at: Option<Lsn>,
|
||||
}
|
||||
|
||||
@@ -2883,10 +2883,9 @@ impl Timeline {
|
||||
.unwrap_or(self.conf.default_tenant_conf.compaction_threshold)
|
||||
}
|
||||
|
||||
/// Returns the expected state of the rel size migration. The actual state is persisted in the
|
||||
/// DbDir key.
|
||||
///
|
||||
/// The expected state is the state that the tenant config expects.
|
||||
/// Returns `true` if the rel_size_v2 config is enabled. NOTE: the write path and read path
|
||||
/// should look at `get_rel_size_v2_status()` to get the actual status of the timeline. It is
|
||||
/// possible that the index part persists the state while the config doesn't get persisted.
|
||||
pub(crate) fn get_rel_size_v2_expected_state(&self) -> RelSizeMigration {
|
||||
let tenant_conf = self.tenant_conf.load();
|
||||
let v2_enabled = tenant_conf
|
||||
|
||||
Reference in New Issue
Block a user