Sales1 min read167 words

5 Laravel 8 Features You Should Know

Recai Atak

PlusClouds Author

Cloud & SaaS

5 Laravel 8 Features You Should Know
Size

كما تعلمون، أصدر إطار العمل الأكثر شهرة في PHP، Laravel، نسخته الثامنة قبل بضعة أشهر، ودعونا نلقي نظرة أقرب على هذه الميزات السبعة الجميلة التي انضمت إلينا.


#1 وضع الصيانة


هذا الوضع كان موجودًا بالفعل منذ الإصدارات الأولى ولكنه أعيد تصميمه بناءً على احتياجات المطورين.

على سبيل المثال، يمكنك وضعه في وضع الصيانة بناءً على الثواني.

php artisan down — refresh=15

أو يمكنك تعيين مفتاح سري للسماح لأشخاص معينين فقط بالوصول إليه.

php artisan down — secret="1872391692361283"

#2 تجميع الوظائف


أحيانًا يمكن أن يكون لدينا مجموعات وظائف غير متزامنة ثقيلة تصبح غير قابلة للإدارة، مما يجعل من الصعب تتبع حالتها. مع Laravel 8، يمكننا الآن تجميع الوظائف.

#3 إغلاق وظيفة الطابور


في الإصدارات القديمة، كنا نقوم فقط بإرسال الوظائف، ولكن الآن يمكننا استدعاء دالة رد نداء عندما تنتهي وظائف الطابور لأداء الإجراءات اللازمة.


#4 تحديد المعدل


الآن يمكننا إعداد تكوينات حول عدد المرات التي يمكن فيها النقر على نموذج أو مسار أو عدد المرات التي يمكن فيها الوصول إلى مجموعة وظائف وفقًا لاحتياجات تطبيقنا أو منطق العمل.




ليدوشن

هل فريق المبيعات يلاحق العملاء المحتملين الخطأ؟

1.8B+ شركات — البحث دائمًا مجاني

اعثر على جهات الاتصال الخاصة بي →

No credit card · Cancel anytime

#There is no text provided for translation. Please provide the text you would like to be translated into English.

الأسئلة الشائعة

What is maintenance mode in Laravel 8 and how can you use a seconds-based refresh?

Maintenance mode is a feature that has existed since the first versions but has been redesigned to meet developers' needs. You can put it in maintenance mode based on seconds using refresh=15, for example php artisan down — refresh=15. You can also set a secret key so only certain people can access the site during maintenance.

How can you allow only certain people to access a Laravel 8 site in maintenance mode?

You can set a secret key to allow access only to those who know it. For example, php artisan down — secret="1872391692361283". This restricts access to authorized users during maintenance.

What is job grouping in Laravel 8 and why would you use it?

Job grouping allows grouping heavy asynchronous jobs to track their status more easily. This is helpful when large groups of jobs can become unmanageable.

What is the queue job closure feature in Laravel 8?

In older versions you could only dispatch jobs, but now you can call a callback function when the queue jobs are finished to perform the necessary actions. This provides a way to run follow-up tasks automatically.

What is rate limiting in Laravel 8 and how can you configure it?

Rate limiting lets you configure how many times a model or route can be accessed, or how many times a job group can be accessed, according to your application's needs. This helps tailor behavior to your business logic.

Are there visual examples in the post that illustrate these Laravel 8 features?

Yes, the post includes images that illustrate the concepts of job grouping and queue job closure.