cq5 - JCR API or Apache Sling -


i read lot of articles jcr vs apache sling , i'm confused use. authors advise use jcr api more performance optimized , rest on side of apache sling because it's faster write , far more readable , maintainable in long run. , had questions:

  • what practice better point of view?
  • what more used in production projects?

i think maciej matuszewski exhausted subject enough in presentation jcr, sling or aem? api should use , when?.

in of cases, recommended use apache sling higher api whereas jcr required when performance needs taken account. important know border between these 2 scenarios.

maciej notices around 1ms difference opening regular aem page without taking caching account. taking care of performance totally unnecessary in case. should instead focus on writing code readable, understandable, reduced minimum , reusing existing apis, frameworks, util classes covered proper unit tests , peer reviewed, rather reinventing wheel beginning. base on that, should prefer aem layer on sling layer.

from experience, jcr should utilized in few scenarios, when traversing of large amount of data of crx database , cannot achieved searching api.

so difference between using c# or c++ programming language computer games development - in of cases enough stay higher api development convenience cases required lower , start using c++ pointers.

however, important thing not mix both abstract layers in implementation.


Comments

Popular posts from this blog

php - Vagrant up error - Uncaught Reflection Exception: Class DOMDocument does not exist -

vue.js - Create hooks for automated testing -

Add new key value to json node in java -