Exemplo n.º 1
0
    def __activate__(self, context):
        # Can't workout how to use the message_list, so use the transaction queues directly.
        self.messaging = MessagingServices.getInstance()

        # Prepare variables
        self.config = context["jsonConfig"]
        self.log = context["log"]
        self.index = context["fields"]
        self.object = context["object"]
        self.payload = context["payload"]
        self.params = context["params"]
        self.utils = context["pyUtils"]
        self.config = context["jsonConfig"]

        self.log.debug("Indexing Metadata Record '{}' '{}'",
                       self.object.getId(), self.payload.getId())

        # Common data
        self.__newDoc()
        self.packagePid = None
        pidList = self.object.getPayloadIdList()
        for pid in pidList:
            if pid.endswith(".tfpackage"):
                self.packagePid = pid

        # Real metadata
        if self.itemType == "object":
            self.__basicData()
            self.__metadata()

        # Make sure security comes after workflows
        self.__security()
Exemplo n.º 2
0
 def queueMessage(self, msg):
     try:
         ms = MessagingServices.getInstance()
         ms.queueMessage(TransactionManagerQueueConsumer.LISTENER_ID, msg);
         ms.release()
         return True
     except:
         return False
Exemplo n.º 3
0
 def __init__(self):
     self.messaging = MessagingServices.getInstance()
Exemplo n.º 4
0
 def __init__(self):
     self.messaging = MessagingServices.getInstance()
 def __init__(self):
     DefaultWorkflowData.__init__(self)
     self.messaging = MessagingServices.getInstance()
Exemplo n.º 6
0
 def queueMessage(self, queue, msg):
     ms = MessagingServices.getInstance()
     ms.queueMessage(queue, msg)
     ms.release()
Exemplo n.º 7
0
 def __init__(self):
     DefaultWorkflowData.__init__(self)
     self.messaging = MessagingServices.getInstance()