Keep a request in C # - Rest

1

The doubt I have is more conceptual than in code.

I have a rest that is a service on the server, the same is done in C #, I would like every day at a specific time it would request a URL X. I thought of putting a timer in my dekstop application made in C # consumes the rest and call the url in question, but I stopped in the draw that the computer that consumes the rest is not connected. Can I make the service itself see a timer inside it and call my URL, or something like that?

    
asked by anonymous 12.01.2018 / 14:05

1 answer

1

Not on an api rest, what you can do is schedule this task on the application server or develop it is a windows service that will be running there. You can also add this job to the database (if your application and structure have any).

Conceptually, since you do not depend on the return of data in the execution of the method of this API Rest, it would make more sense the option of windows service but instead of communicating with your rest, already carry out the routine that you want. >     

12.01.2018 / 14:26