Re: Making FlowFiles environment independent

2016-12-20 Thread Bryan Bende
There is no reason it can't support EL without a flow file, I created this
JIRA: https://issues.apache.org/jira/browse/NIFI-3231

EL per flow file, meaning the flow file specifies the host and port, would
require a fairly significant change to how the processor works internally,
but it doesn't sound like that is what we are talking about here.

On Tue, Dec 20, 2016 at 7:05 AM, ddewaele <ddewa...@gmail.com> wrote:

> Coming back to PutTCP, is there a reason why the hostname property doesn't
> support EL ?
>
> In both cases you mentioned you would like the option to externalise it or
> make it dynamic.
>
> Are there other ways of injecting a hostname in the PutTCP processor ?
>
>
>
> --
> View this message in context: http://apache-nifi-users-list.
> 2361937.n4.nabble.com/Making-FlowFiles-environment-
> independent-tp409p498.html
> Sent from the Apache NiFi Users List mailing list archive at Nabble.com.
>


Re: Making FlowFiles environment independent

2016-12-20 Thread ddewaele
Coming back to PutTCP, is there a reason why the hostname property doesn't
support EL ?

In both cases you mentioned you would like the option to externalise it or
make it dynamic.

Are there other ways of injecting a hostname in the PutTCP processor ?



--
View this message in context: 
http://apache-nifi-users-list.2361937.n4.nabble.com/Making-FlowFiles-environment-independent-tp409p498.html
Sent from the Apache NiFi Users List mailing list archive at Nabble.com.


Re: Making FlowFiles environment independent

2016-12-18 Thread ddewaele
Works like a charm ! Thanks.


Bryan Bende wrote
> There is a concept of a variable registry which is described in the Admin
> Guide here [1], but it is still based on expression language.
> 
> For your use case with PutTCP, are you looking to have the hostname
> paramterized across environments (dev vs prod) or are you looking to
> connect to a different host per flow file?
> 
> [1]
> https://nifi.apache.org/docs/nifi-docs/html/administration-guide.html#custom_properties





--
View this message in context: 
http://apache-nifi-users-list.2361937.n4.nabble.com/Making-FlowFiles-environment-independent-tp409p487.html
Sent from the Apache NiFi Users List mailing list archive at Nabble.com.


Re: Making FlowFiles environment independent

2016-12-12 Thread ddewaele
Thanks a lot ... I'll take a look at the variable registry.

In my case, I want to have a single flow definition (flow template) that we
can deploy in dev / prod, and have an easy way to externalise environment
specific stuff in the flow (like a tcp hostname / port)

I tried passing a system property to the PutTCP hostname property but that
didn't work (When I used ${mySystemPropertyName} the processor didn't
resolve the mySystemPropertyName but simply used "${mySystemPropertyName}"
as a string). I assume this is because the PutTCP hostname property doesn't
support expression language ?




--
View this message in context: 
http://apache-nifi-users-list.2361937.n4.nabble.com/Making-FlowFiles-environment-independent-tp409p415.html
Sent from the Apache NiFi Users List mailing list archive at Nabble.com.


Re: Making FlowFiles environment independent

2016-12-12 Thread Russell Bateman
Without completely understanding your scenario, may I suggest you insert 
UpdateAttributesto do this before PutTCP? It supports Expression Language.


Hope this helps.

Russ

On 12/12/2016 01:04 AM, ddewaele wrote:

We have a flowfile that contains a number of environment specific values
(ports / hostnames / .).

Am I correct in saying that there is no immediate variable registry
somewhere in nifi, and that all of these environment specific items need to
be passed as environment variables or java system properties ?

I understand that the nifi expression language allows us to retrieve
environment variables / system properties, but a number of processor don't
support the expression language for fields that do contain environment
specific values (like the PutTCP processor hostname property).

How should we go about updating those ?



--
View this message in context: 
http://apache-nifi-users-list.2361937.n4.nabble.com/Making-FlowFiles-environment-independent-tp409.html
Sent from the Apache NiFi Users List mailing list archive at Nabble.com.




Making FlowFiles environment independent

2016-12-12 Thread ddewaele
We have a flowfile that contains a number of environment specific values
(ports / hostnames / .).

Am I correct in saying that there is no immediate variable registry
somewhere in nifi, and that all of these environment specific items need to
be passed as environment variables or java system properties ?

I understand that the nifi expression language allows us to retrieve
environment variables / system properties, but a number of processor don't
support the expression language for fields that do contain environment
specific values (like the PutTCP processor hostname property).

How should we go about updating those ?



--
View this message in context: 
http://apache-nifi-users-list.2361937.n4.nabble.com/Making-FlowFiles-environment-independent-tp409.html
Sent from the Apache NiFi Users List mailing list archive at Nabble.com.