JBoss Treecache vs Pojocache عند استخدام الاختراق بدلا من النسخ المتماثل

StackOverflow https://stackoverflow.com/questions/5041550

سؤال

نحن نقوم بإعداد كتلة JBOSS ونحن نبني حل ذاكرة التخزين المؤقت الموزعة الموزعة بنيت على ذاكرة التخزين المؤقت JBOSS (غير قادر على استخدامها كذاكرة التخزين المؤقت للمستوى الثاني لطبقة ORM في علمنا).نريد استخدام إبطال وعدم النسخ المتماثل كوضع ذاكرة التخزين المؤقت.بقدر ما أستطيع أن أرى بعد (جدا) يبدو أن القليل من الحلول تبدو تعمل، ويبدو أن الكائنات وضعت في ذاكرة التخزين المؤقت والأشياء التي يبدو أن إخلاءها عند تحديثها على أي من الخوادم. هذا يقودني للاعتقاد بأن Pojocache مع أداة AOP مطلوبة فقط عند استخدام النسخ المتماثل حتى تتمكن من تكرار القيم الحقلية المحدثة فقط وليس الكائنات بأكملها.هل أنا صحيح هنا أم هل هناك أي مزايا أخرى باستخدام Pojocache على Treecache في سيناريونا؟وإذا كانت Pojocache لها مزايا، فهل ما زلنا بحاجة إلى أدوات AOP وتعليق كياناتنا مع Pojococable (نعم، نحن نستخدم JBCACHACH 1.4.1) لأننا لا نستخدم التصويت؟

التحيات جوناس هاينسون

هل كانت مفيدة؟

المحلول

PoJoCache has the ability through AOP to:

  • only replicate changed fields and not whole objects. Makes a difference if e.g. your person object containes a huge image of the person and you only change the password
  • detect changes and thus can automatically put them on the list to be replicated.

TreeCache (plain) does not need AOP, but can thus not replicate individual fields or detect what has changed so that you need to trigger replication yourself.

If you don't replicate, those points are probably irrelevant.

IIrc, you don't need the @PojocaCacheable annotation for Pojo cache - without it, you need to specify the classes to be enhanced in a different way.

I have the feeling that if you are not replicating, the plain TreeCache will be enough.

مرخصة بموجب: CC-BY-SA مع الإسناد
لا تنتمي إلى StackOverflow
scroll top