Skip to content

Commit 760c898

Browse files
authored
fix: add key variant back to wal to fix bitcode deserialization (#26453)
1 parent 6e9446a commit 760c898

File tree

5 files changed

+8
-0
lines changed

5 files changed

+8
-0
lines changed

influxdb3_cache/src/distinct_cache/cache.rs

Lines changed: 1 addition & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -469,6 +469,7 @@ impl From<&FieldData> for Value {
469469
| FieldData::UInteger(_)
470470
| FieldData::Float(_)
471471
| FieldData::Boolean(_) => panic!("unexpected field type for distinct value cache"),
472+
FieldData::Key(_) => unreachable!("key type should never be constructed"),
472473
}
473474
}
474475
}

influxdb3_cache/src/last_cache/cache.rs

Lines changed: 2 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -679,6 +679,7 @@ impl From<&FieldData> for KeyValue {
679679
FieldData::Boolean(b) => Self::Bool(*b),
680680
FieldData::Timestamp(_) => panic!("unexpected time stamp as key value"),
681681
FieldData::Float(_) => panic!("unexpected float as key value"),
682+
FieldData::Key(_) => unreachable!("key type should never be constructed"),
682683
}
683684
}
684685
}
@@ -1140,5 +1141,6 @@ fn data_type_from_buffer_field(field: &Field) -> InfluxColumnType {
11401141
FieldData::UInteger(_) => InfluxColumnType::Field(InfluxFieldType::UInteger),
11411142
FieldData::Float(_) => InfluxColumnType::Field(InfluxFieldType::Float),
11421143
FieldData::Boolean(_) => InfluxColumnType::Field(InfluxFieldType::Boolean),
1144+
FieldData::Key(_) => unreachable!("key type should never be constructed"),
11431145
}
11441146
}

influxdb3_py_api/src/system_py.rs

Lines changed: 3 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -565,6 +565,9 @@ pub fn execute_python_with_batch(
565565
.set_item(field_name.as_ref(), t)
566566
.context("failed to set timestamp")?;
567567
}
568+
FieldData::Key(_) => {
569+
unreachable!("key type should never be constructed")
570+
}
568571
};
569572
}
570573

influxdb3_wal/src/lib.rs

Lines changed: 1 addition & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -387,6 +387,7 @@ pub struct Row {
387387
#[derive(Clone, Debug, Serialize, Deserialize)]
388388
pub enum FieldData {
389389
Timestamp(i64),
390+
Key(String),
390391
Tag(String),
391392
String(String),
392393
Integer(i64),

influxdb3_write/src/write_buffer/table_buffer.rs

Lines changed: 1 addition & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -331,6 +331,7 @@ impl MutableTableChunk {
331331
panic!("unexpected field type");
332332
}
333333
}
334+
FieldData::Key(_) => unreachable!("key type should never be constructed"),
334335
}
335336
}
336337

0 commit comments

Comments
 (0)