FLeeC: a Fast and Lock-Free Applicational Cache

Bibliographic Details
Main Author: Costa, André João César
Publication Date: 2023
Format: Master thesis
Language: eng
Source: Repositórios Científicos de Acesso Aberto de Portugal (RCAAP)
Download full: http://hdl.handle.net/10362/165841
Summary: Access to data in applications that make use of external storage systems (e.g., Databases) can be a major performance bottleneck. A common solution is to first query a cache application to reduce data access overhead. These cache applications leverage fast main memory access rates and the parallelism capabilities of hardware to provide high performance. To this end, a cache application needs a concurrency control mechanism to maintain correctness under conflicting concurrent accesses, of which mutual-exclusion locks (blocking concurrency control) are the most common mechanism used. Blocking concurrency control strategies fail to provide a high level of performance when under medium to high contention, as the pessimistic nature of blocking concurrency can not completely avoid needlessly synchronizing operations that do not conflict. Conversely, non-blocking (or lock-free) concurrency control strategies can provide high degrees of performance in parallel shared memory contexts, especially in high contention scenarios. This work proposes FLeeC, an application-level cache system based on Memcached, which leverages non-blocking re-designed data structures concurrency to improve performance by allowing any number of concurrent writes and reads to its main data structure. FLeeC features a hash table with embedded eviction policy to allowthe correct functioning of its non-blocking algorithms; a memory reclamation scheme adapted to cache semantics; a non-blocking hash table expansion mechanism to preserve the strong progress guarantees that non-blocking concurrency provides; and dedicated replacement algorithm to minimize false misses that can occur in non-mutually exclusive environments. We have extensively evaluated FLeeC under varied scenarios and workloads and found that, when compared to Memcached, it is capable of achieving 6× higher performance when under high contention scenarios, 1.2× higher performance when under low contention scenarios and equivalent performance in scenarios with no contention. FLeeC can thus be used to further improve the performance of any application that currently uses Memcached
id RCAP_390113016a44e36c00b8e2eeec22652c
oai_identifier_str oai:run.unl.pt:10362/165841
network_acronym_str RCAP
network_name_str Repositórios Científicos de Acesso Aberto de Portugal (RCAAP)
repository_id_str https://opendoar.ac.uk/repository/7160
spelling FLeeC: a Fast and Lock-Free Applicational CacheCachingConcurrencyNon-BlockingLock-FreeDomínio/Área Científica::Engenharia e Tecnologia::Engenharia Eletrotécnica, Eletrónica e InformáticaAccess to data in applications that make use of external storage systems (e.g., Databases) can be a major performance bottleneck. A common solution is to first query a cache application to reduce data access overhead. These cache applications leverage fast main memory access rates and the parallelism capabilities of hardware to provide high performance. To this end, a cache application needs a concurrency control mechanism to maintain correctness under conflicting concurrent accesses, of which mutual-exclusion locks (blocking concurrency control) are the most common mechanism used. Blocking concurrency control strategies fail to provide a high level of performance when under medium to high contention, as the pessimistic nature of blocking concurrency can not completely avoid needlessly synchronizing operations that do not conflict. Conversely, non-blocking (or lock-free) concurrency control strategies can provide high degrees of performance in parallel shared memory contexts, especially in high contention scenarios. This work proposes FLeeC, an application-level cache system based on Memcached, which leverages non-blocking re-designed data structures concurrency to improve performance by allowing any number of concurrent writes and reads to its main data structure. FLeeC features a hash table with embedded eviction policy to allowthe correct functioning of its non-blocking algorithms; a memory reclamation scheme adapted to cache semantics; a non-blocking hash table expansion mechanism to preserve the strong progress guarantees that non-blocking concurrency provides; and dedicated replacement algorithm to minimize false misses that can occur in non-mutually exclusive environments. We have extensively evaluated FLeeC under varied scenarios and workloads and found that, when compared to Memcached, it is capable of achieving 6× higher performance when under high contention scenarios, 1.2× higher performance when under low contention scenarios and equivalent performance in scenarios with no contention. FLeeC can thus be used to further improve the performance of any application that currently uses MemcachedO acesso a dados pode ser uma limitação de desempenho em aplicações que utilizam sistemas de armazenamento externos (e.g. Bases de dados). Uma solução comum consiste em primeiro fazer pedidos a uma cache aplicacional par reduzir o custo associado ao acesso a dados. As caches aplicacionais aproveitam a velocidade de acesso à memória principal assim como as capacidades de paralelismo presentes no hardware para proporcionar alto desempenho. Para este fim, uma cache aplicacional precisa de mecanismos de controlo de concorrência para garantir correção na presença de acessos concorrentes conflituosos. O mecanismo de controlo de concorrência mais comum baseia-se em garantir exclusão mútua em acessos a estruturas de dados. Estes mecanismos (bloqueantes) não conseguem fornecer um alto teor de desempenho quando os níveis de contenção são médio-altos, pois a sua natureza pessimista não consegue evitar totalmente sincronização entre duas operações não conflituosas. Por outro lado, mecanismos de controlo de concorrência não bloqueantes permitem alto desempenho, especialmente em cenários de alta contenção. Este trabalho propõe o FLeeC, uma cache aplicacional baseada no Memcached, que aproveita estruturas de dados redesenhadas não bloqueantes paa melhorar o desempenho ao não restringir o número de escritas e leituras feitas concorrentemente na sua estrutura de dados principal. O FLeeC tem uma hash table com uma política de eviction embebida com o fim de garantir correção na utilização de algoritmos não bloqueantes; um esquema de reutilização de memória adaptado às semânticas de uma cache; um algoritmo não bloqueante de expansão da sua hash table para manter garantias de progresso fortes provenientes da filosofia não bloqueante; e um algoritmo de substituição que minimiza cache misses falsos que pode acontecer na ausência de exclusão mútua. Avaliámos extensivamente o FLeeC sob vários cenários e descobrimos que, quando comparado com o Memcached, o FLeeC é capaz de ter 6× mais desempenho em cenários de alta contenção, 1.2× mais desempenho em cenários de baixa contenção e desempenho equivalente na ausência de contenção. O FLeeC pode então ser utilizado para melhorar o desempenho de qualquer aplicação que atualmente utilize o Memcached.Lourenço, JoãoPreguiça, NunoRUNCosta, André João César2024-04-05T09:15:06Z2023-112023-11-01T00:00:00Zinfo:eu-repo/semantics/publishedVersioninfo:eu-repo/semantics/masterThesisapplication/pdfhttp://hdl.handle.net/10362/165841enginfo:eu-repo/semantics/openAccessreponame:Repositórios Científicos de Acesso Aberto de Portugal (RCAAP)instname:FCCN, serviços digitais da FCT – Fundação para a Ciência e a Tecnologiainstacron:RCAAP2024-05-22T18:20:13Zoai:run.unl.pt:10362/165841Portal AgregadorONGhttps://www.rcaap.pt/oai/openaireinfo@rcaap.ptopendoar:https://opendoar.ac.uk/repository/71602025-05-28T17:50:57.374692Repositórios Científicos de Acesso Aberto de Portugal (RCAAP) - FCCN, serviços digitais da FCT – Fundação para a Ciência e a Tecnologiafalse
dc.title.none.fl_str_mv FLeeC: a Fast and Lock-Free Applicational Cache
title FLeeC: a Fast and Lock-Free Applicational Cache
spellingShingle FLeeC: a Fast and Lock-Free Applicational Cache
Costa, André João César
Caching
Concurrency
Non-Blocking
Lock-Free
Domínio/Área Científica::Engenharia e Tecnologia::Engenharia Eletrotécnica, Eletrónica e Informática
title_short FLeeC: a Fast and Lock-Free Applicational Cache
title_full FLeeC: a Fast and Lock-Free Applicational Cache
title_fullStr FLeeC: a Fast and Lock-Free Applicational Cache
title_full_unstemmed FLeeC: a Fast and Lock-Free Applicational Cache
title_sort FLeeC: a Fast and Lock-Free Applicational Cache
author Costa, André João César
author_facet Costa, André João César
author_role author
dc.contributor.none.fl_str_mv Lourenço, João
Preguiça, Nuno
RUN
dc.contributor.author.fl_str_mv Costa, André João César
dc.subject.por.fl_str_mv Caching
Concurrency
Non-Blocking
Lock-Free
Domínio/Área Científica::Engenharia e Tecnologia::Engenharia Eletrotécnica, Eletrónica e Informática
topic Caching
Concurrency
Non-Blocking
Lock-Free
Domínio/Área Científica::Engenharia e Tecnologia::Engenharia Eletrotécnica, Eletrónica e Informática
description Access to data in applications that make use of external storage systems (e.g., Databases) can be a major performance bottleneck. A common solution is to first query a cache application to reduce data access overhead. These cache applications leverage fast main memory access rates and the parallelism capabilities of hardware to provide high performance. To this end, a cache application needs a concurrency control mechanism to maintain correctness under conflicting concurrent accesses, of which mutual-exclusion locks (blocking concurrency control) are the most common mechanism used. Blocking concurrency control strategies fail to provide a high level of performance when under medium to high contention, as the pessimistic nature of blocking concurrency can not completely avoid needlessly synchronizing operations that do not conflict. Conversely, non-blocking (or lock-free) concurrency control strategies can provide high degrees of performance in parallel shared memory contexts, especially in high contention scenarios. This work proposes FLeeC, an application-level cache system based on Memcached, which leverages non-blocking re-designed data structures concurrency to improve performance by allowing any number of concurrent writes and reads to its main data structure. FLeeC features a hash table with embedded eviction policy to allowthe correct functioning of its non-blocking algorithms; a memory reclamation scheme adapted to cache semantics; a non-blocking hash table expansion mechanism to preserve the strong progress guarantees that non-blocking concurrency provides; and dedicated replacement algorithm to minimize false misses that can occur in non-mutually exclusive environments. We have extensively evaluated FLeeC under varied scenarios and workloads and found that, when compared to Memcached, it is capable of achieving 6× higher performance when under high contention scenarios, 1.2× higher performance when under low contention scenarios and equivalent performance in scenarios with no contention. FLeeC can thus be used to further improve the performance of any application that currently uses Memcached
publishDate 2023
dc.date.none.fl_str_mv 2023-11
2023-11-01T00:00:00Z
2024-04-05T09:15:06Z
dc.type.status.fl_str_mv info:eu-repo/semantics/publishedVersion
dc.type.driver.fl_str_mv info:eu-repo/semantics/masterThesis
format masterThesis
status_str publishedVersion
dc.identifier.uri.fl_str_mv http://hdl.handle.net/10362/165841
url http://hdl.handle.net/10362/165841
dc.language.iso.fl_str_mv eng
language eng
dc.rights.driver.fl_str_mv info:eu-repo/semantics/openAccess
eu_rights_str_mv openAccess
dc.format.none.fl_str_mv application/pdf
dc.source.none.fl_str_mv reponame:Repositórios Científicos de Acesso Aberto de Portugal (RCAAP)
instname:FCCN, serviços digitais da FCT – Fundação para a Ciência e a Tecnologia
instacron:RCAAP
instname_str FCCN, serviços digitais da FCT – Fundação para a Ciência e a Tecnologia
instacron_str RCAAP
institution RCAAP
reponame_str Repositórios Científicos de Acesso Aberto de Portugal (RCAAP)
collection Repositórios Científicos de Acesso Aberto de Portugal (RCAAP)
repository.name.fl_str_mv Repositórios Científicos de Acesso Aberto de Portugal (RCAAP) - FCCN, serviços digitais da FCT – Fundação para a Ciência e a Tecnologia
repository.mail.fl_str_mv info@rcaap.pt
_version_ 1833597009162928128