Skip to content

Commit

Permalink
[indexer] alter public key to use text type. (#499)
Browse files Browse the repository at this point in the history
* alter public key to use text type.

* fix linter.
  • Loading branch information
larry-aptos authored Sep 4, 2024
1 parent 33f8836 commit 9200855
Show file tree
Hide file tree
Showing 4 changed files with 8 additions and 2 deletions.
Original file line number Diff line number Diff line change
@@ -0,0 +1,3 @@
-- This file should undo anything in `up.sql`
ALTER TABLE signatures
ALTER COLUMN public_key TYPE VARCHAR(136);
Original file line number Diff line number Diff line change
@@ -0,0 +1,3 @@
-- Your SQL goes here
ALTER TABLE signatures
ALTER COLUMN public_key TYPE TEXT;
3 changes: 1 addition & 2 deletions rust/processor/src/db/postgres/schema.rs
Original file line number Diff line number Diff line change
Expand Up @@ -963,8 +963,7 @@ diesel::table! {
is_sender_primary -> Bool,
#[sql_name = "type"]
type_ -> Varchar,
#[max_length = 136]
public_key -> Varchar,
public_key -> Text,
signature -> Text,
threshold -> Int8,
public_key_indices -> Jsonb,
Expand Down
1 change: 1 addition & 0 deletions rust/processor/src/processors/mod.rs
Original file line number Diff line number Diff line change
Expand Up @@ -99,6 +99,7 @@ pub trait ProcessorTrait: Send + Sync + Debug {

/// Gets the connection.
/// If it was unable to do so (default timeout: 30s), it will keep retrying until it can.
#[allow(elided_named_lifetimes)]
async fn get_conn(&self) -> DbPoolConnection {
let pool = self.connection_pool();
loop {
Expand Down

0 comments on commit 9200855

Please sign in to comment.