Changeset 16264 for trunk/Nebulous-Server/lib/Nebulous/Server/SQL.pm
- Timestamp:
- Jan 29, 2008, 2:19:34 PM (18 years ago)
- File:
-
- 1 edited
-
trunk/Nebulous-Server/lib/Nebulous/Server/SQL.pm (modified) (3 diffs)
Legend:
- Unmodified
- Added
- Removed
-
trunk/Nebulous-Server/lib/Nebulous/Server/SQL.pm
r16259 r16264 1 1 # Copyright (c) 2004 Joshua Hoblitt 2 2 # 3 # $Id: SQL.pm,v 1.4 5 2008-01-28 19:48:08jhoblitt Exp $3 # $Id: SQL.pm,v 1.46 2008-01-30 00:19:06 jhoblitt Exp $ 4 4 5 5 package Nebulous::Server::SQL; … … 172 172 storage_object.so_id, 173 173 uri, 174 assigned_vol_id 174 assigned_vol_id, 175 available 175 176 FROM storage_object 176 177 JOIN instance … … 242 243 SET ext_id = ? 243 244 WHERE ext_id = ? 245 }, 246 find_objects_with_unavailable_instances => qq{ 247 SELECT 248 so_id, 249 ext_id, 250 count(ins_id) as instances, 251 count(mountedvol.vol_id) as available_instances, 252 count(mountedvol.vol_id) < count(ins_id) as need_recovery, 253 count(mountedvol.vol_id) > 0 as recoverable 254 FROM storage_object 255 JOIN instance 256 USING(so_id) 257 LEFT JOIN mountedvol 258 USING(vol_id) 259 GROUP BY so_id 260 HAVING need_recovery = 1 244 261 }, 245 262 );
Note:
See TracChangeset
for help on using the changeset viewer.
