remove logging for register/unregister relations
git-svn-id: svn://svn.cy55.de/Zope3/src/cybertools/trunk@3282 fd906abe-77d9-0310-91a1-e0d9ade77398
This commit is contained in:
parent
a603002142
commit
f2a8a754fc
1 changed files with 5 additions and 4 deletions
|
@ -41,6 +41,9 @@ from zope.traversing.api import getName, getParent
|
||||||
from interfaces import IRelationRegistry, IRelationInvalidatedEvent, IRelation
|
from interfaces import IRelationRegistry, IRelationInvalidatedEvent, IRelation
|
||||||
|
|
||||||
|
|
||||||
|
logger = getLogger('cybertools.relation.registry')
|
||||||
|
|
||||||
|
|
||||||
class DummyRelationRegistry(object):
|
class DummyRelationRegistry(object):
|
||||||
""" Dummy implementation for demonstration and test purposes.
|
""" Dummy implementation for demonstration and test purposes.
|
||||||
"""
|
"""
|
||||||
|
@ -136,16 +139,14 @@ class RelationRegistry(Catalog):
|
||||||
self.index_doc(uid, relation)
|
self.index_doc(uid, relation)
|
||||||
if self.relations is not None:
|
if self.relations is not None:
|
||||||
self.relations[uid] = relation
|
self.relations[uid] = relation
|
||||||
logger = getLogger('cybertools.relation.registry')
|
#logger.info('added relation with uid %i.' % uid)
|
||||||
logger.info('added relation with uid %i.' % uid)
|
|
||||||
|
|
||||||
def unregister(self, relation):
|
def unregister(self, relation):
|
||||||
uid = component.getUtility(IIntIds).getId(relation)
|
uid = component.getUtility(IIntIds).getId(relation)
|
||||||
self.unindex_doc(uid)
|
self.unindex_doc(uid)
|
||||||
if self.relations is not None and uid in self.relations:
|
if self.relations is not None and uid in self.relations:
|
||||||
del self.relations[uid]
|
del self.relations[uid]
|
||||||
logger = getLogger('cybertools.relation.registry')
|
#logger.info('removed relation with uid %i.' % uid)
|
||||||
logger.info('removed relation with uid %i.' % uid)
|
|
||||||
notify(RelationInvalidatedEvent(relation))
|
notify(RelationInvalidatedEvent(relation))
|
||||||
|
|
||||||
def cleanupRelations(self):
|
def cleanupRelations(self):
|
||||||
|
|
Loading…
Add table
Reference in a new issue