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

Rename MAX_CONSOLIDATIONS to MAX_CONSOLIDATION_REQUESTS_PER_PAYLOAD #8391

Merged
Merged
Show file tree
Hide file tree
Changes from all commits
Commits
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
Original file line number Diff line number Diff line change
Expand Up @@ -56,7 +56,7 @@ static SpecConfigElectra required(final SpecConfig specConfig) {

int getMaxAttestationsElectra();

int getMaxConsolidations();
int getMaxConsolidationRequestsPerPayload();

int getMaxDepositReceiptsPerPayload();

Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -34,7 +34,7 @@ public class SpecConfigElectraImpl extends DelegatingSpecConfigDeneb implements
private final int whistleblowerRewardQuotientElectra;
private final int maxAttesterSlashingsElectra;
private final int maxAttestationsElectra;
private final int maxConsolidations;
private final int maxConsolidationRequestsPerPayload;
private final int maxDepositReceiptsPerPayload;
private final int maxWithdrawalRequestsPerPayload;
private final int maxPendingPartialsPerWithdrawalsSweep;
Expand All @@ -53,7 +53,7 @@ public SpecConfigElectraImpl(
final int whistleblowerRewardQuotientElectra,
final int maxAttesterSlashingsElectra,
final int maxAttestationsElectra,
final int maxConsolidations,
final int maxConsolidationRequestsPerPayload,
final int maxDepositReceiptsPerPayload,
final int maxWithdrawalRequestsPerPayload,
final int maxPendingPartialsPerWithdrawalsSweep) {
Expand All @@ -70,7 +70,7 @@ public SpecConfigElectraImpl(
this.whistleblowerRewardQuotientElectra = whistleblowerRewardQuotientElectra;
this.maxAttesterSlashingsElectra = maxAttesterSlashingsElectra;
this.maxAttestationsElectra = maxAttestationsElectra;
this.maxConsolidations = maxConsolidations;
this.maxConsolidationRequestsPerPayload = maxConsolidationRequestsPerPayload;
this.maxDepositReceiptsPerPayload = maxDepositReceiptsPerPayload;
this.maxWithdrawalRequestsPerPayload = maxWithdrawalRequestsPerPayload;
this.maxPendingPartialsPerWithdrawalsSweep = maxPendingPartialsPerWithdrawalsSweep;
Expand Down Expand Up @@ -137,8 +137,8 @@ public int getMaxAttestationsElectra() {
}

@Override
public int getMaxConsolidations() {
return maxConsolidations;
public int getMaxConsolidationRequestsPerPayload() {
return maxConsolidationRequestsPerPayload;
}

@Override
Expand Down Expand Up @@ -183,7 +183,7 @@ public boolean equals(final Object o) {
&& whistleblowerRewardQuotientElectra == that.whistleblowerRewardQuotientElectra
&& maxAttesterSlashingsElectra == that.maxAttesterSlashingsElectra
&& maxAttestationsElectra == that.maxAttestationsElectra
&& maxConsolidations == that.maxConsolidations
&& maxConsolidationRequestsPerPayload == that.maxConsolidationRequestsPerPayload
&& maxDepositReceiptsPerPayload == that.maxDepositReceiptsPerPayload
&& maxWithdrawalRequestsPerPayload == that.maxWithdrawalRequestsPerPayload
&& maxPendingPartialsPerWithdrawalsSweep == that.maxPendingPartialsPerWithdrawalsSweep;
Expand All @@ -205,7 +205,7 @@ public int hashCode() {
whistleblowerRewardQuotientElectra,
maxAttesterSlashingsElectra,
maxAttestationsElectra,
maxConsolidations,
maxConsolidationRequestsPerPayload,
maxDepositReceiptsPerPayload,
maxWithdrawalRequestsPerPayload,
maxPendingPartialsPerWithdrawalsSweep);
Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -41,7 +41,7 @@ public class ElectraBuilder implements ForkConfigBuilder<SpecConfigDeneb, SpecCo
private Integer whistleblowerRewardQuotientElectra;
private Integer maxAttesterSlashingsElectra;
private Integer maxAttestationsElectra;
private Integer maxConsolidations;
private Integer maxConsolidationRequestsPerPayload;
private Integer maxDepositReceiptsPerPayload;
private Integer maxWithdrawalRequestsPerPayload;
private Integer maxPendingPartialsPerWithdrawalsSweep;
Expand All @@ -64,7 +64,7 @@ public SpecConfigElectra build(final SpecConfigDeneb specConfig) {
whistleblowerRewardQuotientElectra,
maxAttesterSlashingsElectra,
maxAttestationsElectra,
maxConsolidations,
maxConsolidationRequestsPerPayload,
maxDepositReceiptsPerPayload,
maxWithdrawalRequestsPerPayload,
maxPendingPartialsPerWithdrawalsSweep);
Expand Down Expand Up @@ -145,9 +145,10 @@ public ElectraBuilder maxAttestationsElectra(final Integer maxAttestationsElectr
return this;
}

public ElectraBuilder maxConsolidations(final Integer maxConsolidations) {
checkNotNull(maxConsolidations);
this.maxConsolidations = maxConsolidations;
public ElectraBuilder maxConsolidationRequestsPerPayload(
final Integer maxConsolidationsRequestPerPayload) {
checkNotNull(maxConsolidationsRequestPerPayload);
this.maxConsolidationRequestsPerPayload = maxConsolidationsRequestPerPayload;
return this;
}

Expand Down Expand Up @@ -202,7 +203,7 @@ public Map<String, Object> getValidationMap() {
constants.put("whistleblowerRewardQuotientElectra", whistleblowerRewardQuotientElectra);
constants.put("maxAttesterSlashingsElectra", maxAttesterSlashingsElectra);
constants.put("maxAttestationsElectra", maxAttestationsElectra);
constants.put("maxConsolidations", maxConsolidations);
constants.put("maxConsolidationRequestsPerPayload", maxConsolidationRequestsPerPayload);
constants.put("maxDepositReceiptsPerPayload", maxDepositReceiptsPerPayload);
constants.put("maxWithdrawalRequestsPerPayload", maxWithdrawalRequestsPerPayload);
constants.put("maxPendingPartialsPerWithdrawalsSweep", maxPendingPartialsPerWithdrawalsSweep);
Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -145,7 +145,8 @@ BlockBodyFields.EXECUTION_PAYLOAD, new ExecutionPayloadSchemaElectra(specConfig)
namedSchema(
BlockBodyFields.CONSOLIDATIONS,
SszListSchema.create(
SignedConsolidation.SSZ_SCHEMA, specConfig.getMaxConsolidations())));
SignedConsolidation.SSZ_SCHEMA,
specConfig.getMaxConsolidationRequestsPerPayload())));
}

@Override
Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -145,7 +145,8 @@ public static BlindedBeaconBlockBodySchemaElectraImpl create(
namedSchema(
BlockBodyFields.CONSOLIDATIONS,
SszListSchema.create(
SignedConsolidation.SSZ_SCHEMA, specConfig.getMaxConsolidations())));
SignedConsolidation.SSZ_SCHEMA,
specConfig.getMaxConsolidationRequestsPerPayload())));
}

@Override
Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -30,7 +30,7 @@ MAX_ATTESTER_SLASHINGS_ELECTRA: 1
# `uint64(2**3)` (= 8)
MAX_ATTESTATIONS_ELECTRA: 8
# `uint64(2**0)` (= 1)
MAX_CONSOLIDATIONS: 1
MAX_CONSOLIDATION_REQUESTS_PER_PAYLOAD: 1

# Execution
# ---------------------------------------------------------------
Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -30,7 +30,7 @@ MAX_ATTESTER_SLASHINGS_ELECTRA: 1
# `uint64(2**3)` (= 8)
MAX_ATTESTATIONS_ELECTRA: 8
# `uint64(2**0)` (= 1)
MAX_CONSOLIDATIONS: 1
MAX_CONSOLIDATION_REQUESTS_PER_PAYLOAD: 1

# Execution
# ---------------------------------------------------------------
Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -30,7 +30,7 @@ MAX_ATTESTER_SLASHINGS_ELECTRA: 1
# `uint64(2**3)` (= 8)
MAX_ATTESTATIONS_ELECTRA: 8
# `uint64(2**0)` (= 1)
MAX_CONSOLIDATIONS: 1
MAX_CONSOLIDATION_REQUESTS_PER_PAYLOAD: 1

# Execution
# ---------------------------------------------------------------
Expand Down