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
2 changes: 2 additions & 0 deletions Cargo.lock

Some generated files are not rendered by default. Learn more about how customized files appear on GitHub.

2 changes: 1 addition & 1 deletion Cargo.toml
Original file line number Diff line number Diff line change
Expand Up @@ -96,7 +96,7 @@ teloxide = { version = "0.13", features = ["macros"] }
thiserror = "1.0.49"
tikv-jemallocator = { version = "0.6", features = ["profiling"] }
tokio = { version = "1.43", features = ["full"] }
tokio-postgres = "0.7.10"
tokio-postgres = { version = "0.7.10", features = ["with-serde_json-1"]}
tokio-tungstenite = "0.27.0"
tonic = { version = "0.10", features = ["gzip"] }
tonic-build = "0.10"
Expand Down
1 change: 1 addition & 0 deletions crates/common/src/adjustments.rs
Original file line number Diff line number Diff line change
Expand Up @@ -15,4 +15,5 @@ pub struct DataAdjustmentsEntry {
pub adjusted_block_hash: B256,
pub adjusted_value: U256,
pub is_dry_run: bool,
pub metadata: serde_json::Value,
}
Original file line number Diff line number Diff line change
@@ -0,0 +1,2 @@
ALTER TABLE bid_adjustments
ADD COLUMN IF NOT EXISTS metadata JSONB;
6 changes: 4 additions & 2 deletions crates/relay/src/database/postgres/postgres_db_service.rs
Original file line number Diff line number Diff line change
Expand Up @@ -2250,10 +2250,11 @@ impl PostgresDatabaseService {
submitted_value,
adjusted_block_hash,
adjusted_value,
is_dry_run
is_dry_run,
metadata
)
VALUES
($1, $2, $3, $4, $5, $6, $7, $8, $9, $10)
($1, $2, $3, $4, $5, $6, $7, $8, $9, $10, $11)
",
&[
&(entry.slot.as_u64() as i64),
Expand All @@ -2266,6 +2267,7 @@ impl PostgresDatabaseService {
&entry.adjusted_block_hash.as_slice(),
&PostgresNumeric::from(entry.adjusted_value),
&entry.is_dry_run,
&entry.metadata,
],
)
.await?;
Expand Down