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.
maps are stored as [ { "key_(type)": k, "data_(type)": d } , ... ], where (type) can be int, bool, string or object. The fields are:
account_auths in account_object and related operations
address_auths in account_object and related operations
key_auths in account_object and related operations
feeds in asset_bitasset_data_object
acceptable_collateral in credit_offer_object and related operations
acceptable_borrowers in credit_offer_object and related operations
static_variants are stored as { "which": w, "data_(type)" : d }, where (type) can be int, bool, string or object. The fields are:
op in proposal_create_operation.proposed_ops
initializer in worker_create_operation
policy in vesting_balance_create_operation and etc
active_special_authority in account_object and related operations
owner_special_authority in account_object and related operations
htlc_preimage_hash in htlc_create_operation
argument in restriction class, used in custom authority operations (added in #2681)
operation_result
object arrays are stored normally as object arrays, especially, among them, static_variant arrays are stored as object arrays, including:
parameters in committee_update_chain_parameters_operation.**.current_fees
proposed_ops in proposal_create_operation
operations in proposal_object
predicates in assert_operation
Note: more disk space is required for ES to store the redundant data. Here is some data for comparison.
PR for https://github.com/bitshares/bitshares-core/issues/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
,string
orobject
. The fields are:account_auths
inaccount_object
and related operationsaddress_auths
inaccount_object
and related operationskey_auths
inaccount_object
and related operationsfeeds
inasset_bitasset_data_object
acceptable_collateral
incredit_offer_object
and related operationsacceptable_borrowers
incredit_offer_object
and related operationsstatic_variant
s are stored as{ "which": w, "data_(type)" : d }
, where(type)
can beint
,bool
,string
orobject
. The fields are:op
inproposal_create_operation.proposed_ops
initializer
inworker_create_operation
policy
investing_balance_create_operation
and etcactive_special_authority
inaccount_object
and related operationsowner_special_authority
inaccount_object
and related operationshtlc_preimage_hash
inhtlc_create_operation
argument
inrestriction
class, used in custom authority operations (added in #2681)operation_result
static_variant
arrays are stored as object arrays, including:parameters
incommittee_update_chain_parameters_operation.**.current_fees
proposed_ops
inproposal_create_operation
operations
inproposal_object
predicates
inassert_operation
BTW https://github.com/bitshares/bitshares-core/issues/2568 is the next work to be done.