Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

Pending transaction system resources #266

Merged
merged 8 commits into from
Jan 22, 2025
3 changes: 3 additions & 0 deletions koinos/broadcast/broadcast.proto
Original file line number Diff line number Diff line change
Expand Up @@ -11,6 +11,9 @@ message transaction_accepted {
protocol.transaction transaction = 1;
protocol.transaction_receipt receipt = 2;
uint64 height = 3 [jstype = JS_STRING];
uint64 system_disk_storage_used = 4;
uint64 system_network_bandwidth_used = 5;
uint64 system_compute_bandwidth_used = 6;
}

message transaction_failed {
Expand Down
15 changes: 11 additions & 4 deletions koinos/mempool/mempool.proto
Original file line number Diff line number Diff line change
Expand Up @@ -14,10 +14,17 @@ message address_resource_record {
uint64 current_rc = 2;
}

message pending_transaction_record {
message pending_transaction {
protocol.transaction transaction = 1;
uint64 disk_storage_used = 2 [jstype = JS_STRING];
uint64 network_bandwidth_used = 3 [jstype = JS_STRING];
uint64 compute_bandwidth_used = 4 [jstype = JS_STRING];
uint64 system_disk_storage_used = 5 [jstype = JS_STRING];
uint64 system_network_bandwidth_used = 6 [jstype = JS_STRING];
uint64 system_compute_bandwidth_used = 7 [jstype = JS_STRING];
}

message pending_transaction_record {
pending_transaction pending_transaction = 1;
uint64 timestamp = 2;
uint64 disk_storage_used = 3;
uint64 network_bandwidth_used = 4;
uint64 compute_bandwidth_used = 5;
}
10 changes: 2 additions & 8 deletions koinos/rpc/mempool/mempool_rpc.proto
Original file line number Diff line number Diff line change
Expand Up @@ -4,16 +4,10 @@ package koinos.rpc.mempool;
option go_package = "github.com/koinos/koinos-proto-golang/v2/koinos/rpc/mempool";

import "koinos/options.proto";
import "koinos/mempool/mempool.proto";
import "koinos/protocol/protocol.proto";
import "koinos/rpc/rpc.proto";

message pending_transaction {
protocol.transaction transaction = 1;
uint64 disk_storage_used = 2 [jstype = JS_STRING];
uint64 network_bandwidth_used = 3 [jstype = JS_STRING];
uint64 compute_bandwidth_used = 4 [jstype = JS_STRING];
}

message check_pending_account_resources_request {
bytes payer = 1 [(btype) = ADDRESS];
uint64 max_payer_rc = 2 [jstype = JS_STRING];
Expand All @@ -31,7 +25,7 @@ message get_pending_transactions_request {
}

message get_pending_transactions_response {
repeated pending_transaction pending_transactions = 1;
repeated koinos.mempool.pending_transaction pending_transactions = 1;
}

message check_account_nonce_request {
Expand Down