عرض عملي: تجويع الخيوط في خدمة حية
في هذا الدرس 3 موضوعات
هذا الدرس مخطط له. يعرض المخطط أدناه الموضوعات التي سيغطيها، ولم يُنشر الدرس الكامل بعد.
نص الدروس والتمارين باللغة الإنجليزية، بينما تبقى واجهة الموقع وعناوين الدروس بالعربية.
في هذا الدرس
diagnose a hung endpoint with thread dumps; prepares MID-008-LAB1.
تفاصيل المخطط المبدئي
خطوة بخطوة
- Under load Shop slows then stops responding; CPU is low.
- Take three thread dumps; most request threads are WAITING in
Future.getor BLOCKED on one lock. - Find the owner thread and the code path holding the lock while doing remote I/O.
- Planned mistake: restart the service and move on. Fix: save the dumps first; they are the evidence.
- Move the remote call outside the critical section (or increase isolation with a separate pool); repeat the load test.
- Confirm with a fresh dump and JFR lock-contention events that waiting is gone.
التطبيق
طبّق هذا الدرس بمختبر الوحدة وتمارينها واختبارها.
تعليم الدرس كمكتمل اختياري ويمكنك التراجع عنه في أي وقت. يبقى تقدمك محفوظًا في هذا المتصفح.