1

I'm new to Apama. I see that a com.apama.file lib exists, but I am unsure how to actually use it to read a file. I want to send each line as an event to be parsed and then depending on the contents sent as a different event from there, but googling suggests that I'd need a transport (not sure what that is either) to do so, but my project lead is under the impression that this can all be done using Apama EPL. How true is this and if it has some validity, how can I go about achieving that?

Nikhil Jindia
  • 121
  • 1
  • 10
  • Hi - Your question is quite vague - to get a proper answer you will need to show what you have done so far. it might help if you look at https://github.com/SoftwareAG/apama-streaming-analytics-connectivity-FileTransport – Caribou Jun 25 '20 at 09:00

2 Answers2

1

Yes, this is certainly possible. To help you do it, though, please can you provide a little more information about your setup? For example, what is the file type and is the file local to where the correlator will be running? Will there only be one file to process at a time? How large is the file, and are there any specific performance requirements?

You may find this helpful: https://github.com/SoftwareAG/apama-streaming-analytics-connectivity-FileTransport

imog
  • 11
  • 3
  • After talking to my project lead he was under the impression that you could just yank information out of a text file using apama and send it to Cumulocity. Our goal is to send pertinent data from a log file that is being read and written simultaneously (read-only by Apama) and send that data up to Cumulocity to be analyzed by another Apama program to make a dashboard of some sort. With my understanding of Apama, the best way to do this would be to directly create an .evt file from the programs that initially wrote the log file and have Apama read that as it's being written. Is that correct? – Nikhil Jindia Jun 25 '20 at 14:35
0

You don't say quite what you are trying to achieve, but if you are new to Apama then I will say that that is not something that is done frequently, especially in simpler solutions when your are just starting.

Depending what you are trying to achieve, are you aware of the "engine_send" tool and the ability to use it to send in a text file of Apama events (normally a .evt file), and with batch tags if you want spread them over time?

  • After talking to my project lead he was under the impression that you could just yank information out of a text file using apama. Our goal is to send pertinent data from a log file that is being read and written simultaneously (read-only by Apama) and send that data up to Cumulocity to be analyzed by another Apama program to make a dashboard of some sort. With my understanding of Apama, the best way to do this would be to directly create an .evt file from the programs that initially wrote the log file and have Apama read that as it's being written. Is that correct? – Nikhil Jindia Jun 25 '20 at 14:33
  • Thanks for the extra info. We of course are happy for people to use Apama in many scenarios, but we also want it to be the appropriate tool for the job. If ALL of your Streaming Analytics (SA) is to be performed "server-side" with the Apama inside Cumulocity, then Apama might not be the appropriate technology to choose client-side if the only purpose is to read/tail a file and send as Measurements to Cumulocity REST API. If however you might do SA client-side then use Apama there. You can do it using the link Ian posted above, but then you're just using Apama as integration bus. (Many do!) – Kev Palfreyman Jun 25 '20 at 16:14