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

En 12318 gascost txs frozen #4159

Merged
merged 8 commits into from
Jun 21, 2022
Merged

Conversation

AdoAdoAdo
Copy link
Contributor

@AdoAdoAdo AdoAdoAdo commented Jun 3, 2022

This PR adds an increase in the gas limit for guarded transactions, since there is extra processing for guardian signature verification.

@AdoAdoAdo AdoAdoAdo marked this pull request as ready for review June 3, 2022 12:26
@@ -66,6 +70,7 @@
# it is a good idea to increase the maximum number of opened files allowed by the operating system
FullArchiveNumActivePersisters = 10


Copy link
Contributor

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

remove empty line?

Copy link
Contributor Author

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

done

log.Trace("creating economics data components")
argsNewEconomicsData := economics.ArgsNewEconomicsData{
Economics: &ccf.economicsConfig,
PenalizedTooMuchGasEnableEpoch: ccf.epochConfig.EnableEpochs.PenalizedTooMuchGasEnableEpoch,
GasPriceModifierEnableEpoch: ccf.epochConfig.EnableEpochs.GasPriceModifierEnableEpoch,
EpochNotifier: epochNotifier,
BuiltInFunctionsCostHandler: builtInCostHandler,
TxVersionChecker: txVersionChecker,
Copy link
Contributor

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

a little strange why an "economics handler, whatever" depends upon the transaction version checker.
Understood why it has been done, not having a great suggestion if or how to refactor. Can be left as it is.

mutGasLimitSettings sync.RWMutex
gasPerDataByte uint64
minGasPrice uint64
extraGasLimitGuardedTx uint64
Copy link
Contributor

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

move this also in gasConfig struct?

Copy link
Contributor Author

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

done


args.EpochNotifier.RegisterNotifyHandler(ed)

return ed, nil
}

func (ed *economicsData) setGasLimitSetting(gasLimitSetting config.GasLimitSetting) error {
Copy link
Contributor

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

👍
remained as technical debt this refactor from our last change

@AdoAdoAdo AdoAdoAdo merged commit 707bf7c into feat/freeze-account Jun 21, 2022
@AdoAdoAdo AdoAdoAdo deleted the EN-12318-gascost-txs-frozen branch June 21, 2022 11:54
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
None yet
Projects
None yet
Development

Successfully merging this pull request may close these issues.

3 participants