revert 4 commits related to primary storage issue.

ba90fa91d3da56d4b63a0850d58add34cc5a7a2c
64bb7007053d004fe7a8ac3b610e20df69f16bab
630d2561d2b13882892799507613823bcc04b4ac
1978d7bd7311d19a4b370a679cfd364d54e1e300
CLOUDSTACK-4566: fix incorrect values in resource_count table for resource limitation

There are three issues in resource_count table
(1) expunge a vm, the public_ip decreases and becomes -1 in basic zone.
(2) recover a vm, the volume increase.
(3) restore a vm, the volume decrease.
CLOUDSTACK-2319: fix incorrect account_id in event table for Revoke SecurityGroupRule commands
(cherry picked from commit d9ba234d6c032aeb2ba04d4e6be0502de8a4efd9)