Skip to content
Snippets Groups Projects
Commit 62761001 authored by sveseli's avatar sveseli
Browse files

updated release notes; merged fixes from 0.10

parents 24f886e3 4253d91c
No related branches found
No related tags found
No related merge requests found
...@@ -2,6 +2,8 @@ Release 0.10 (03/11/2016) ...@@ -2,6 +2,8 @@ Release 0.10 (03/11/2016)
============================= =============================
- Added dm-list-daqs and dm-list-uploads commands - Added dm-list-daqs and dm-list-uploads commands
- Resolved issue with newly created directories treated as files for
real-time data acquisitions
Release 0.9 (02/25/2016) Release 0.9 (02/25/2016)
============================= =============================
......
...@@ -15,5 +15,5 @@ DM_DAQ_WEB_SERVICE_HOST=DM_HOSTNAME ...@@ -15,5 +15,5 @@ DM_DAQ_WEB_SERVICE_HOST=DM_HOSTNAME
DM_DAQ_WEB_SERVICE_PORT=33336 DM_DAQ_WEB_SERVICE_PORT=33336
DM_CAT_WEB_SERVICE_HOST=DM_HOSTNAME DM_CAT_WEB_SERVICE_HOST=DM_HOSTNAME
DM_CAT_WEB_SERVICE_PORT=44436 DM_CAT_WEB_SERVICE_PORT=44436
DM_SOFTWARE_VERSION="0.9 (DM_DATE)" DM_SOFTWARE_VERSION="0.10 (DM_DATE)"
__version__ = "0.9 (2016.02.24)" __version__ = "0.10 (2016.03.21)"
...@@ -159,7 +159,7 @@ class SessionManager: ...@@ -159,7 +159,7 @@ class SessionManager:
parsedUrl = urlparse.urlparse(url) parsedUrl = urlparse.urlparse(url)
protocol = parsedUrl[0] protocol = parsedUrl[0]
path = parsedUrl[2] path = parsedUrl[2]
self.logger.debug('Sending request: %s' % url) #self.logger.debug('Sending request: %s' % url)
encodedData = '' encodedData = ''
if data is not None: if data is not None:
if type(data) == types.DictType and len(data): if type(data) == types.DictType and len(data):
......
...@@ -18,7 +18,7 @@ class MongoDbFileCatalogPlugin(FileProcessor): ...@@ -18,7 +18,7 @@ class MongoDbFileCatalogPlugin(FileProcessor):
def processFile(self, fileInfo): def processFile(self, fileInfo):
experimentFilePath = fileInfo.get('experimentFilePath') experimentFilePath = fileInfo.get('experimentFilePath')
experimentName = fileInfo.get('experimentName') experimentName = fileInfo.get('experimentName')
self.logger.debug('Processing file "%s" for experiment %s: %s' % (experimentFilePath, experimentName, fileInfo)) self.logger.debug('Processing file "%s" for experiment %s' % (experimentFilePath, experimentName))
daqInfo = fileInfo.get('daqInfo') daqInfo = fileInfo.get('daqInfo')
storageDirectory = daqInfo.get('storageDirectory') storageDirectory = daqInfo.get('storageDirectory')
......
...@@ -64,7 +64,7 @@ class RsyncFileTransferPlugin(FileTransferPlugin): ...@@ -64,7 +64,7 @@ class RsyncFileTransferPlugin(FileTransferPlugin):
FileUtility.getMd5Sum(filePath, fileInfo) FileUtility.getMd5Sum(filePath, fileInfo)
# Transfer file # Transfer file
self.logger.debug('Starting transfer: %s' % fileInfo) self.logger.debug('Starting transfer: %s -> %s' % (srcUrl, destUrl))
self.start(src=srcUrl, dest=destUrl, templateInfo=fileInfo, cwd=dataDirectory) self.start(src=srcUrl, dest=destUrl, templateInfo=fileInfo, cwd=dataDirectory)
# Get remote checksum # Get remote checksum
......
...@@ -46,9 +46,13 @@ class DmFileSystemEventHandler(FileSystemEventHandler): ...@@ -46,9 +46,13 @@ class DmFileSystemEventHandler(FileSystemEventHandler):
files = glob.glob(os.path.join(event.src_path,'*')) files = glob.glob(os.path.join(event.src_path,'*'))
self.logger.debug('Processing directory event: %s , src path: %s' % (event.__dict__, event.src_path)) self.logger.debug('Processing directory event: %s , src path: %s' % (event.__dict__, event.src_path))
if len(files) > 0: if len(files) > 0:
filePath = max(files, key=os.path.getctime) sortedFiles = sorted(files, key=os.path.getctime, reverse=True)
self.logger.debug('Latest file: %s' % (filePath)) for filePath in sortedFiles:
self.fileSystemObserver.fileUpdated(filePath, self.dataDirectory, self.experiment) if os.path.isfile(filePath):
self.logger.debug('Latest file: %s' % (filePath))
self.fileSystemObserver.fileUpdated(filePath, self.dataDirectory, self.experiment)
return
self.logger.debug('No new files found in %s' % (event.src_path))
except Exception, ex: except Exception, ex:
self.logger.error('Exception occured when searching for file in directory %s: %s' % (event.__dict__, ex)) self.logger.error('Exception occured when searching for file in directory %s: %s' % (event.__dict__, ex))
else: else:
......
...@@ -18,7 +18,7 @@ class DsProcessFileNotificationPlugin(FileProcessor): ...@@ -18,7 +18,7 @@ class DsProcessFileNotificationPlugin(FileProcessor):
experimentName = fileInfo.get('experimentName') experimentName = fileInfo.get('experimentName')
daqInfo = fileInfo.get('daqInfo', {}) daqInfo = fileInfo.get('daqInfo', {})
md5Sum = fileInfo.get('md5Sum') md5Sum = fileInfo.get('md5Sum')
self.logger.debug('Processing file %s for experiment %s: %s' % (experimentFilePath, experimentName, str(fileInfo))) self.logger.debug('Processing file %s for experiment %s' % (experimentFilePath, experimentName))
# Prepare dictionary for processing. Only send needed data. # Prepare dictionary for processing. Only send needed data.
fileInfo2 = {} fileInfo2 = {}
......
...@@ -110,7 +110,7 @@ class FileSystemObserver(threading.Thread,Singleton): ...@@ -110,7 +110,7 @@ class FileSystemObserver(threading.Thread,Singleton):
observedFile['statusMonitor'] = daqInfo observedFile['statusMonitor'] = daqInfo
observedFile.setLastUpdateTimeToNow() observedFile.setLastUpdateTimeToNow()
self.observedFileMap[filePath] = observedFile self.observedFileMap[filePath] = observedFile
self.logger.debug('Observed file updated: %s', observedFile) self.logger.debug('Observed file updated: %s', filePath)
@ThreadingUtility.synchronize @ThreadingUtility.synchronize
def checkObservedFilesForProcessing(self): def checkObservedFilesForProcessing(self):
......
0% Loading or .
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment