Skip to main content

Hi,

I am looking for a writter that will allow me to save blob data in FME Flow. On FME Form I am using AttributeFileWriter that is working completely fine

 

Hmm, is there a reason you want want to use the JPEG Writer for this?

Also, this should also work on FME Flow - What’s the error you’re getting on Flow


Hi, blob has to be written as image. I do not get any error in FME Flow. AttributeFileWriter does not save the images. I have tried feature writer but then the orientation of the images is gone

 


If you are using a RasterReplacer this is already turning your blob data into a Raster feature in FME. You can just use the JPEG writer instead of the AttributeFileWriter. 

You should be able to skip the RasterReplacer though if you want to stick with the AttirbtueFileWriter.

You will want to double/tripple check the output location on FME Flow. It could be that the file is getting written out to an unsuspected location. You can use loggers and parameter fetches to help figure out what’s going on with FME Flow. Debugging on FME Flow can be very frustrating.

I’ve also seen some really weird behaviour with FME Flow not processing certain parts of the workspace. Again though loggers usually help with this too. You should put a logger down before and after the AttribtueFileWriter. Then check the log file t see if both are getting features logged. 

Most (but not all) transformers have a line in the logfile like:
 

CoordinateSystemSetter (TeeFactory): Cloned 1 input feature(s) into 1 output feature(s)

This gives a clue about if a feature has come in or not. In the above case a single feature went in and out of the CoordinateSystemSetter.

And below - the Sampler_Sampled didn’t get any.

Sampler_Sampled (TeeFactory): Cloned 0 input feature(s) into 0 output feature(s)

 


Hi, thanks for your message. As I mentioned earlier, FeatureWriter does not preserve the original image orientation, all images are saved in landscape format. In contrast, AttributeFileWriter retains the correct orientation, saving images as either landscape or portrait as appropriate.

AttributeFileWriter is not made for FME Flow

 


Could you share your workspace along with the log from the failed FME Flow job?


Hi, Unfortuanately I cannot not as it has confidential data


As I mentioned earlier, FeatureWriter does not preserve the original image orientation,

 

Oh yes sorry, I don’t know how I missed that - But the AttributeFileWriter does indeed work on FME Flow it just doesn't work with the DataDownloadService. 

I’ve just tested it on FME 2024.2 and got it to write out some data.

What I will say though is that I used the output filename as a Published Parameter and the User Interface of FME Flow and the file picker didn’t work properly for determining an output location. I have to put the path in manually.


I can attest, AttributeFileWriter works on FME Flow.


Hi, If AttributeFileWriter doesn't work with the DataDownloadService how did you manage to write some data?


If you want the result of the AttributeFileWriter to be included in the Data Download archive, you should try using the writer “File Copy”. Here’s a tutorial about that : 
https://support.safe.com/hc/en-us/articles/25407442117261-Including-Files-with-the-Data-Download-Results#h_01J9CA6JWBH51V4E7W7KSV7NF9


Hi, If AttributeFileWriter doesn't work with the DataDownloadService how did you manage to write some data?

The DataDownloadService is a specific service that will zip up your output dataset and save it to a specific location which is accessible via an unauthenticated a download link. 

The JobSubmitterService for example can be use and it will just output the data to the specified output location - This could be a temp location or a Resource location

The article @alexbiz shared is perfect for what you want I think. After writing out the image with the AttributeFileWriter you give the path to the Filecopy writer to perform a move - This writer can be used in the DataDownloadService. If configured correctly then this should work well.