Download our latest MNC Answers Application at Play Store. Download Now

Redis MCQs Solution | TCS Fresco Play | Fresco Play

Redis MCQs Solution | TCS Fresco Play | FrescoPlay | TCS


Disclaimer: The primary purpose of providing this solution is to assist and support anyone who are unable to complete these courses due to a technical issue or a lack of expertise. This website's information or data are solely for the purpose of knowledge and education.

Make an effort to understand these solutions and apply them to your Hands-On difficulties. (It is not advisable that copy and paste these solutions).

All Question of the MCQs Present Below for Ease Use Ctrl + F with the question name to find the Question. All the Best!

If you found answer for any of the questions is wrong. Please do mention in the comment section, could be useful for others. Thanks!


Redis MCQs Solution | TCS Fresco Play | Fresco Play
_______________________________________

1. Redis is single threaded.

True

2. Redis can be configured to meet different requirements by editing the configuration settings in __.

redis.conf

3. Which configuration setting specifies the file to which RDB snapshot dump is saved to _?

dbfilename

4. Which of the following is not a Key Value database?

MongoDB

5. _ is the number of sentinels that need to agree the fact that the master is not reachable and make a failover procedure promoting slave to master.

Quorum

6. When using Pipelining, will the additional memory used be high?

Yes

7. Redis is widely used as a secondary database for ___.

Caching

8. Which is the default persistence mode in Redis?

RDB

9. Which is the best way for persistence in Redis?

AOF

10. Redis provides multi-state architecture during replication where every instance can both read and write.

False

11. Which one is a difference between Memcached and Redis?

Single threaded

----------------------------------

12. ___ returns the number of elements in a set

SCARD

13. Given is a code snippet : 127.0.0.1:6379> lpush numbers 4 127.0.0.1:6379> lpush numbers 3 127.0.0.1:6379> lpush numbers 7 127.0.0.1:6379> rpush numbers 10 127.0.0.1:6379> rpush numbers 15 127.0.0.1:6379> lpush numbers 12. Which of the following will be the output for the given code?

12,7,3,4,10,15 

14. Which among the following does Redis Hashes stores?

Key value pairs

15. ___ command will add elements to the set.

SADD 

16. Consider "a" as a shared key among two processes A and B. Process A : set a 10, INCRBY a 2, get a. Process B : INCR a, get a. Which of the following will be the final value for a?

13 

17. _ sets the key to expire within the given number of seconds.

EXPIRE

18. Which among the following are the data structures that are commonly used in Redis?

Sets 

19. The _ command is used to remove the expiration from a key.

Persist

20. Sets are unordered collection of strings

True

21. _ returns an array of values.

HGET 

22. Which one of the following set command removes and returns members of a set?

SPOP

---------------------------------------------------------------

23. _ sets the key to expire within the given number of seconds.

EXPIRE

24. _ configuration setting allows you set a hard upper bound on the amount of memory that is available to a running Redis instance.

maxmemory

25. In a Redis transaction, we can use command to enter into the transaction and queue the transaction commands instead of executing them.

Multi

26. _ returns an array of values.

HGET

27. Which among the following does Redis Hashes stores?

Key value pairs

28. Which is the type of locking where the data is not actually locked but the users are notified and their changes are cancelled if another user is already modifying the data?

Optimistic locking 

29. gives the total number of bytes allocated by Redis.

used_memory 

30. _ is used to flush the transaction queue and exit from the transaction.

Discard

31. ZSCORE command returns the range of members in a sorted set, by score

False

32. The _ command is used to remove the expiration from a key.

Persist

-----------------------------------------------------

33. _ is a type of lock that allows you to limit the number of processes that can concurrently access a resource to some fixed number.

Counting semaphore 

34. Which is the short structure that Redis provides for the compact representation of Sets?

intset 

35. Which among the following factors helps in calculating the number of shards in Redis?

number of keys in single shard 

36. ---- implies the maximum allowed size of each individual element in the data structure to be encoded to ziplist short structure.

max-ziplist-value

----------------------------------------

37. Which file is configured to change persistence mode?

redis.conf

38. __ is required in distributed backend systems where cache state needs to be maintained uniformly across the systems.

Centralized cache

39. ___ is the technique of breaking down data into multiple parts.

Sharding

40. In Redis context, senders are named as _ and receivers are named as Subscribers.

Publishers

41. _ are used to store, retrieve and update data.

Commands

42. _ is an implementation of partitioning where you can send your query to a random instance and the instance will forward your query to the right node.

Query routing

43. __ is the number of sentinels that need to agree the fact that the master is not reachable and make a failover procedure promoting slave to master.

Quorum

44. __ is the memory eviction policy where keys are evicted by removing the less recently used keys first, but only among keys that have an expires set, in order to make space for the newly added data.

Volatile-lru

45. In-Memory database stores data in memory.

True

46. Lists is a sequence of ___.

Ordered element

47. __ command provides a check-and-set behavior to Redis commands.

WATCH

48. The command is used to set a lock in string dataset.

SETNX 

49. Persistent server should be the _ once the whole environment is started.

master Server

50. Twemproxy is a proxy developed at Twitter for Redis protocol for automatic partitioning among multiple redis instances and optional ejection of node if it is not available

True

51. How many commands can be send to a server in pipelining?

Multiple

52. Consider an example, where a range of users from 0 to 10000 goes to a redis instance R0 and another range of users 10001 to 20000 goes to R1. This is _ partitioning.

Range partitioning

53. In-Memory database stores data in memory.

True

54. _ is the configuration setting that tells the maximum number of items allowed in a Hash table for ziplist encoding.

hash-max-ziplist-entries 

55. Which configuration setting is used to specify the memory eviction policy in Redis?

maxmemory-samples

flushdb

maxmemory-policy

max-memory xx

56. The configuration setting in redis.conf that could be configured to the number of samples of keys to be checked, to evict keys with the oldest access time.

maxmemory-policy

maxmemory xx

maxmemory-samples

57. Which among the following is a benefit of Pipelining?

Data as batches xx

Less Commands

Primary memory

Speed



**************************************************

If you have any queries, please feel free to ask on the comment section.
If you want MCQs and Hands-On solutions for any courses, Please feel free to ask on the comment section too.

Please share and support our page!