We are running NiFi 1.10 and have defined a Parameter Context. This has been assigned to a Processor Group, and a ListFTP processor has been added to our flow. In the parameter context, there is a parameter called ftp.password, which is set as a sensitive parameter and the password as its value. Then in the ListFTP processor, this parameter is referenced by #{ftp.password}. However, it does not seems to work as it seems to be unable to resolve the parameter. It fails to login to the FTP server, but if I put the password directly into the password field, omitting the use of a parameter value, it works.
Apart from these steps, is there anything else that needs to be done?
Creating Parameter Context.
Assigning Parameter Context to Processor Group.
Creating a Parameter (ftp.password), sensitive is checked.
Assigning Parameter to ListFTP's Password field: #{ftp.password}
P.S. Followed this document: https://nifi.apache.org/docs/nifi-docs/html/user-guide.html#parameter-contexts
Indeed. Devs are investigated about this and found the logic for some processors are different. See this. I think you already report this and got the reason for what is wrong.
It will be fixed in the next version.
Related
I have a requirement to set a parameter say a timestamp in a parameter file using a command task that triggers a Unix shell script that does this task in a workflow and later in the same workflow, use the parameter that is set earlier. Is that possible?
The informatica version used is 9.6
You need to define the Parameter file property on a Session. Not just set the parameter value for a session, but make the session read the paramfile.
With Workflow parmeter file it works like this (briefly speaking):
Workflow is initialized and reads the assigned parameter file. All variables are set.
Upon session initialization all the variables and parameters are already set .
The file is not read again, variables are not re-set.
However, once a parameter file is defined as Session property, it works in a bit different way.
Workflow is initialized and reads the assigned parameter file. All variables are set.
Session is initialized, and it reads its own parameter file, setting all variables and parameters.
In this case, the values defined in session parameter file will be used.
Of course, it is not necessary to use Workflow level parameter file.
It is also possible to have one session that generates the parameter file for the very next session to use it. Provided it is defined as session property, as mentioned above.
I got the solution :). Dont know if there is any other option. But the trick that worked for me is, if you have to set a parameter and then read back the parameter to use it in the same workflow sue to whatever requirement, then you can set the parameter and then use it in a session inside a worklet, and this perfectly works. I am not sure why but this definitely works :)
You can use the Assignment task for this purpose. Set a workflow variable and use it wherever you want in the same workflow.
I am working on a Jmeter LDAP test plan and the test plan has to populate an attribute on the LDAP that is multi-valued.
When I do an LDAP search sampler, I noted that the value I get back is a string, with the values separated by ", ".
But, if I take the same comma-separated string and try to do an LDAP modify or add, using either an LDAP Request or LDAP Extended Request, I get an error.
So I am wondering if there is a way that the Jmeter LDAP Request or LDAP Extended Request can do that?
Thanks,
Jim
EDIT: When I try to use an Extended LDAP Request modification test/add with the attribute of "", I get this error in the Jmeter GUI response:
When attempting to modify entry cn=xxx... to replace the set of values for attribute lastlogindate, value "20181023085627-04, 20181024063205-04" was found to be invalid according to the associated syntax: The provided value "20181023085627-04, 20181024063205-04" is not a valid generalized time value because it contains an invalid character '-' at position 14
The strange part is that even though I have Jmeter to log at debug level, I don't see any detail on the error in the Jmeter.log, but/so I am guessing that that error message is coming from the Jmeter client itself. I noticed that the message says:
to replace the set of values
so it seems like it recognizes that I am trying to modify/replace a multi-value, but it doesn't seem to like the syntax of the replacement values string(s).
Does anyone know what the correct format SHOULD be?
I found the answer to my own question, or at least "A" answer: It appears that I can use an Extended LDAP request, and add the same attribute in that request, multiple times. So for example, if I am populating an attribute named "foo" the Extended LDAP request would have the following:
attribute value opcode
foo 12345 add
foo 12346 add
etc.
I think I also need to do a replace with no value, to empty the attribute, before all the adds.
I am testing a flow in NIFI that checks for specific value of a counter using REST API. I am able to extract it correct value from REST response. However, when I check the condition in Route on Attribute processor, the expected matched condition's results are routing to unmatched processor.
Attached is the :
Flow and configuration
I have already checked my response to be "1". But its routing to unmatched branch.
Is there something wrong with NIFI expression language I am using?
Jasim,
Initial setup check counter attribute in which value is 1.
And modify the expression language like ${counter:equals('1')} or ${counter:matches('1')} instead of contains.
because contains not suitable for your scanerio.
Hope this helpful for you.
I am trying to use go cd for continuous delivery and create a pipeline for the same. I m able to get success result after running the job but in that job i did not pass any parameter.I want to pass parameter in custom command to reduce repetition within my configurations.
We can pass parameter via a environment variable -eg If you want to pass a version in your custom command and value is 1.2.4 so define the value in environment variable and pass the value in your command for example ./abc #{version}.
You might get error while editing the command (Parameter is not defined error) add the same varibale in parameter tab as well .[![enter image description here][2]][2]
I could not get the clear picture of what you are expecting. But as far as I could understand, you want to perform a custom command task by passing few parameters as input.
When you choose custom command, you will get something like
In Arguments block, you could give the input parameters you need to pass for that particular task.
Edit : I think this may help you.
Parameterize your Configuration
Please go through this link and see whether this helps you. They had explained about defining and using the parameter in a pipeline
I'm running in to an issue in that I need to get one value in a cucumber statement, and then give that value to another statement.
Specifically I am getting a JSON object from one page (where that object gets sent to an api endpoint as a preference) and then using information out of that after I query the api, which happens in a completely separate step.
I am suspecting that I have to write the value somewhere, and then pull that value when the step that needs it comes up, but I'm kind of at a loss for doing that as well.
I can provide any further needed details, thanks for any help!
Definitely a rookie question - to which the answer is to use instance variables - #variable_name = get_method in the helper method your step calls.