向哨兵报告奥多错误

odoo8-addon-sentr的Python项目详细描述


License: AGPL-3

哨兵

此模块允许与 奥多。

安装

通过添加 odooaddons_path的模块目录。为了使模块正确 包装odoo wsgi应用程序,它还需要作为服务器范围的加载 模块。这可以使用 或使用--load命令行参数。

此模块还要求ravenpython包在 系统。它可以使用pip安装:

pip install raven

配置

以下附加配置选项可以添加到您的odoo中 配置文件:

OptionDescriptionDefault
^{tt3}$Sentry Data Source Name. You can find this value in your Sentry project configuration. Typically it looks something like this: https://<public_key>:<secret_key>@sentry.example.com/<project id> This is the only required option in order to use the module.^{tt4}$
^{tt5}$Whether or not Sentry logging is enabled.^{tt6}$
^{tt7}$The minimal logging level for which to send reports to Sentry. Possible values: notset, debug, info, warn, error, critical. It is recommended to have this set to at least warn, to avoid spamming yourself with Sentry events.^{tt8}$
^{tt9}$A string of comma-separated logger names which should be excluded from Sentry.^{tt10}$
^{tt11}$A string of comma-separated exceptions which should be ignored. You can use a star symbol (*) at the end, to ignore all exceptions from a module, eg.: openerp.exceptions.*.^{tt12}$
^{tt13}$A string of comma-separated processor classes which will be applied on an event before sending it to Sentry.^{tt14}$
^{tt15}$Transport class which will be used to send events to Sentry. Possible values: threaded: spawns an async worker for processing messages, synchronous: a synchronous blocking transport; requests_threaded: an asynchronous transport using the requests library; requests_synchronous - blocking transport using the requests library.^{tt16}$
^{tt17}$If enabled, additional context data will be extracted from current HTTP request and user session (if available). This has no effect for Cron jobs, as no request/session is available inside a Cron job.^{tt18}$
^{tt19}$Absolute path to your Odoo installation directory. This is optional and will only be used to extract the Odoo Git commit, which will be sent to Sentry, to allow to distinguish between Odoo updates.

其他client arguments可以是 通过在odoo配置中在参数名前面加上sentry\u来配置 文件。当前支持的其他客户端参数是:install_sys_hook, include_paths, exclude_paths, machine, auto_log_stacks, capture_locals, string_max_length, list_max_length, site, include_versions, environment

ODOO配置示例

下面是带有odoo sentry选项的odoo配置文件的示例:

[options]
sentry_dsn = https://<public_key>:<secret_key>@sentry.example.com/<project id>
sentry_enabled = true
sentry_logging_level = warn
sentry_exclude_loggers = werkzeug
sentry_ignore_exceptions = openerp.exceptions.AccessDenied,openerp.exceptions.AccessError,openerp.exceptions.MissingError,openerp.exceptions.RedirectWarning,openerp.exceptions.ValidationError,openerp.exceptions.Warning,openerp.exceptions.except_orm
sentry_processors = raven.processors.SanitizePasswordsProcessor,openerp.addons.sentry.logutils.SanitizeOdooCookiesProcessor
sentry_transport = threaded
sentry_include_context = true
sentry_environment = production
sentry_auto_log_stacks = false
sentry_odoo_dir = /home/odoo/odoo/

使用量

一旦配置并安装,模块将在和报告任何日志事件。 在配置的岗哨日志级别之上,不需要其他操作。

Try me on Runbot

已知问题/路线图

  • 没有数据库分离–此模块通过截取所有odoo来工作 记录正在运行的odoo进程中的记录。这意味着一旦安装在 一个数据库,它将拦截并报告所有ODOO数据库的错误, 在奥多服务器上使用的。
  • frontend integration–在将来,添加 通过集成 raven-js。另外,Sentry user feedback form可以是 集成到odoo客户机错误对话框窗口中,允许用户很快 描述当事情出错时他们在做什么。

缺陷跟踪器

GitHub Issues上跟踪错误。如果有麻烦,请 如果您的问题已经报告,请检查那里。如果你先发现它, 通过提供详细且受欢迎的反馈,帮助我们粉碎它。

学分

贡献者

维护人员

Odoo Community Association

此模块由OCA维护。

oca,或odoo社区协会,是一个非营利性组织 任务是支持odoo特性和 促进其广泛应用。

若要对此模块作出贡献,请访问https://odoo-community.org

欢迎加入QQ群-->: 979659372 Python中文网_新手群

推荐PyPI第三方库


热门话题
java如何访问ArrayList中对象的特定元素   反射如何检查java。朗。反思。方法返回类型是集合?   当我想使用socket发送对象时出现Java异常   eclipse是否可以修补部署到Tomcat/WildFly的Java应用程序?   java Spring:无法导入库   java从基类请求体DTO获取派生DTO   向ArrayList中添加元素时引发java异常   算法Java程序从列表中给定的数字中分组连续数<list>   java如何从类中获取一个变量到主活动?   regex Java模式,用于双引号或单引号内的数据,不包括括号内的引号   类Java OOP物理引擎类型   java在使用Camel时,如何使用Spring加载属性?   java Junit 4在@Mock中的作用域生成方法