Mercurial > libervia-backend
comparison src/plugins/plugin_misc_xmllog.py @ 2145:33c8c4973743
core (plugins): added missing contants + use of new constants in PLUGIN_INFO
author | Goffi <goffi@goffi.org> |
---|---|
date | Sun, 12 Feb 2017 18:59:10 +0100 |
parents | 2daf7b4c6756 |
children | 51d346e283fd |
comparison
equal
deleted
inserted
replaced
2144:1d3f73e065e1 | 2145:33c8c4973743 |
---|---|
16 | 16 |
17 # You should have received a copy of the GNU Affero General Public License | 17 # You should have received a copy of the GNU Affero General Public License |
18 # along with this program. If not, see <http://www.gnu.org/licenses/>. | 18 # along with this program. If not, see <http://www.gnu.org/licenses/>. |
19 | 19 |
20 from sat.core.i18n import _ | 20 from sat.core.i18n import _ |
21 from sat.core.constants import Const as C | |
21 from sat.core.log import getLogger | 22 from sat.core.log import getLogger |
22 log = getLogger(__name__) | 23 log = getLogger(__name__) |
23 from twisted.words.protocols.jabber.xmlstream import XmlStream | 24 from twisted.words.protocols.jabber.xmlstream import XmlStream |
24 from twisted.words.xish import domish | 25 from twisted.words.xish import domish |
25 | 26 |
26 PLUGIN_INFO = { | 27 PLUGIN_INFO = { |
27 "name": "Raw XML log Plugin", | 28 C.PI_NAME: "Raw XML log Plugin", |
28 "import_name": "XmlLog", | 29 C.PI_IMPORT_NAME: "XmlLog", |
29 "type": "Misc", | 30 C.PI_TYPE: "Misc", |
30 "protocols": [], | 31 C.PI_PROTOCOLS: [], |
31 "dependencies": [], | 32 C.PI_DEPENDENCIES: [], |
32 "main": "XmlLog", | 33 C.PI_MAIN: "XmlLog", |
33 "handler": "no", | 34 C.PI_HANDLER: "no", |
34 "description": _("""Send raw XML logs to bridge""") | 35 C.PI_DESCRIPTION: _("""Send raw XML logs to bridge""") |
35 } | 36 } |
36 | 37 |
37 | 38 |
38 class LoggingXmlStream(XmlStream): | 39 class LoggingXmlStream(XmlStream): |
39 """This class send the raw XML to the Bridge, for logging purpose""" | 40 """This class send the raw XML to the Bridge, for logging purpose""" |