0

I have a simple django view which just reads the request and prints it out into the console. Now along with the request body I need to get the start time of the view for a particular session and if after the session has been terminated or there is no request incoming for that particular view for about 1 min, I need to print out a custom string "Device Stopped".

Can anyone please help me out to solve this issue. Thanks!

Abijith Mg
  • 2,647
  • 21
  • 35
Sayantan Mukherjee
  • 205
  • 1
  • 4
  • 13
  • Possible duplicate of [Timeout on a function call](https://stackoverflow.com/questions/492519/timeout-on-a-function-call) – Abijith Mg May 23 '17 at 14:21
  • Thank you. I have already tried it. But I need specific solution for django WSGI requests. – Sayantan Mukherjee May 23 '17 at 16:54
  • F.Y.I. My application is somewhat like this : [Click Here](https://stackoverflow.com/questions/16212161/how-to-connect-my-django-app-with-incoming-data-on-a-tcp-port) I just want to get the start and stop time of the tcp connection – Sayantan Mukherjee May 23 '17 at 18:26

0 Answers0