محدود کردن قبلِ از کار افتادن سیستم از لینکدین Shahab Bozorgi
ا Throttling یکی از روشهای مهم برای مدیریت درخواستها و جلوگیری از فشار بیش از حد روی سرورهاست تو این پست باهاش آشنا میشیم
تو جنگو میتونیم با استفاده از DRF خیلی راحت Throttling رو پیادهسازی کنیم این قابلیت بهمون کمک میکنه تعداد درخواست هایی که هر کاربر یا کل سیستم میتونه در یک بازه زمانی مشخص بفرسته رو کنترل کنیم
چجوری از Throttling تو DRF استفاده کنیم؟! ا DRF چند نوع Throttle پیشفرض داره: AnonRateThrottle → برای کاربران ناشناس UserRateThrottle → برای کاربران لاگین کرده ScopedRateThrottle → برای محدود کردن درخواستها در سطح API خاص کافیه این تنظیمات رو توی settings.py اضافه کنیم و مقدار دلخواهمون رو تنظیم کنیم با این روش از overload شدن سرور هم جلوگیری میکنیم.
محدود کردن قبلِ از کار افتادن سیستم از لینکدین Shahab Bozorgi
ا Throttling یکی از روشهای مهم برای مدیریت درخواستها و جلوگیری از فشار بیش از حد روی سرورهاست تو این پست باهاش آشنا میشیم
تو جنگو میتونیم با استفاده از DRF خیلی راحت Throttling رو پیادهسازی کنیم این قابلیت بهمون کمک میکنه تعداد درخواست هایی که هر کاربر یا کل سیستم میتونه در یک بازه زمانی مشخص بفرسته رو کنترل کنیم
چجوری از Throttling تو DRF استفاده کنیم؟! ا DRF چند نوع Throttle پیشفرض داره: AnonRateThrottle → برای کاربران ناشناس UserRateThrottle → برای کاربران لاگین کرده ScopedRateThrottle → برای محدود کردن درخواستها در سطح API خاص کافیه این تنظیمات رو توی settings.py اضافه کنیم و مقدار دلخواهمون رو تنظیم کنیم با این روش از overload شدن سرور هم جلوگیری میکنیم.
BY جنگولرن
Warning: Undefined variable $i in /var/www/tg-me/post.php on line 283
If riding a bucking bronco is your idea of fun, you’re going to love what the stock market has in store. Consider this past week’s ride a preview.The week’s action didn’t look like much, if you didn’t know better. The Dow Jones Industrial Average rose 213.12 points or 0.6%, while the S&P 500 advanced 0.5%, and the Nasdaq Composite ended little changed.
What is Telegram?
Telegram’s stand out feature is its encryption scheme that keeps messages and media secure in transit. The scheme is known as MTProto and is based on 256-bit AES encryption, RSA encryption, and Diffie-Hellman key exchange. The result of this complicated and technical-sounding jargon? A messaging service that claims to keep your data safe.Why do we say claims? When dealing with security, you always want to leave room for scrutiny, and a few cryptography experts have criticized the system. Overall, any level of encryption is better than none, but a level of discretion should always be observed with any online connected system, even Telegram.