def release_vlanid(vlan_id):
 LOG.debug(_('release_vlanid() called'))
 session = db.get_session()
 try:
  vlanid = session.query(l2network_models.VlanID).filter_by(vlan_id=vlan_id).one()
  vlanid['vlan_used'] = False
  session.merge(vlanid)
  session.flush()
  return vlanid['vlan_used']
 except exc.NoResultFound:
  raise c_exc.VlanIDNotFound(vlan_id=vlan_id)
 return

def release_vlanid ( vlan_id ) : LOG . debug ( _ ( 'release_vlanid() called' ) ) session = db . get_session ( ) try : vlanid = session . query ( l2network_models . VlanID ) . filter_by ( vlan_id = vlan_id ) . one ( ) vlanid [ 'vlan_used' ] = False session . merge ( vlanid ) session . flush ( ) return vlanid [ 'vlan_used' ] except exc . NoResultFound : raise c_exc . VlanIDNotFound ( vlan_id = vlan_id ) return
sets the vlanid state to be unused .