Skip to content
Merged
Show file tree
Hide file tree
Changes from all commits
Commits
Show all changes
34 commits
Select commit Hold shift + click to select a range
6a70752
port pingpong fix from feature branch.
tsachiherman Jul 27, 2021
55fdd4d
avoid assuming that the local transaction pool contain only locally s…
tsachiherman Jul 27, 2021
ec477f5
few refactoring changes
tsachiherman Jul 28, 2021
791a2d3
try to disable wait.
tsachiherman Jul 28, 2021
3edf72e
Merge branch 'master' into tsachi/fixmasterpingpong
tsachiherman Jul 31, 2021
de2e9df
update
tsachiherman Jul 31, 2021
7d28ee2
Adjust to 1sec debt
tsachiherman Jul 31, 2021
8c02d1c
background sync
tsachiherman Aug 1, 2021
d2d4ce6
Merge branch 'master' into tsachi/fixmasterpingpong
tsachiherman Aug 7, 2021
86d5f56
update pingpong
tsachiherman Aug 7, 2021
9f11ce0
fix few error checkings + typos.
tsachiherman Aug 7, 2021
b10b8e9
update
tsachiherman Aug 9, 2021
18dfafe
update
tsachiherman Aug 9, 2021
07fc93a
Merge branch 'master' into tsachi/fixmasterpingpong
tsachiherman Aug 10, 2021
cf27802
update pingpong
tsachiherman Aug 10, 2021
f2673b1
stage
tsachiherman Aug 11, 2021
9ee3144
avoid queuefull
tsachiherman Aug 11, 2021
3281b83
update
tsachiherman Aug 11, 2021
7a5c60b
update
tsachiherman Aug 12, 2021
8754632
Merge branch 'master' into tsachi/fixmasterpingpong
tsachiherman Aug 12, 2021
4acfd42
fix bug
tsachiherman Aug 12, 2021
03a1c0b
/
tsachiherman Aug 12, 2021
0d4ea2c
update
tsachiherman Aug 12, 2021
7e44500
few more changes.
tsachiherman Aug 12, 2021
0681907
prealloc array
tsachiherman Aug 13, 2021
33c2bac
Merge branch 'master' into tsachi/fixmasterpingpong
tsachiherman Aug 13, 2021
749bbf6
update
tsachiherman Aug 13, 2021
4da9930
fix few variable shadowings.
tsachiherman Aug 13, 2021
f2fc434
changes
tsachiherman Aug 13, 2021
95cd511
update
tsachiherman Aug 14, 2021
df74d07
update
tsachiherman Aug 14, 2021
9780c1d
commit
tsachiherman Aug 14, 2021
30ca217
update
tsachiherman Aug 14, 2021
3cf6368
rollback
tsachiherman Aug 14, 2021
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
10 changes: 10 additions & 0 deletions daemon/algod/api/client/restClient.go
Original file line number Diff line number Diff line change
Expand Up @@ -328,6 +328,10 @@ func (client RestClient) LedgerSupply() (response v1.Supply, err error) {
return
}

type pendingTransactionsByAddrParams struct {
Max uint64 `url:"max"`
}

type transactionsByAddrParams struct {
FirstRound uint64 `url:"firstRound"`
LastRound uint64 `url:"lastRound"`
Expand Down Expand Up @@ -359,6 +363,12 @@ func (client RestClient) TransactionsByAddr(addr string, first, last, max uint64
return
}

// PendingTransactionsByAddr returns all the pending transactions for a PK [addr].
func (client RestClient) PendingTransactionsByAddr(addr string, max uint64) (response v1.PendingTransactions, err error) {
err = client.get(&response, fmt.Sprintf("/v1/account/%s/transactions/pending", addr), pendingTransactionsByAddrParams{max})
return
}

// AssetInformation gets the AssetInformationResponse associated with the passed asset index
func (client RestClient) AssetInformation(index uint64) (response v1.AssetParams, err error) {
err = client.get(&response, fmt.Sprintf("/v1/asset/%d", index), nil)
Expand Down
10 changes: 10 additions & 0 deletions libgoal/libgoal.go
Original file line number Diff line number Diff line change
Expand Up @@ -881,6 +881,16 @@ func (c *Client) GetPendingTransactions(maxTxns uint64) (resp v1.PendingTransact
return
}

// GetPendingTransactionsByAddress gets a snapshot of current pending transactions on the node for the given address.
// If maxTxns = 0, fetches as many transactions as possible.
func (c *Client) GetPendingTransactionsByAddress(addr string, maxTxns uint64) (resp v1.PendingTransactions, err error) {
algod, err := c.ensureAlgodClient()
if err == nil {
resp, err = algod.PendingTransactionsByAddr(addr, maxTxns)
}
return
}

// ExportKey exports the private key of the passed account, assuming it's available
func (c *Client) ExportKey(walletHandle []byte, password, account string) (resp kmdapi.APIV1POSTKeyExportResponse, err error) {
kmd, err := c.ensureKmdClient()
Expand Down
Loading