event_example.d/ 폴더에서 다음 콘텐츠가 있는 event_example.yaml(이)라는 설정 파일을 만듭니다.
instances:[{}]
conf.d/ 폴더에서 한 수준 위에 위치한 checks.d/ 폴더로 이동합니다.
이 폴더에서 다음 콘텐츠가 있는 event_example.py(이)라는 커스텀 점검 파일을 만듭니다.
event_example.py
fromdatadog_checks.baseimportAgentCheck__version__="1.0.0"classMyClass(AgentCheck):defcheck(self,instance):self.event({"timestamp":time.time(),"event_type":"Error","msg_title":"이벤트 예시","msg_text":"Datadog의 이벤트 예시입니다.","alert_type":"error",})