Unanswered question

trying to send with a parameterized sourcefile doesn't send the file

I have a parameter with paths to the correct files and want to loop over them. When using the hardcoded path, there's no problem but once I start replacing the path with variables the file is no longer sent along.
I've used the "filename" to check for the validity of the path but couldn't spot any mistakes here.
Could you maybe help me? Do you need any more information?

Geert V.
Geert V.

Geert V.

Level
0
85 / 100
points

Answers

Nouredine A.
Nouredine A.

Nouredine A.

Level
4
5000 / 5000
points
Team

You should store the files that you would like to upload inside your project folder under the "custom-resources" folder.

Then in your request you can use ${NL-CustomResources} as relative path to point to your files.

For instance, it will be something like that: ${NL-CustomResources}/${FV_uploadFiles.File}

Geert V.
Geert V.

Geert V.

Level
0
85 / 100
points

I've tried using this but the "custom resources" point to a different location.
They point to "C:\Users\User\AppData\Roaming\Neotys\NeoLoad\v5.3\custom-resources". In this file there are no files available.
In my project, there also is a file called "Custom-resources", with the files that I'd like to use, but this file is ignored.

So adding the "${NL-CustomResources} didn't help sadly. Anything else I can try?

Nouredine A.
Nouredine A.

Nouredine A.

Level
4
5000 / 5000
points
Team

I'm not sure from your response if you tried it or not. ${NL-CustomResources} is indeed replaced by an absolute path on your LG. If you copy your files under your project folder under that "custom-resources" folder all the files will be copied into the LG under that path C:\Users\User\AppData\Roaming\Neotys\NeoLoad\v5.3\custom-resources. This is automatically done by NeoLoad.

That's why using ${NL-CustomResources}/${FV_uploadFiles.File} in your request should work.

Geert V.
Geert V.

Geert V.

Level
0
85 / 100
points

I've created a video of what happens.
I'm not using the ^${NL-CustomResources}, altough i've tried without any avail.

I hope this video explains my problem.
https://goo.gl/photos/ZEbG4hHwaMuD1LbQ8

Geert V.
Geert V.

Geert V.

Level
0
85 / 100
points

Also, i've added the "data" directory to the Custom-resources like you've asked. These are not copied on runtime.
See screenshot for proof.

Nouredine A.
Nouredine A.

Nouredine A.

Level
4
5000 / 5000
points
Team

You should not add your data folder inside that custom-resources folder. You just need to copy all your files inside that <project_folder>\custom-resources folder and then in your POST request use exactly that syntax: ${NL-CustomResources}/${FV_uploadFiles.File}

You do not have to take care about the path. It is expected to work like this whatever your load generators OS.

Geert V.
Geert V.

Geert V.

Level
0
85 / 100
points

Hey,

I've added the files directly to the custom-resources folder. Changed the URL to the one you described and ran the check again.
There was no change in result. I've added more screenshots and the logfile of the check for you to verify. Hopefully this provides you with enough information.

Nouredine A.
Nouredine A.

Nouredine A.

Level
4
5000 / 5000
points
Team

In the custom-resources folder i can see your file but with that file name: GR-test alt brexp.csv with blank space. But in the file that you are requesting in your URL the name is GR-testaltbrexp.csv without spaces.

Could you make sure that the name in your variable files are exactly the same that the files you copied in the custom-resources folder?

The best would be to avoid any blank spaces.

 

Geert V.
Geert V.

Geert V.

Level
0
85 / 100
points

I've made the alterations but this didn't work.
I've removed the blank spaces and kept the variable.
Also removed the variable and kept the spaces.
But both just send an empty file.

Nouredine A.
Nouredine A.

Nouredine A.

Level
4
5000 / 5000
points
Team

In your load generator, if you go into the absolute path that is replaced with the ${NL-CustomResources} variable, do you see your files?

All the files that are stored inside your project folder under "custom-resources" folder are synchronized to that absolute path replaced for that ${NL-CustomResources} variable.

You have the full path in your POST request.