Skip to main content
Solved

KAFKA porvides a file. What's next?


Hi,

The KAFKAConnector works fine und provides me features with a filename "key"and the file itself "value". In my case "value" holds a zip-file with Shape-Layers.

How can I access the features in the zip-Files?

 

The content of "value" starts e.g.:"504B0304140008080800117242540000000000000000000000000C00000036313231396E67722E646266A4BD49AEB5C9921C5622454D04021A68016F2EBC83E89B2121160942608352092047DA8776A389D629B3F81AF76391F578322A1F2A2BF2FEFFBDD74F34DE9A9BFFCBFFE75FFC8B7FF53FFEDDDFFDBFFFC3FFF777DB3FFFCBDFFDDDBFF987BFFF37F77FFD3BFEEB7FFD57DF7FE5BFFCFD3FFC87FFF8F7FFF8F7FFF04FFCF9BFFF87FFEB3FFDDBFF7B2DFF13FFF53....

 

I think, I have to write this somehow to the filesystem. Maybe using the FeatureWriter Format: DATAFILE

And then use the FeatureReader.

 

Any Ideas?

 

regards

Herfried

Best answer by caracadrian

Use AttributeFileWriter with "value" as Source Attribute and "key".zip (if it is a zip) to Target Filemane.

Then use ZipExtractor and FeaureReader if you need to access the data.

View original
Did this help you find an answer to your question?

4 replies

caracadrian
Contributor
Forum|alt.badge.img+23
  • Contributor
  • Best Answer
  • February 3, 2022

Use AttributeFileWriter with "value" as Source Attribute and "key".zip (if it is a zip) to Target Filemane.

Then use ZipExtractor and FeaureReader if you need to access the data.


david_r
Evangelist
  • February 3, 2022
caracadrian wrote:

Use AttributeFileWriter with "value" as Source Attribute and "key".zip (if it is a zip) to Target Filemane.

Then use ZipExtractor and FeaureReader if you need to access the data.

Or simply read the data directly from the zip, if the format reader supports it (most file-based readers do).


caracadrian
Contributor
Forum|alt.badge.img+23
  • Contributor
  • February 3, 2022
david_r wrote:

Or simply read the data directly from the zip, if the format reader supports it (most file-based readers do).

Thanks for reminding me of that option!


  • Author
  • February 3, 2022

Thank you for your help.

The AttributeFileWriter and FeaureReader work fine and I will go with that.

 

Maybe one day there will be a solution without a detour over the filesystem.

 


Cookie policy

We use cookies to enhance and personalize your experience. If you accept you agree to our full cookie policy. Learn more about our cookies.

 
Cookie settings