Sandro Bonazzola has posted comments on this change. Change subject: core: log: support overlapping filters ......................................................................
Patch Set 2: (1 comment) http://gerrit.ovirt.org/#/c/25406/2/src/plugins/otopi/core/log.py File src/plugins/otopi/core/log.py: Line 91: self.environment.get(k, None) for k in Line 92: self.environment[constants.CoreEnv.LOG_FILTER_KEYS] Line 93: ] Line 94: ): Line 95: if f not in (None, ''): > take example of: What I was thinking to is: >>> filter = ["engine", "engineengine", "ovirt-engine-history"] >>> filter.sort(reverse=True) #longest first >>> r.sub("***FILTERED***", "ovirt-engine-history engineengine engine test >>> word") Out: '***FILTERED*** ***FILTERED******FILTERED*** ***FILTERED*** test word' sadly engineengine is not used as longer string when engine is there while ovirt-engine-history is :-/ Line 96: index = -1 Line 97: while True: Line 98: index = msg.find(f, index+1) Line 99: if index == -1: -- To view, visit http://gerrit.ovirt.org/25406 To unsubscribe, visit http://gerrit.ovirt.org/settings Gerrit-MessageType: comment Gerrit-Change-Id: I512425cf2d1f56cdaf1c386fa105f7e335ae10c4 Gerrit-PatchSet: 2 Gerrit-Project: otopi Gerrit-Branch: master Gerrit-Owner: Alon Bar-Lev <alo...@redhat.com> Gerrit-Reviewer: Alon Bar-Lev <alo...@redhat.com> Gerrit-Reviewer: Sandro Bonazzola <sbona...@redhat.com> Gerrit-Reviewer: Yedidyah Bar David <d...@redhat.com> Gerrit-HasComments: Yes _______________________________________________ Engine-patches mailing list Engine-patches@ovirt.org http://lists.ovirt.org/mailman/listinfo/engine-patches