Skip to Content
Python数据处理
book

Python数据处理

by Jacqueline Kazil, Katharine Jarmul
July 2017
Intermediate to advanced
398 pages
11h 54m
Chinese
Posts & Telecom Press
Content preview from Python数据处理
自动化和规模化
327
14.8.4
 日志和监控服务
如果一个脚本满足不了需求,或者你想将自动化程序合并到一个大型的组织框架中,你可
能需要研究将日志和监控作为一个服务的技术。有很多公司通过创建工具和系统来跟踪日
志,致力于让数据分析师和开发者的生活更简单。这些工具通常有非常简单的
Python
库,
将日志和监控信息发送到它们的平台。
通过日志服务,你可以将更多的时间投入到研究和脚本中,将更少的时间用
于管理监控和日志。这可以将“我们的脚本在不在工作,工作得怎么样?”
这样的问题留给团队中的非开发者,因为其中的很多服务都有很棒的报表和
内置的警报。
根据自动化程序的大小和布局,你可能同时需要系统监控以及脚本与错误监控。在这一节
中,我们会查看几种能够同时完成这两件事的服务,同时也会查看一些更加专业的服务。
即使你的自动化程序的规模没有大到需要它们,但是了解什么是可用的总是好的。
1.
日志和异常
基于
Python
的日志服务提供了打印日志到一个中心服务的能力,同时让你的脚本在一系列
不同的机器上运行,无论是本地机器还是远程机器。
一个有着很棒的
Python
支持的类似服务是
Sentry
https://getsentry.com/welcome/
)。
需要每月支付很少的费用,你就可以访问错误的报告板,收到基于异常临界值发送的警
报,监控基于日、周、月的错误和异常类型。
Sentry
Python
客户端(
https://github.com/
getsentry/raven-python
)非常容易安装、配置和使用
Become an O’Reilly member and get unlimited access to this title plus top books and audiobooks from O’Reilly and nearly 200 top publishers, thousands of courses curated by job role, 150+ live events each month,
and much more.

Read now

Unlock full access

More than 5,000 organizations count on O’Reilly

AirBnbBlueOriginElectronic ArtsHomeDepotNasdaqRakutenTata Consultancy Services

QuotationMarkO’Reilly covers everything we've got, with content to help us build a world-class technology community, upgrade the capabilities and competencies of our teams, and improve overall team performance as well as their engagement.
Julian F.
Head of Cybersecurity
QuotationMarkI wanted to learn C and C++, but it didn't click for me until I picked up an O'Reilly book. When I went on the O’Reilly platform, I was astonished to find all the books there, plus live events and sandboxes so you could play around with the technology.
Addison B.
Field Engineer
QuotationMarkI’ve been on the O’Reilly platform for more than eight years. I use a couple of learning platforms, but I'm on O'Reilly more than anybody else. When you're there, you start learning. I'm never disappointed.
Amir M.
Data Platform Tech Lead
QuotationMarkI'm always learning. So when I got on to O'Reilly, I was like a kid in a candy store. There are playlists. There are answers. There's on-demand training. It's worth its weight in gold, in terms of what it allows me to do.
Mark W.
Embedded Software Engineer

You might also like

数据科学中的实用统计学(第2版)

数据科学中的实用统计学(第2版)

Peter Bruce, Andrew Bruce, Peter Gedeck
Java持续交付

Java持续交付

Daniel Bryant, Abraham Marín-Pérez
解密金融数据

解密金融数据

Justin Pauley

Publisher Resources

ISBN: 9787115459190