I am a newbie in python, I'm starting and having trouble with celery and flask, are looking forward to getting the help of you. (Sorry if my English is not good)
I'm testing with a small project using celery and flask, my program will use flask to send requests to the celery worker retrieved content is then returned to the user, however, after testing I saw after the call the function get()
of celery, it seems does not release the memory for the ram volume used convincedthat increased to very high After memory_profiler
, I see the results as follows:
Line # Mem usage Increment Line Contents
42 32.605 MiB 0.000 MiB @app.route('/test2')
43 @profile
44 def test2():
45 32.605 MiB 0.000 MiB url = 'https://www.youtube.com/'
46 42.641 MiB 10.035 MiB request_get.delay(url).get()
47 42.641 MiB 0.000 MiB url = 'https://www.youtube.com/'
48 45.422 MiB 2.781 MiB request_get.delay(url).get()
49 45.422 MiB 0.000 MiB url = 'https://www.youtube.com/'
50 47.992 MiB 2.570 MiB request_get.delay(url).get()
51 47.992 MiB 0.000 MiB url = 'https://www.youtube.com/'
52 55.102 MiB 7.109 MiB request_get.delay(url).get()
53 55.102 MiB 0.000 MiB url = 'https://www.youtube.com/'
54 57.441 MiB 2.340 MiB request_get.delay(url).get()
Didn't know there was anybody having the same problem and there is no workaround, thanks for reading