Class PushToStore¶
Defined in File stage.py
Inheritance Relationships¶
Base Type¶
public stage.Task(Class Task)
Class Documentation¶
- stage.PushToStore : public stage.Task
PushToStore is the epilogue of the pipeline. Effectively (if instructed so) it informs the kosh store about the existence of a new file. Attributes: ams_config: The AMS configuration storing information regarding the AMS setup. i_queue: The queue to read file locations from dir: The directory of the database store: The Kosh Store
Public Functions
- __init__(self, i_queue, application_name, dest_dir, db_url=None)¶
Initializes the PushToStore Task. Args: i_queue: The queue to read requests from. application_name: The name of the running application. dest_dir: The path to store persistend data to. db_url: The url to a SQL DB server which will be used to register metadata associated with the files.
- process_request(self, db_store, item)¶
Function that process a request to push the data to the DB
- __call__(self)¶
A busy loop reading messages from the i_queue publishing them to the underlying store.