Adding changes to handle region order for ALT operations. Currently, we don't batch operations for ALT, as a result ALT operations don't follow region order. Batching operations will be the long term solution for this. I have created this solution as a short term fix
Changed Hashmap to LinkedHashmap to maintain region order, same with HashSet(Changed it to LinkedHashSet to maintain the order of Stack Instances)
The average time complexity for LinkedHashmap/HashSet v Hashmap/HashSet and for Insert, Delete, Search is the same -> O(1)
The worst time complexity for LinkedHashmap/HashSet v Hashmap/HashSet for Insert, Delete, Search is the same -> O(n)
Manually tested the solution in my dev account
By submitting this pull request, I confirm that you can use, modify, copy, and redistribute this contribution, under the terms of your choice.
Issue #, if available:
Description of changes:
By submitting this pull request, I confirm that you can use, modify, copy, and redistribute this contribution, under the terms of your choice.