Store some data in ES as objects instead of just as strings#2565
Merged
Store some data in ES as objects instead of just as strings#2565
Conversation
17 tasks
2 tasks
17 tasks
|
Kudos, SonarCloud Quality Gate passed! |
This was referenced Dec 26, 2021
17 tasks
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment
Add this suggestion to a batch that can be applied as a single commit.This suggestion is invalid because no changes were made to the code.Suggestions cannot be applied while the pull request is closed.Suggestions cannot be applied while viewing a subset of changes.Only one suggestion per line can be applied in a batch.Add this suggestion to a batch that can be applied as a single commit.Applying suggestions on deleted lines is not supported.You must change the existing code in this line in order to create a valid suggestion.Outdated suggestions cannot be applied.This suggestion has been applied or marked resolved.Suggestions cannot be applied from pending reviews.Suggestions cannot be applied on multi-line comments.Suggestions cannot be applied while the pull request is queued to merge.Suggestion cannot be applied right now. Please check back later.








PR for #2380 and #1400.
The strings are kept for backward compatibility. The objects are stored redundantly in new fields with name
(old_field_name)_object. The affected fields are listed below.[ { "key_(type)": k, "data_(type)": d } , ... ], where(type)can beint,bool,stringorobject. The fields are:account_authsinaccount_objectand related operationsaddress_authsinaccount_objectand related operationskey_authsinaccount_objectand related operationsfeedsinasset_bitasset_data_objectacceptable_collateralincredit_offer_objectand related operationsacceptable_borrowersincredit_offer_objectand related operationsstatic_variants are stored as{ "which": w, "data_(type)" : d }, where(type)can beint,bool,stringorobject. The fields are:opinproposal_create_operation.proposed_opsinitializerinworker_create_operationpolicyinvesting_balance_create_operationand etcactive_special_authorityinaccount_objectand related operationsowner_special_authorityinaccount_objectand related operationshtlc_preimage_hashinhtlc_create_operationargumentinrestrictionclass, used in custom authority operations (added in Adaptrestriction::argumentas an object for ES #2681)operation_resultstatic_variantarrays are stored as object arrays, including:parametersincommittee_update_chain_parameters_operation.**.current_feesproposed_opsinproposal_create_operationoperationsinproposal_objectpredicatesinassert_operationNote: more disk space is required for ES to store the redundant data. Here is some data for comparison.
BTW #2568 is the next work to be done.