Use model_query() instead of session.query in db.instance_destroy

Unify db.instance_destroy() method to use model_query() as others
methods use.

Side effect we won't try to soft delete already soft deleted instance

Change-Id: I36d5bb42b16901c260ff4276e31a6aec46ffa8a4
Merge "Use model_query() instead of session.query in db.instance_destroy"
XenAPI: Speedup host_ref cannot change - get it once

The host we run on is fixed - getting this each time from XAPI
is expensive

Change-Id: Ifee9a778f3ed855ef52b001de3fc2ebbd0b972cf
XenAPI: get_info was very expensive

Getting the whole VM record is expensive and slowed down Tempest tests
significantly.

Change-Id: I93bcef5b692a531aac41518dc29d5d4f46cded65
XenAPI: Tidy calls to get_all_ref_and_rec

Use in fewer places, and where it is still used, use the more
efficient get_all_records

Change-Id: I4725c3f1fdebdf1737941cb7db69b19afb22df9f
XenAPI: Speedup get_vhd_parent_uuid

In many cases the VDI record has already been retrieved.
Use it rather than expensively getting a new VDI record from XAPI.

Change-Id: I469e2a415c1f1924010f47d3927ca18c45a7b8f8
XenAPI: Reduce calls to sr_scan

These are expensive and not needed in the scenarios here

Change-Id: I2aeda6e2b7a001ac23ee486495592e242bc078ba
XenAPI: get_XYZ is faster than get_record

Replace multiple calls to use get_XYZ in preference.

Change-Id: I52e20c4f4c9d6a6ad019694916ee057cc96b18a6