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

Method setDynamicProperty

libminifi/src/core/ConfigurableComponent.cpp:254–271  ·  view source on GitHub ↗

Source from the content-addressed store, hash-verified

252}
253
254bool ConfigurableComponent::setDynamicProperty(const std::string name, std::string value) {
255 std::lock_guard<std::mutex> lock(configuration_mutex_);
256 auto &&it = dynamic_properties_.find(name);
257
258 if (it != dynamic_properties_.end()) {
259 Property orig_property = it->second;
260 Property& new_property = it->second;
261 auto onExit = gsl::finally([&] {
262 onDynamicPropertyModified(orig_property, new_property);
263 logger_->log_debug("Component %s dynamic property name %s value %s", name, new_property.getName(), value);
264 });
265 new_property.setValue(value);
266 new_property.setSupportsExpressionLanguage(true);
267 return true;
268 } else {
269 return createDynamicProperty(name, value);
270 }
271}
272
273bool ConfigurableComponent::updateDynamicProperty(const std::string &name, const std::string &value) {
274 std::lock_guard<std::mutex> lock(configuration_mutex_);

Callers 6

set_propery_internalFunction · 0.45
setPropertyMethod · 0.45
parseSinglePropertyMethod · 0.45

Calls 6

log_debugMethod · 0.80
findMethod · 0.45
endMethod · 0.45
getNameMethod · 0.45
setValueMethod · 0.45

Tested by 1

setPropertyMethod · 0.36