Your achievements

Level 1

0% to

Level 2

Tip /
Sign in

Sign in to Community

to gain points, level up, and earn exciting badges like the new
BedrockMission!

Learn more

View all

Sign in to view all badges

SOLVED

I am retrieving data from a node in JCR, which of these are more performatic?

saulovenancio
Level 2
Level 2

1. To create a java object that has a property holdign the node wehre the properties are stored and then the getter will get the value from the node strucutre?

2. or create the object while retrieving all the data from node, and then when getter is triggered it get values directly from java object

Is there any performance difference?

THnaks.                

1 Accepted Solution
prajesh
Correct answer by
Level 2
Level 2

I would suggest go with Option 2. it holds the data in your object and avoids traversing the repository every time you call your get method.

View solution in original post

1 Reply
prajesh
Correct answer by
Level 2
Level 2

I would suggest go with Option 2. it holds the data in your object and avoids traversing the repository every time you call your get method.

View solution in original post