make SubscribeRequest forward-compatible
This commit is contained in:
parent
1d1a01c8ae
commit
193a1b6878
32
src/lib.rs
32
src/lib.rs
|
@ -100,15 +100,9 @@ impl GeyserFilter {
|
||||||
);
|
);
|
||||||
|
|
||||||
SubscribeRequest {
|
SubscribeRequest {
|
||||||
slots: HashMap::new(),
|
|
||||||
accounts: Default::default(),
|
|
||||||
transactions: HashMap::new(),
|
|
||||||
entry: Default::default(),
|
|
||||||
blocks: blocks_subs,
|
blocks: blocks_subs,
|
||||||
blocks_meta: HashMap::new(),
|
|
||||||
commitment: Some(map_commitment_level(self.0) as i32),
|
commitment: Some(map_commitment_level(self.0) as i32),
|
||||||
accounts_data_slice: Default::default(),
|
..Default::default()
|
||||||
ping: None,
|
|
||||||
}
|
}
|
||||||
}
|
}
|
||||||
|
|
||||||
|
@ -117,15 +111,9 @@ impl GeyserFilter {
|
||||||
blocksmeta_subs.insert("client".to_string(), SubscribeRequestFilterBlocksMeta {});
|
blocksmeta_subs.insert("client".to_string(), SubscribeRequestFilterBlocksMeta {});
|
||||||
|
|
||||||
SubscribeRequest {
|
SubscribeRequest {
|
||||||
slots: HashMap::new(),
|
|
||||||
accounts: Default::default(),
|
|
||||||
transactions: HashMap::new(),
|
|
||||||
entry: Default::default(),
|
|
||||||
blocks: HashMap::new(),
|
|
||||||
blocks_meta: blocksmeta_subs,
|
blocks_meta: blocksmeta_subs,
|
||||||
commitment: Some(map_commitment_level(self.0) as i32),
|
commitment: Some(map_commitment_level(self.0) as i32),
|
||||||
accounts_data_slice: Default::default(),
|
..Default::default()
|
||||||
ping: None,
|
|
||||||
}
|
}
|
||||||
}
|
}
|
||||||
|
|
||||||
|
@ -140,14 +128,8 @@ impl GeyserFilter {
|
||||||
|
|
||||||
SubscribeRequest {
|
SubscribeRequest {
|
||||||
slots: slots_subs,
|
slots: slots_subs,
|
||||||
accounts: Default::default(),
|
|
||||||
transactions: HashMap::new(),
|
|
||||||
entry: Default::default(),
|
|
||||||
blocks: HashMap::new(),
|
|
||||||
blocks_meta: HashMap::new(),
|
|
||||||
commitment: Some(map_commitment_level(self.0) as i32),
|
commitment: Some(map_commitment_level(self.0) as i32),
|
||||||
accounts_data_slice: Default::default(),
|
..Default::default()
|
||||||
ping: None,
|
|
||||||
}
|
}
|
||||||
}
|
}
|
||||||
|
|
||||||
|
@ -163,15 +145,9 @@ impl GeyserFilter {
|
||||||
);
|
);
|
||||||
|
|
||||||
SubscribeRequest {
|
SubscribeRequest {
|
||||||
slots: HashMap::new(),
|
|
||||||
accounts: accounts_subs,
|
accounts: accounts_subs,
|
||||||
transactions: HashMap::new(),
|
|
||||||
entry: Default::default(),
|
|
||||||
blocks: Default::default(),
|
|
||||||
blocks_meta: HashMap::new(),
|
|
||||||
commitment: Some(map_commitment_level(self.0) as i32),
|
commitment: Some(map_commitment_level(self.0) as i32),
|
||||||
accounts_data_slice: Default::default(),
|
..Default::default()
|
||||||
ping: None,
|
|
||||||
}
|
}
|
||||||
}
|
}
|
||||||
}
|
}
|
||||||
|
|
Loading…
Reference in New Issue