Hi Everyone,
I’ve got a wisej app running on an externally hosted 3rd party IIS server. I need to periodically run/load a page in the app so that it triggers a bunch of checks to carry out based on timed events. I was thinking along the lines of running a CRON job. I don’t have my own Windows server nor an ‘always-on’ machine, but I do have a Synology NAS device that can run scheduled python or shell scripts (ash linux). I checked with the IIS hosting company that I’m using and they will only run a scheduled task every 20 minutes, but I need it to run at least every 5 minutes.
Anyway, I threw together some python using ‘httplib’ module to load the html page that I thought would run the wisej application, but it doesn’t appear to work. Tried a similar thing with shell script using ‘wget’, which only downloads the html page structure but doesn’t actually start the app. After a couple of days trying various python and shell scripts and nothing working, I found a website called cron-job.org that is supposed to trigger a page load of your choosing at a set time/interval, but that doesn’t work either.
So, I’m not sure where to go from here or if my approach is completely wrong or not. If I had a spare windows machine kicking around then this sort of scheduled task would be a cinch, but such is life!
Has anybody tackled this sort of problem before and if so, what approach do you use?
Thank you in advance!
Sorry I didn’t reply sooner. Just requesting the HTML page will not work. All you get back is the HTML page. The requester (which is usually the browser) has to execute javascript. It’s the same for all javascript web apps. If you request a page with angular or jquery all you get back is the page with the links.
It’s a lot better to start the process using server code and don’t rely on an external timer or requester. You build a simple monitor app in Wisej and launch threads or processes and manage them. The third party IIS allows you launch threads.
The only issue is that when IIS recycles it will kill the threads in the same app pool. I believe it can be turned off for a specific app pool.
Best,
Luca
Why not just call a url on your WiseJ site from Python with a URL parameter – different values for the different tasks
Read the parameter – there were a few examples in the posts, and depending on tthe value of the parameter – do different things.
Hi Andrew,
I think a scheduled task will do as long as it runs a batch file like
“\Program Files (x86)\Google\Chrome\Application\chrome.exe” wisej.com
Please login first to submit.