如何为NiFi设置分布式地图缓存? [英] How does one setup a Distributed Map Cache for NiFi?

查看:233
本文介绍了如何为NiFi设置分布式地图缓存?的处理方法,对大家解决问题具有一定的参考价值,需要的朋友们下面随着小编来一起学习吧!

问题描述

我是NiFi的新手,只是在玩处理器.

I'm brand new to NiFi and simply playing around with processors.

我正在尝试在测试中合并WaitNotify处理器,但是我必须设置一个分布式映射缓存(服务器客户端?).

I'm trying to incorporate Wait and Notify processors in my testing, but I have to setup a Distributed Map Cache (server and client?).

NiFi文档假定我没有一定的了解水平.

The NiFi documentation assumes a level of understanding that I do not have.

我已经在计算机(macOS)上安装了memcached,并验证了它在端口11211上运行(默认).我已经在NiFi的CONTROLLER SERVICES下创建了DistributedMapCacheClientServiceDistributedMapCacheServer,但是我得到了java.net.SocketTimeoutException&其他错误.

I've installed memcached on my computer (macOS) and verified that it's running on Port 11211 (default). I've created a DistributedMapCacheClientService and DistributedMapCacheServer under NiFi's CONTROLLER SERVICES, but I'm getting java.net.SocketTimeoutException & other errors.

关于整个主题是否有很好的教程?有人可以建议如何前进吗?

Is there a good tutorial on this entire topic? Can someone suggest how to move forward?

推荐答案

DistributedMapCacheClientServiceDistributedMapCacheServer不需要其他软件.

要创建这些服务,请右键单击画布,选择Configure,然后选择Controller Services选项卡.然后,您可以通过单击右侧的+按钮并按名称搜索来添加新服务.

To create these services, right-click on the canvas, select Configure and then select the Controller Services tab. You can then add new services by clicking the + button on the right and searching by name.

  1. 使用默认参数(端口4557)创建DistributedMapCacheServer并将其启用.这将启动内置的缓存服务器.

  1. create DistributedMapCacheServer with default parameters (port 4557) and enable it. this will start built-in cache server.

使用主机名localhost和其他默认参数创建DistributedMapCacheClientService并将其启用

create DistributedMapCacheClientService with hostname localhost and other default parameters and enable it

创建简单流GenerateFlowFile设置run schedule且参数中的字节大小不为零. 将其连接到PutDistributedMapCache并将Entry Identifier设置为Key01并选择DistributedMapCacheClientService

create a simple flow GenerateFlowFile set the run schedule and not zero bytes size in parameters. connect it to PutDistributedMapCache set Entry Identifier as Key01 and choose your DistributedMapCacheClientService

尝试运行它.如果其他软件未使用端口4557,则放置缓存应正常工作.

try to run it. and if port 4557 not used by other software the put cache should work.

这篇关于如何为NiFi设置分布式地图缓存?的文章就介绍到这了,希望我们推荐的答案对大家有所帮助,也希望大家多多支持IT屋!

查看全文
登录 关闭
扫码关注1秒登录
发送“验证码”获取 | 15天全站免登陆