Big Switch: Lock consistency table for REST calls

Adds a new class to hold an SQL table lock throughout
a REST call to prevent servers in an HA deployment from
using a stale consistency hash value.

Also passes the current context down to the server manager
for every request since the consistency hash will need to
be read from the database instead of from a variable on the
server pool object.

Conflicts:

	neutron/plugins/bigswitch/plugin.py
	neutron/tests/unit/bigswitch/test_servermanager.py

Closes-Bug: #1328331
Change-Id: I5f8402c076d7732742c0ae4d9b9d6833d42a0b7b
(cherry picked from commit 09e706b210513968cac2bad78fe81ee9cbb5b5be)
Big Switch: Remove consistency hash on full sync

Clears the consistency hash before performing a full
backend synchronization. Since all of the data is being
replaced, there is no reason to include this and it
currently requires special-casing to handle.

Closes-Bug: #1328233
Change-Id: Iace766d869dc78b041d3a5464e728b872c8347c2
(cherry picked from commit e60670e5a202870693f7485a1da4411f4faaf36d)
BSN: Remove db lock and add missing contexts

Adds context tracking decorators that were missing
from router interface methods. Without them, new
sessions were being created instead of using the
existing context which was causing transaction
issues.

Modifies the servermanager to store context references
as weakrefs so if multiple functions are called before
the rest functions are called, the first one doesn't steal
the only context reference with a pop() call.

Removes a DB lock for update in the server manager that occured
during rest calls that was triggering deadlocks due to the
file lock synchronization for the rest calls.

Closes-Bug: #1336251
Change-Id: Iad3d61e2c23832b3ad760a999fbab7feaa13f805
(cherry picked from commit ee9fe2458f813b5d367bc7263c7a30a3af46aa2b)