Adapting Database Best Practices to memcached Applications-opracowanie

Nasza ocena:

3
Wyświetleń: 280
Komentarze: 0
Notatek.pl

Pobierz ten dokument za darmo

Podgląd dokumentu
Adapting Database Best Practices to memcached Applications-opracowanie - strona 1

Fragment notatki:

Adapting Database Best Practices to memcached Applications
The most direct way to cache MySQL data is to use a 2-column table, where the first column is a
primary key. Because of the uniqueness requirements for memcached keys, make sure your database
schema makes appropriate use of primary keys and unique constraints.
If you combine multiple column values into a single memcached item value, choose data types to
make it easy to parse the value back into its components, for example by using a separator character
between numeric values.
The queries that map most easily to memcached lookups are those with a single WHERE clause, using
an = or IN operator. For complicated WHERE clauses, or those using operators such as , BETWEEN,
or LIKE, memcached does not provide a simple or efficient way to scan through or filter the keys
or associated values, so typically you perform those operations as SQL queries on the underlying
database.
... zobacz całą notatkę



Komentarze użytkowników (0)

Zaloguj się, aby dodać komentarz