Send yo mysql

Questions and answers on how to get the most out of FFAStrans
Post Reply
taurojo
Posts: 35
Joined: Mon Dec 19, 2016 2:44 pm

Send yo mysql

Post by taurojo »

I like save the history convert to.external MySQL.
Any workflow for that?

I can send data to create API in PHP and save to mysql. Ir Python script to my Server MySQL update script.

Any sugestión?
emcodem
Posts: 1811
Joined: Wed Sep 19, 2018 8:11 am

Re: Send yo mysql

Post by emcodem »

Hi taurojo,

sure, there are many ways to do that.
One is to do a while (true) loop in a powershell script that asks the history api: http://localhost:65445/api/v2/history/? ... &count=250 then parses the resulting JSON and inserts the data into your mysql. This will require lots of scripting work, alone parsing json is a nightmare in Powershell.
Another one is to prepare one commandline processor that you insert the data into mysql at the end of your workflow.

Another one is to use the http processor to call your php site and send the relevant data on job success or fail. You would also add the needed processor in each and every workflow at the correct spots. Use Processor Presets to make your life easy.

Yet another one is to read the monitor log file and transform/insert the data accordingly (but i would not recommend this, the monitor log can change or dissapear at any next release, e.g. ffastrans might hopefully change from files to database, then all files are gone!)
emcodem, wrapping since 2009 you got the rhyme?
Post Reply