ore_pool_api/state/pool.rs
1use steel::*;
2
3use super::AccountDiscriminator;
4
5/// Pool tracks global lifetime stats about the mining pool.
6#[repr(C)]
7#[derive(Clone, Copy, Debug, PartialEq, Pod, Zeroable)]
8pub struct Pool {
9 /// The authority of this pool.
10 pub authority: Pubkey,
11
12 /// The bump used for signing CPIs.
13 #[deprecated(since = "0.1.3", note = "Bumps are no longer required")]
14 pub bump: u64,
15
16 /// The url where hashes should be submitted (right padded with 0s).
17 pub url: [u8; 128],
18
19 /// The latest attestation posted by this pool operator.
20 pub attestation: [u8; 32],
21
22 /// Foreign key to the ORE proof account.
23 pub last_hash_at: i64,
24
25 /// The net sum of rewards claimable by members in the pool.
26 pub total_rewards: u64,
27
28 /// The total number of hashes this pool has submitted.
29 pub total_submissions: u64,
30
31 /// The total number of members in this pool.
32 pub total_members: u64,
33
34 /// The total number of members in this pool at the last submission.
35 pub last_total_members: u64,
36}
37
38account!(AccountDiscriminator, Pool);