انتقل إلى المحتوى
أمين أبوزيد
درس مخطط لهMID-042-L05

المعاملات

  • الدرس 5 من 7
  • Mid-level
في هذا الدرس 4 موضوعات

هذا الدرس مخطط له. يعرض المخطط أدناه الموضوعات التي سيغطيها، ولم يُنشر الدرس الكامل بعد.

نص الدروس والتمارين باللغة الإنجليزية، بينما تبقى واجهة الموقع وعناوين الدروس بالعربية.

في هذا الدرس

know when multi-document transactions are needed and what they cost.

الموضوعات المخطط لها

  • Single-document updates are atomic; good modeling often removes the need for transactions.
  • Multi-document transactions exist (need a replica set or sharded cluster; verify version support).
  • Cost: more latency, more locking and memory, short time limits, retries on transient errors.
  • Use them for real cross-document invariants (move a value between two documents), not as a habit.
تفاصيل المخطط المبدئي

عرض عملي

Spring @Transactional with a MongoTransactionManager bean, and a note that it fails on a standalone server.

اختبر فهمك

When is a transaction not needed?

أظهر الإجابة

When the change fits in one document, since that write is atomic.

التطبيق

طبّق هذا الدرس بمختبر الوحدة وتمارينها واختبارها.

المختبر والتمارين الاختبار

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

اكتب للبحث في المستويات والمراحل والوحدات والدروس.