Currently, there are two methods for user to enable/disable a erasure coding policy. One is through "dfs.namenode.ec.policies.enabled" property which is a static way to configure the enabled erasure coding policies. Another is through "enableErasureCodingPolicy" or "disabledErasureCodingPolicy" API which can enabled or disable erasure coding policy at runtime.
When Namenode restart, there is potential state conflicts between the policy defined in "dfs.namenode.ec.policies.enabled" and policy saved in fsImage. To resolve the conflict and simplify the operation, it's better to use just one way and remove the old method configuring the property.