예제 #1
0
 def oid(self):
     """Universally unique identifier for this app."""
     # since 4.0: thread.get_ident() is not included when
     # generating the process id.  This is due to how the RPC
     # backend now dedicates a single thread to receive results,
     # which would not work if each thread has a separate id.
     return oid_from(self, threads=False)
예제 #2
0
 def thread_oid(self):
     """Per-thread unique identifier for this app."""
     try:
         return self._local.oid
     except AttributeError:
         self._local.oid = new_oid = oid_from(self, threads=True)
         return new_oid
예제 #3
0
파일: base.py 프로젝트: songminger/celery
 def oid(self):
     """Universally unique identifier for this app."""
     # since 4.0: thread.get_ident() is not included when
     # generating the process id.  This is due to how the RPC
     # backend now dedicates a single thread to receive results,
     # which would not work if each thread has a separate id.
     return oid_from(self, threads=False)
예제 #4
0
 def oid(self):
     return oid_from(self)
예제 #5
0
파일: base.py 프로젝트: 277800076/celery
 def oid(self):
     """Universally unique identifier for this app."""
     return oid_from(self)
예제 #6
0
파일: base.py 프로젝트: shejianmin/celery
 def oid(self):
     """Universally unique identifier for this app."""
     return oid_from(self)
예제 #7
0
파일: base.py 프로젝트: JayceM6/celery
 def oid(self):
     return oid_from(self)
예제 #8
0
파일: rpc.py 프로젝트: Dalar/celery
 def oid(self):
     try:
         return self._tls.OID
     except AttributeError:
         oid = self._tls.OID = oid_from(self)
         return oid
예제 #9
0
 def thread_oid(self):
     """Per-thread unique identifier for this app."""
     return self.context_oid.get(oid_from(self, threads=True))
예제 #10
0
파일: rpc.py 프로젝트: romand/celery
 def oid(self):
     try:
         return self._tls.OID
     except AttributeError:
         oid = self._tls.OID = oid_from(self)
         return oid