Changeset 33674
- Timestamp:
- Apr 3, 2012, 4:26:24 PM (14 years ago)
- File:
-
- 1 edited
-
trunk/ippToPsps/jython/queue.py (modified) (4 diffs)
Legend:
- Unmodified
- Added
- Removed
-
trunk/ippToPsps/jython/queue.py
r33528 r33674 13 13 from gpc1db import Gpc1Db 14 14 from datastore import Datastore 15 from dvoobjects import DvoObjects 15 16 from batch import Batch 16 17 … … 30 31 self.gpc1Db = Gpc1Db(self.logger, self.config) 31 32 self.datastore = Datastore(self.logger, self.config, self.ippToPspsDb) 33 self.dvoObjects = DvoObjects(self.logger, self.config) 32 34 33 35 self.config.printAll() … … 50 52 # queue up batches that are processed but not loaded to datastore 51 53 for batchType in self.config.batchTypes: 54 52 55 self.logger.infoTitle("Previous failed datastore loads") 53 56 self.publishAnyUnpublishedBatches(batchType) 54 57 55 58 # get totals for whole area to check if there is anything to do 56 processedIDs = self.ippToPspsDb.getProcessedIDs(batchType, self.config.epoch, self.config.dvoLabel) 57 consistantlyFailedIDs = self.ippToPspsDb.getConsistentlyFailedIDs(batchType, self.config.epoch, self.config.dvoLabel) 58 rows = self.gpc1Db.getItemsInThisDVODbForThisStage( 59 self.config.dvoLabel, 60 batchType, 61 self.config.minRa, 62 self.config.maxRa, 63 self.config.minDec, 64 self.config.maxDec) 59 processedIDs = self.ippToPspsDb.getProcessedIDs(batchType) 60 consistantlyFailedIDs = self.ippToPspsDb.getConsistentlyFailedIDs(batchType) 61 62 # for object batches, get full list of stuff from Dvo 63 if batchType == "OB": 64 self.dvoObjects.setSkyArea( 65 self.config.minRa, 66 self.config.maxRa, 67 self.config.minDec, 68 self.config.maxDec) 69 rows = self.dvoObjects.allPopulatedRegionInfo 70 self.dvoObjects.printSummary() 71 72 # for other batches, info comes from gpc1 database 73 else: 74 rows = self.gpc1Db.getItemsInThisDVODbForThisStage( 75 self.config.dvoLabel, 76 batchType, 77 self.config.minRa, 78 self.config.maxRa, 79 self.config.minDec, 80 self.config.maxDec) 65 81 66 82 # first report total stuff … … 125 141 def publishAnyUnpublishedBatches(self, batchType): 126 142 127 batchIDs = self.ippToPspsDb.getProcessedButFailedDatastoreBatchIDs( self.config.epoch, self.config.dvoLabel,batchType)143 batchIDs = self.ippToPspsDb.getProcessedButFailedDatastoreBatchIDs(batchType) 128 144 self.logger.infoPair("%s batches" % batchType, "%d" % len(batchIDs)) 129 145
Note:
See TracChangeset
for help on using the changeset viewer.
