MCPcopy Create free account
hub / github.com/apache/nifi-minifi-cpp / onSchedule

Method onSchedule

extensions/windows-event-log/TailEventLog.cpp:58–72  ·  view source on GitHub ↗

Source from the content-addressed store, hash-verified

56}
57
58void TailEventLog::onSchedule(const std::shared_ptr<core::ProcessContext> &context, const std::shared_ptr<core::ProcessSessionFactory> &sessionFactory) {
59 std::string value;
60
61 if (context->getProperty(LogSourceFileName.getName(), value)) {
62 log_source_ = value;
63 }
64 if (context->getProperty(MaxEventsPerFlowFile.getName(), value)) {
65 core::Property::StringToInt(value, max_events_);
66 }
67
68 log_handle_ = OpenEventLog(NULL, log_source_.c_str());
69
70 logger_->log_trace("TailEventLog configured to tail %s",log_source_);
71
72}
73
74void TailEventLog::onTrigger(const std::shared_ptr<core::ProcessContext> &context, const std::shared_ptr<core::ProcessSession> &session) {
75

Callers

nothing calls this directly

Calls 4

c_strMethod · 0.80
log_traceMethod · 0.80
getPropertyMethod · 0.45
getNameMethod · 0.45

Tested by

no test coverage detected