Perfomance Flashcards

1
Q

What is view caching?

A

It allows you to cache some pages.

How well did you know this?
1
Not at all
2
3
4
5
Perfectly
2
Q

What is Page caching?

A

Page caching store the whole page on your disk.

How well did you know this?
1
Not at all
2
3
4
5
Perfectly
3
Q

What is Action caching?

A

Page Caching cannot be used for actions that have before filters - for example, pages that require authentication. This is where Action Caching comes in.

How well did you know this?
1
Not at all
2
3
4
5
Perfectly
4
Q

What is Fragment caching?

A

Fragment Caching allows a fragment of view logic to be wrapped in a cache block and served out of the cache store when the next request comes in.

When your application receives its first request to this page,
Rails will write a new cache entry with a unique key. (with update_at timestamp)

How well did you know this?
1
Not at all
2
3
4
5
Perfectly
5
Q

Where we can store cached data?

A

1) FileStory
2) MemoryStory
3) MemCacheStore
4) RedisCacheStore

How well did you know this?
1
Not at all
2
3
4
5
Perfectly
6
Q

What is Counter Cashe?

A
The counter cache, on the other hand, stores the number of records of each associated object in its own column in
the database (We need to add a new column). This value can be retrieved as often as is needed, without requiring potentially expensive computation to take place.
How well did you know this?
1
Not at all
2
3
4
5
Perfectly
7
Q

How to disable DB caching for ActiveRecord query request?

A

Company.all.select(“SQL_NO_CACHE *”)

How well did you know this?
1
Not at all
2
3
4
5
Perfectly