Using Cache for Repository Elements

Technology specific object identification, supported applications, web technologies, and 3rd party controls.
annavamsi
Posts: 20
Joined: Wed Sep 14, 2016 10:55 pm

Using Cache for Repository Elements

Post by annavamsi » Fri Mar 17, 2017 5:14 am

Hi,

I have a scenario where in I want to know if I can set the "Use Cache" Property of the rooted folder in the repository to True.

I have a object(this is a rooted object folder) in repository which identifies a particular segment based on index number where in the index number is a variable which i can set in the code, so that i have one object which identifies any segment based on index number.

In the above scenario can I set the "Use Cache" Property to True or not?

Regards,
Vamsi

krstcs
Posts: 2683
Joined: Tue Feb 07, 2012 4:14 pm
Location: Austin, Texas, USA

Re: Using Cache for Repository Elements

Post by krstcs » Fri Mar 17, 2017 2:21 pm

In practice, you should be using the cache all the time. You should only turn it OFF if it is actually causing issues. The cache helps speed up identification, and therefore the tests.
Shortcuts usually aren't...

annavamsi
Posts: 20
Joined: Wed Sep 14, 2016 10:55 pm

Re: Using Cache for Repository Elements

Post by annavamsi » Mon Mar 20, 2017 4:55 am

I get what you said, but in my scenario can we use it when we are having same root element folder identifying multiple layouts with index as a variable.

I also get the following waning messages in the report.
1. <ObjectName> could be found using its absolute path, but not using its relative path from the cached element of parent folder ...

2. Failed to update the cached element for folder ......

Is issue 2 because of folder having a variable in it?

Regards,
Vamsi

User avatar
qwertzu
Posts: 284
Joined: Wed Jan 25, 2017 11:08 am

Re: Using Cache for Repository Elements

Post by qwertzu » Mon Mar 20, 2017 12:27 pm

Hi annavamsi,
Is issue 2 because of folder having a variable in it?
Using a variable in a rooted folder path where cashing is set to true should be no problem.

Regarding the error "Failed to update the cached element for folder ... " :

There was a bug in a previous Ranorex Version, which has already been fixed.
So you could try to update to the latest version :-)