Skip to content

getBundlesFromAddresses deprecation #309

@Cylix

Description

@Cylix

From #304 (iota.lib.js changes):

getBundlesFromAddresses() is deprecated and will probably be removed in next major version.
Reason for deprecating is poor performance; number of bundle instances can be any, and fetching all bundles lazily is preferred for most use cases. I think that findTransactions() on addresses is fine for most cases.
getTransfers() is deprecated
calls getBundlesFromAddresses
transfers field of getAccountData() is deprecated
Reason for this is internal getBundlesFromAddresses call to fetch full bundles. transactions field was added as replacement which contains transactions (instead of bundles) as returned by findTransactions() on account addresses. (https://github.com/iotaledger/iota.lib.js/blob/next/packages/core/src/createGetAccountData.ts#L154)

Everything is kind of related here and change sounds reasonable for the performance issues.
We already tried to have some improvements for getBundlesFromAddresses, but there is not so much room for improvement as most of the performance is bound by IRI execution time.

Metadata

Metadata

Assignees

No one assigned

    Labels

    A-APIArea - APIC-enhancementCategory - EnhancementD-easyDifficulty - EasyP-mediumPriority - Medium

    Projects

    No projects

    Milestone

    Relationships

    None yet

    Development

    No branches or pull requests

    Issue actions