Skip to content

ContractCreateFlow creates a file for smaller initcode #1746

@steven-sheehy

Description

@steven-sheehy

Problem

The ContractCreateFlow does not take advantage of newer features of HAPI to reduce the number and cost of transactions. Same issue in all SDKs.

Solution

  • The initcode file is created unconditionally instead of directly using ContractCreateTransaction.bytecode if it fits within a single transaction. File append and delete would likewise not be needed if bytecode is populated.
  • FileCreateTransaction partial bytecode is limited to 2048 instead of a larger size closer to max HAPI size 6 KiB
  • FileAppendTransaction sets chunk size to 2048 instead of a size closer to max HAPI size 6 KiB

Alternatives

No response

Metadata

Metadata

Assignees

Labels

enhancementNew feature or request

Type

No type

Projects

No projects

Milestone

No milestone

Relationships

None yet

Development

No branches or pull requests

Issue actions