SlideShare a Scribd company logo
www.luxoft.com
APPLICATION PERFORMANCE:
DATABASE-RELATED PROBLEMS
Evgeniy Khyst
12.12.2015
www.luxoft.com
Application Performance: Database-related Problems
● Application performance;
● Common performance problems and their solutions;
● Database-related problems;
● Lock contention;
● Locking mechanism;
● Transaction isolation level;
● URL shortener example;
● Hi/Lo algorithms;
● Payment system example.
www.luxoft.com
Application Performance
● Key performance metrics:
- Request processing time;
- Throughput;
● Poor performance:
- Long time to process single requests;
- Low number of requests processed per second.
www.luxoft.com
Request Processing Time
Request processing time = 4 seconds
www.luxoft.com
Throughput
Throughput = 3 requests per second
www.luxoft.com
Throughput
Throughput = 1 request per second
www.luxoft.com
Throughput
Throughput = 10 requests per second
www.luxoft.com
Common Performance Problems and Their Solutions
● Database-related problems;
● JVM performance problems;
● Application specific performance problems;
● Network-related problems.
www.luxoft.com
Database-related Performance Problems
● Query execution time is too big;
● Too much queries per single business function;
● Database connection management problems.
www.luxoft.com
Query Execution Time is Too Big
● Missing indexes;
● Slow SQL queries (sub-queries, too many JOINs etc);
● Slow SQL queries generated by ORM;
● Not optimal JDBC fetch size;
● Lack of proper data caching;
● Lock contention.
www.luxoft.com
Missing Indexes
To find out what indexes to create look at query execution plan:
EXPLAIN PLAN FOR
SELECT isbn FROM book;
SELECT * FROM TABLE(DBMS_XPLAN.DISPLAY());
www.luxoft.com
TABLE ACCESS FULL
● Full table scan is a scan made on a database where each row of
the table under scan is read in a sequential order and the
columns encountered are checked for the validity of a condition;
● Full table scans are the slowest method of scanning a table in
most of the cases;
● Create missing indexes to search by index instead of
performing full table scan.
www.luxoft.com
Slow SQL Queries
● Slow SQL queries (sub-queries, too many JOINs etc):
Solution: Rewrite query
● Slow SQL queries generated by ORM:
- JPQL/HQL and Criteria API queries are translated to SQL;
Solutions:
- Rewrite JPQL/HQL, Criteria API queries;
- Replace with plain SQL query.
www.luxoft.com
Not Optimal JDBC Fetch Size
JDBC allows to specify the number of rows fetched with each
database round-trip for a query, and this number is referred to as
the fetch size.
Solutions:
● java.sql.Statement.setFetchSize(rows)
● hibernate.jdbc.fetch_size property
www.luxoft.com
Lack of Proper Data Caching
Solutions:
● Enable ORM second-level cache;
● Enable ORM query cache;
● Implement custom cache.
www.luxoft.com
Lock Contention
Operations are waiting to obtain lock for a long time due to high
lock contention.
Solution:
Revise application logic and implementation:
● Update asynchronously;
● Replace updates with inserts (inserts are not blocking).
www.luxoft.com
Too Much Queries per Single Business Function
● Insert/update queries executed in a loop;
● "SELECT N+1" problem;
● Reduce number calls hitting database.
www.luxoft.com
Insert/Update Queries Executed in a Loop
● Use JDBC batch (keep batch size less than 1000);
● hibernate.jdbc.batch_size property;
● Periodically flush changes and clear Session/EntityManager
to control first-level cache size.
www.luxoft.com
JDBC Batch Processing
PreparedStatement preparedStatement = connection.prepareStatement("UPDATE book SET title=? WHERE isbn=?");
preparedStatement.setString(1, "Patterns of Enterprise Application Architecture");
preparedStatement.setString(2, "007-6092019909");
preparedStatement.addBatch();
preparedStatement.setString(1, "Enterprise Integration Patterns");
preparedStatement.setString(2, "978-0321200686");
preparedStatement.addBatch();
int[] affectedRecords = preparedStatement.executeBatch();
for (int i=0; i<100000; i++) {
Book book = new Book(.....);
session.save(book);
if ( i % 20 == 0 ) { // 20, same as the JDBC batch size
// flush a batch of inserts and release memory:
session.flush();
session.clear();
}
}
www.luxoft.com
"SELECT N+1" Problem
● The first query will selected root entities only, and each
associated collection will be selected with additional query.
● So persistence provider generates N+1 SQL queries, where N is a
number of root entities in result list of user query.
www.luxoft.com
"SELECT N+1" Problem
Solutions:
● Use different fetching strategy or entity graph;
● Make child entities aggregate roots and use DAO methods to
fetch them:
- Replace bidirectional one-to-many mapping with unidirectional;
● Enable second-level and query cache.
www.luxoft.com
Reduce Number Database Calls
Solutions:
● Use Hi/Lo algorithms;
● Enable ORM second-level cache;
● Enable ORM query cache;
● Implement custom cache.
www.luxoft.com
Database Connection Management Problems
● Application is using too much DB connections:
- Application is not closing connections after using
Solution: Close all connections after using
- DB is not able to handle that much connections application uses
Solution: Use connection pooling
● Application is waiting to get connection from pool too long
Solution: Increase pool size
www.luxoft.com
JVM Performance Problems
Excessive JVM garbage collections slows down application.
Solutions:
● Analyze garbage collector logs:
- Send GC data to a log file, enable GC log rotation:
-Xloggc:gc.log -XX:+UseGCLogFileRotation
-XX:NumberOfGCLogFiles=5 -XX:GCLogFileSize=1M
-XX:+PrintGCTimeStamps
● Tune GC:
- Use Garbage-First Collector: -XX:+UseG1GC
www.luxoft.com
Application Specific Performance Problems
Resource consuming computations:
● Algorithms with complexity O(N2), O(2N);
● Asymmetric RSA encryption;
● Bcrypt hashing during authentication;
● Etc.
Solution: Horizontal scalability. Increase number of instances
capable of processing requests and balance load (create cluster).
www.luxoft.com
Network-related Problems
● Network latency;
● Not configured timeout:
- mail.smtp.connectiontimeout Socket connection timeout. Default
is infinite timeout.
- mail.smtp.timeout Socket read timeout. Default is infinite timeout.
www.luxoft.com
Reducing Lock Contention
● Database-related problems
- Query execution time is too big
• Lock contention
Solutions:
● Use Hi/Lo algorithms;
● Update asynchronously;
● Replace updates with inserts.
www.luxoft.com
Locking Mechanism
Locks are mechanisms that prevent destructive interaction
between transactions accessing the same resource.
In general, multi-user databases use some form of data locking to
solve the problems associated with:
● data concurrency,
● consistency,
● integrity.
www.luxoft.com
Isolation Levels vs Locks
● Transaction isolation level does not affect the locks that are
acquired to protect data modifications.
● A transaction always gets an exclusive lock on any data it
modifies and holds that lock until the transaction completes,
regardless of the isolation level set for that transaction.
● For read operations transaction isolation levels primarily define
the level of protection from the effects of modifications made
by other transactions.
www.luxoft.com
Preventable Read Phenomena
● Dirty reads - A transaction reads data that has been written by
another transaction that has not been committed yet.
● Nonrepeatable reads - A transaction rereads data it has
previously read and finds that another committed transaction
has modified or deleted the data.
● Phantom reads - A transaction reruns a query returning a set
of rows that satisfies a search condition and finds that another
committed transaction has inserted additional rows that satisfy
the condition.
www.luxoft.com
Standard Transaction Isolation Levels
● Read uncommited
● Read commited
● Repeatable reads
● Serializable
www.luxoft.com
Isolation Levels vs Read Phenomena
Dirty reads Nonrepeatable reads Phantom reads
Read uncommited Possible Possible Possible
Read commited Not possible Possible Possible
Repeatable reads Not possible Not possible Possible
Serializable Not possible Not possible Not possible
www.luxoft.com
Default Isolation Level
Read commited isolation level is default.
www.luxoft.com
Read Commited Isolation Level
In read commited reads are not blocking.
www.luxoft.com
Read Commited Isolation Level
Conflicting writes in read commited transactions.
www.luxoft.com
URL Shortener Example
Requirements:
● Receives URL and returns "shortened" version;
● E.g. post "http://github.com" to "http://url-shortener/s/" and get
back "http://url-shortener/s/2Bi";
● The shortened URL can be resolved to original URL. E.g.
"http://url-shortener/s/2Bi" will return "http://github.com";
● Shortened URLs that were not accessed longer than some
specified amount of time should be deleted.
www.luxoft.com
URL Shortener Example
● Each time URL is submitted a new record is inserted into the
database;
● Insert operations do not introduce locks in database;
● For primary key generation database sequence is used;
● The Hi/Lo algorithm allows to reduce number of database hits
to improve performance.
www.luxoft.com
URL Shortener Example
● Original URL’s primary key is converted to radix 62:
- Radix 62 alphabet contains digits lower- and upper-case letters: 10000
in radix 10 = 2Bi in radix 62;
● String identifying original URL is converted back to radix 10 to
get primary key value and original URL can be found by ID.
www.luxoft.com
URL Shortener Example
E.g. URL "http://github.com/" shortened to "http://url-
shortener/s/2Bi":
● Inserting new record to database with id 10000 for original URL
"http://github.com/" representing "shortened" URL
● Converting id 10000 to radix 62: 2Bi
www.luxoft.com
URL Shortener Example
● During each shortened URL resolving last view timestamp is
updated in database and total number of views column is
incremented;
● These update should be asynchronous to not reduce
performance due to lock contention;
● Absence of update operations gives application better
scalability and throughput.
www.luxoft.com
Update Asynchronously
● When URL is resolved JMS message is sent to queue;
● Application consumes messages from queue and updates
records in database;
● During URL resolving there are no update operations.
www.luxoft.com
Hi/Lo Algorithms
The usage of Hi/Lo algorithm allows different application nodes not
to block each other.
www.luxoft.com
Hi/Lo Algorithms
● JPA mapping:
@SequenceGenerator(name = "MY_SEQ", sequenceName = "MY_SEQ",
allocationSize = 50)
allocationSize = N - fetch the next value from the database once in every
N persist calls and locally (in-memory) increment the value in between.
● Sequence DDL:
CREATE SEQUENCE MY_SEQ INCREMENT BY 50 START WITH 50;
INCREMENT BY should match allocationSize
START WITH should be greater or equal to allocationSize
www.luxoft.com
Payment System Example
Requirements:
● Users can add funds on their accounts (add funds)
● Users can pay to shops with funds from their accounts
(payment)
● Users and shops can withdraw money from their accounts
(withdraw funds)
● Account balance must be always up to date
www.luxoft.com
Simple solution 1
● Store account balance in table and update on each operation.
● Advantage:
- Simple
www.luxoft.com
Simple solution 1 - Data model
Table ACCOUNT_BALANCE
ACCOUNT_ID BALANCE
www.luxoft.com
Simple solution 1 - Queries
UPDATE ACCOUNT_BALANCE SET
BALANCE = BALANCE + :amount
WHERE ACCOUNT_ID = :account
SELECT ACCOUNT_ID,
BALANCE
FROM ACCOUNT_BALANCE
WHERE ACCOUNT_ID = :account
www.luxoft.com
Simple solution 1 - Problems
● Update operations introduce locks;
● During Christmas holidays users can make hundreds of
payments simultaneously;
● Due to lock contention payments will be slow;
● System have low throughput.
www.luxoft.com
Simple solution 2
● Do not store account balance at all;
● Store details of each transaction;
● Calculate balance dynamically based on transaction log;
● Advantages:
- Still simple enough;
- No update operations at all.
www.luxoft.com
Simple solution 2 - Data model
Table TRANSACTION_LOG
TX_ID TX_TYPE TX_DATE ACCOUNT_ID TX_AMOUNT
www.luxoft.com
Simple solution 2 - Queries
INSERT INTO TRANSACTION_LOG(TX_ID, TX_TYPE, TX_DATE,
ACCOUNT_ID, TX_AMOUNT)
VALUES(:id, :type, :date, :account, :amount)
SELECT ACCOUNT_ID,
SUM(TX_AMOUNT) AS BALANCE
FROM TRANSACTION_LOG
WHERE ACCOUNT_ID = :account
www.luxoft.com
Simple solution 2 - Problems
● Users can make thousands of transactions per day;
● During Christmas holidays users can make thousands of
payments per hour;
● Number of transactions continuously grow;
● More records in TRANSACTION_LOG table - slower requests.
www.luxoft.com
Better solution
● Store balance on yesterday in table;
● Update account balance once a day in background;
● Store details of each transaction;
● Calculate balance dynamically based on value of balance on
yesterday and transactions made today from transaction log.
www.luxoft.com
Better solution - Data model
Table ACCOUNT_BALANCE
Table TRANSACTION_LOG
ACCOUNT_ID BALANCE_DATE BALANCE
TX_ID TX_TYPE TX_DATE ACCOUNT_ID TX_AMOUNT
www.luxoft.com
Better solution - Queries
INSERT INTO TRANSACTION_LOG(TX_ID, TX_TYPE, TX_DATE,
ACCOUNT_ID, TX_AMOUNT)
VALUES(:id, :type, :date, :account, :amount)
-- Executed once a day at midnight
UPDATE ACCOUNT_BALANCE SET
BALANCE = BALANCE + :transactionLogSum,
BALANCE_DATE = :lastTransactionLogDate
WHERE ACCOUNT_ID = :account
www.luxoft.com
Better solution - Queries
SELECT ACCOUNT_ID,
BALANCE_DATE,
BALANCE AS CACHED_BALANCE
FROM ACCOUNT_BALANCE
WHERE ACCOUNT_ID = :account
SELECT ACCOUNT_ID,
MAX(TX_DATE) AS LAST_TX_LOG_DATE,
SUM(TX_AMOUNT) AS TX_LOG_SUM
FROM TRANSACTION_LOG
WHERE ACCOUNT_ID = :account
AND TX_DATE > :balanceDate
-- BALANCE = CACHED_BALANCE + TX_LOG_SUM
www.luxoft.com
Better solution - Advantages
● No updates during payment operations - no locks
● No locks - better throughput
● Number of rows in query with SUM operation is limited (1 day)
● Constant query execution time
www.luxoft.com
THANK YOU

More Related Content

What's hot

Geo2tag performance evaluation, Zaslavsky, Krinkin
Geo2tag performance evaluation, Zaslavsky, Krinkin Geo2tag performance evaluation, Zaslavsky, Krinkin
Geo2tag performance evaluation, Zaslavsky, Krinkin OSLL
 
Grokking Techtalk #37: Data intensive problem
 Grokking Techtalk #37: Data intensive problem Grokking Techtalk #37: Data intensive problem
Grokking Techtalk #37: Data intensive problem
Grokking VN
 
Proxysql use case scenarios plam 2016
Proxysql use case scenarios    plam 2016Proxysql use case scenarios    plam 2016
Proxysql use case scenarios plam 2016
Alkin Tezuysal
 
Open Policy Agent for governance as a code
Open Policy Agent for governance as a code Open Policy Agent for governance as a code
Open Policy Agent for governance as a code
Alexander Tokarev
 
Comparing high availability solutions with percona xtradb cluster and percona...
Comparing high availability solutions with percona xtradb cluster and percona...Comparing high availability solutions with percona xtradb cluster and percona...
Comparing high availability solutions with percona xtradb cluster and percona...
Marco Tusa
 
12-Step Program for Scaling Web Applications on PostgreSQL
12-Step Program for Scaling Web Applications on PostgreSQL12-Step Program for Scaling Web Applications on PostgreSQL
12-Step Program for Scaling Web Applications on PostgreSQL
Konstantin Gredeskoul
 
IOUG Collaborate 2015 - PDB Cloning Using SQL Commands
IOUG Collaborate 2015 - PDB Cloning Using SQL CommandsIOUG Collaborate 2015 - PDB Cloning Using SQL Commands
IOUG Collaborate 2015 - PDB Cloning Using SQL Commands
Leighton Nelson
 
Oracle Database 12c - Features for Big Data
Oracle Database 12c - Features for Big DataOracle Database 12c - Features for Big Data
Oracle Database 12c - Features for Big Data
Abishek V S
 
Postgres Vision 2018: WAL: Everything You Want to Know
Postgres Vision 2018: WAL: Everything You Want to KnowPostgres Vision 2018: WAL: Everything You Want to Know
Postgres Vision 2018: WAL: Everything You Want to Know
EDB
 
Oracle 12c Parallel Execution New Features
Oracle 12c Parallel Execution New FeaturesOracle 12c Parallel Execution New Features
Oracle 12c Parallel Execution New Features
Randolf Geist
 
Webinar Slides: Tungsten Connector / Proxy – The Secret Sauce Behind Zero-Dow...
Webinar Slides: Tungsten Connector / Proxy – The Secret Sauce Behind Zero-Dow...Webinar Slides: Tungsten Connector / Proxy – The Secret Sauce Behind Zero-Dow...
Webinar Slides: Tungsten Connector / Proxy – The Secret Sauce Behind Zero-Dow...
Continuent
 
Modern Distributed Messaging and RPC
Modern Distributed Messaging and RPCModern Distributed Messaging and RPC
Modern Distributed Messaging and RPC
Max Alexejev
 
PostgreSQL Enterprise Class Features and Capabilities
PostgreSQL Enterprise Class Features and CapabilitiesPostgreSQL Enterprise Class Features and Capabilities
PostgreSQL Enterprise Class Features and Capabilities
PGConf APAC
 
Ten query tuning techniques every SQL Server programmer should know
Ten query tuning techniques every SQL Server programmer should knowTen query tuning techniques every SQL Server programmer should know
Ten query tuning techniques every SQL Server programmer should know
Kevin Kline
 
Presto Testing Tools: Benchto & Tempto (Presto Boston Meetup 10062015)
Presto Testing Tools: Benchto & Tempto (Presto Boston Meetup 10062015)Presto Testing Tools: Benchto & Tempto (Presto Boston Meetup 10062015)
Presto Testing Tools: Benchto & Tempto (Presto Boston Meetup 10062015)
Matt Fuller
 
Grokking TechTalk 9 - Building a realtime & offline editing service from scra...
Grokking TechTalk 9 - Building a realtime & offline editing service from scra...Grokking TechTalk 9 - Building a realtime & offline editing service from scra...
Grokking TechTalk 9 - Building a realtime & offline editing service from scra...
Grokking VN
 
App Grid Dev With Coherence
App Grid Dev With CoherenceApp Grid Dev With Coherence
App Grid Dev With CoherenceJames Bayer
 
Apache con2016final
Apache con2016final Apache con2016final
Apache con2016final
Salesforce
 
ProxySQL - High Performance and HA Proxy for MySQL
ProxySQL - High Performance and HA Proxy for MySQLProxySQL - High Performance and HA Proxy for MySQL
ProxySQL - High Performance and HA Proxy for MySQL
René Cannaò
 
Introduction to Prometheus Monitoring (Singapore Meetup)
Introduction to Prometheus Monitoring (Singapore Meetup) Introduction to Prometheus Monitoring (Singapore Meetup)
Introduction to Prometheus Monitoring (Singapore Meetup)
Arseny Chernov
 

What's hot (20)

Geo2tag performance evaluation, Zaslavsky, Krinkin
Geo2tag performance evaluation, Zaslavsky, Krinkin Geo2tag performance evaluation, Zaslavsky, Krinkin
Geo2tag performance evaluation, Zaslavsky, Krinkin
 
Grokking Techtalk #37: Data intensive problem
 Grokking Techtalk #37: Data intensive problem Grokking Techtalk #37: Data intensive problem
Grokking Techtalk #37: Data intensive problem
 
Proxysql use case scenarios plam 2016
Proxysql use case scenarios    plam 2016Proxysql use case scenarios    plam 2016
Proxysql use case scenarios plam 2016
 
Open Policy Agent for governance as a code
Open Policy Agent for governance as a code Open Policy Agent for governance as a code
Open Policy Agent for governance as a code
 
Comparing high availability solutions with percona xtradb cluster and percona...
Comparing high availability solutions with percona xtradb cluster and percona...Comparing high availability solutions with percona xtradb cluster and percona...
Comparing high availability solutions with percona xtradb cluster and percona...
 
12-Step Program for Scaling Web Applications on PostgreSQL
12-Step Program for Scaling Web Applications on PostgreSQL12-Step Program for Scaling Web Applications on PostgreSQL
12-Step Program for Scaling Web Applications on PostgreSQL
 
IOUG Collaborate 2015 - PDB Cloning Using SQL Commands
IOUG Collaborate 2015 - PDB Cloning Using SQL CommandsIOUG Collaborate 2015 - PDB Cloning Using SQL Commands
IOUG Collaborate 2015 - PDB Cloning Using SQL Commands
 
Oracle Database 12c - Features for Big Data
Oracle Database 12c - Features for Big DataOracle Database 12c - Features for Big Data
Oracle Database 12c - Features for Big Data
 
Postgres Vision 2018: WAL: Everything You Want to Know
Postgres Vision 2018: WAL: Everything You Want to KnowPostgres Vision 2018: WAL: Everything You Want to Know
Postgres Vision 2018: WAL: Everything You Want to Know
 
Oracle 12c Parallel Execution New Features
Oracle 12c Parallel Execution New FeaturesOracle 12c Parallel Execution New Features
Oracle 12c Parallel Execution New Features
 
Webinar Slides: Tungsten Connector / Proxy – The Secret Sauce Behind Zero-Dow...
Webinar Slides: Tungsten Connector / Proxy – The Secret Sauce Behind Zero-Dow...Webinar Slides: Tungsten Connector / Proxy – The Secret Sauce Behind Zero-Dow...
Webinar Slides: Tungsten Connector / Proxy – The Secret Sauce Behind Zero-Dow...
 
Modern Distributed Messaging and RPC
Modern Distributed Messaging and RPCModern Distributed Messaging and RPC
Modern Distributed Messaging and RPC
 
PostgreSQL Enterprise Class Features and Capabilities
PostgreSQL Enterprise Class Features and CapabilitiesPostgreSQL Enterprise Class Features and Capabilities
PostgreSQL Enterprise Class Features and Capabilities
 
Ten query tuning techniques every SQL Server programmer should know
Ten query tuning techniques every SQL Server programmer should knowTen query tuning techniques every SQL Server programmer should know
Ten query tuning techniques every SQL Server programmer should know
 
Presto Testing Tools: Benchto & Tempto (Presto Boston Meetup 10062015)
Presto Testing Tools: Benchto & Tempto (Presto Boston Meetup 10062015)Presto Testing Tools: Benchto & Tempto (Presto Boston Meetup 10062015)
Presto Testing Tools: Benchto & Tempto (Presto Boston Meetup 10062015)
 
Grokking TechTalk 9 - Building a realtime & offline editing service from scra...
Grokking TechTalk 9 - Building a realtime & offline editing service from scra...Grokking TechTalk 9 - Building a realtime & offline editing service from scra...
Grokking TechTalk 9 - Building a realtime & offline editing service from scra...
 
App Grid Dev With Coherence
App Grid Dev With CoherenceApp Grid Dev With Coherence
App Grid Dev With Coherence
 
Apache con2016final
Apache con2016final Apache con2016final
Apache con2016final
 
ProxySQL - High Performance and HA Proxy for MySQL
ProxySQL - High Performance and HA Proxy for MySQLProxySQL - High Performance and HA Proxy for MySQL
ProxySQL - High Performance and HA Proxy for MySQL
 
Introduction to Prometheus Monitoring (Singapore Meetup)
Introduction to Prometheus Monitoring (Singapore Meetup) Introduction to Prometheus Monitoring (Singapore Meetup)
Introduction to Prometheus Monitoring (Singapore Meetup)
 

Viewers also liked

Administando melhor o tempo
Administando melhor o tempoAdministando melhor o tempo
Administando melhor o tempo
Associação Viva e Deixe Viver
 
GauravGoelResume
GauravGoelResumeGauravGoelResume
GauravGoelResumeGaurav Goel
 
ใบงาน (2)
ใบงาน (2)ใบงาน (2)
ใบงาน (2)
Tanawat Rengtian
 
Presentazione es4
Presentazione es4Presentazione es4
Presentazione es4
LUCIABARO
 
Invitation au voyage
Invitation au voyageInvitation au voyage
Invitation au voyageNadVDS
 
Aforizma demaku
Aforizma demakuAforizma demaku
Aforizma demaku
JURIST
 
Métodos Naturais de Contracepção
Métodos Naturais de ContracepçãoMétodos Naturais de Contracepção
Métodos Naturais de Contracepção
Adhonias Moura
 
Case Procountor: Zephyr test tool deployment
Case Procountor: Zephyr test tool deploymentCase Procountor: Zephyr test tool deployment
Case Procountor: Zephyr test tool deployment
Ambientia
 
Sergii Tsypanov: "Tricky enterprise"
Sergii Tsypanov: "Tricky enterprise"Sergii Tsypanov: "Tricky enterprise"
Sergii Tsypanov: "Tricky enterprise"
LogeekNightUkraine
 
Past Simple: Negative and Interrogative
Past Simple: Negative and InterrogativePast Simple: Negative and Interrogative
Past Simple: Negative and Interrogative
guerina3
 
Константин Маркович: "Creating modular application using Spring Boot "
Константин Маркович: "Creating modular application using Spring Boot "Константин Маркович: "Creating modular application using Spring Boot "
Константин Маркович: "Creating modular application using Spring Boot "
Anna Shymchenko
 
Недопетая песня поэта-фронтовика Бориса Котова
Недопетая песня  поэта-фронтовика  Бориса Котова Недопетая песня  поэта-фронтовика  Бориса Котова
Недопетая песня поэта-фронтовика Бориса Котова
Донецкая республиканская библиотека для детей
 
Владимир Григорьевич Калиниченко
 Владимир  Григорьевич Калиниченко Владимир  Григорьевич Калиниченко
Владимир Григорьевич Калиниченко
Донецкая республиканская библиотека для детей
 
Евгений Бова: "Modularity in Java: introduction to Jigsaw through the prism o...
Евгений Бова: "Modularity in Java: introduction to Jigsaw through the prism o...Евгений Бова: "Modularity in Java: introduction to Jigsaw through the prism o...
Евгений Бова: "Modularity in Java: introduction to Jigsaw through the prism o...
Anna Shymchenko
 
Spy Cheating Playing Cards in Bangalore
Spy Cheating Playing Cards in  BangaloreSpy Cheating Playing Cards in  Bangalore
Spy Cheating Playing Cards in Bangalore
spycardsindia
 

Viewers also liked (16)

Administando melhor o tempo
Administando melhor o tempoAdministando melhor o tempo
Administando melhor o tempo
 
GauravGoelResume
GauravGoelResumeGauravGoelResume
GauravGoelResume
 
ใบงาน (2)
ใบงาน (2)ใบงาน (2)
ใบงาน (2)
 
DHOWELL BC-8pt
DHOWELL BC-8ptDHOWELL BC-8pt
DHOWELL BC-8pt
 
Presentazione es4
Presentazione es4Presentazione es4
Presentazione es4
 
Invitation au voyage
Invitation au voyageInvitation au voyage
Invitation au voyage
 
Aforizma demaku
Aforizma demakuAforizma demaku
Aforizma demaku
 
Métodos Naturais de Contracepção
Métodos Naturais de ContracepçãoMétodos Naturais de Contracepção
Métodos Naturais de Contracepção
 
Case Procountor: Zephyr test tool deployment
Case Procountor: Zephyr test tool deploymentCase Procountor: Zephyr test tool deployment
Case Procountor: Zephyr test tool deployment
 
Sergii Tsypanov: "Tricky enterprise"
Sergii Tsypanov: "Tricky enterprise"Sergii Tsypanov: "Tricky enterprise"
Sergii Tsypanov: "Tricky enterprise"
 
Past Simple: Negative and Interrogative
Past Simple: Negative and InterrogativePast Simple: Negative and Interrogative
Past Simple: Negative and Interrogative
 
Константин Маркович: "Creating modular application using Spring Boot "
Константин Маркович: "Creating modular application using Spring Boot "Константин Маркович: "Creating modular application using Spring Boot "
Константин Маркович: "Creating modular application using Spring Boot "
 
Недопетая песня поэта-фронтовика Бориса Котова
Недопетая песня  поэта-фронтовика  Бориса Котова Недопетая песня  поэта-фронтовика  Бориса Котова
Недопетая песня поэта-фронтовика Бориса Котова
 
Владимир Григорьевич Калиниченко
 Владимир  Григорьевич Калиниченко Владимир  Григорьевич Калиниченко
Владимир Григорьевич Калиниченко
 
Евгений Бова: "Modularity in Java: introduction to Jigsaw through the prism o...
Евгений Бова: "Modularity in Java: introduction to Jigsaw through the prism o...Евгений Бова: "Modularity in Java: introduction to Jigsaw through the prism o...
Евгений Бова: "Modularity in Java: introduction to Jigsaw through the prism o...
 
Spy Cheating Playing Cards in Bangalore
Spy Cheating Playing Cards in  BangaloreSpy Cheating Playing Cards in  Bangalore
Spy Cheating Playing Cards in Bangalore
 

Similar to Евгений Хыст "Application performance database related problems"

Zero Downtime JEE Architectures
Zero Downtime JEE ArchitecturesZero Downtime JEE Architectures
Zero Downtime JEE Architectures
Alexander Penev
 
(ATS6-PLAT06) Maximizing AEP Performance
(ATS6-PLAT06) Maximizing AEP Performance(ATS6-PLAT06) Maximizing AEP Performance
(ATS6-PLAT06) Maximizing AEP Performance
BIOVIA
 
Open source: Top issues in the top enterprise packages
Open source: Top issues in the top enterprise packagesOpen source: Top issues in the top enterprise packages
Open source: Top issues in the top enterprise packages
Rogue Wave Software
 
Fastest Servlets in the West
Fastest Servlets in the WestFastest Servlets in the West
Fastest Servlets in the West
Stuart (Pid) Williams
 
Advanced web application architecture - Talk
Advanced web application architecture - TalkAdvanced web application architecture - Talk
Advanced web application architecture - Talk
Matthias Noback
 
Web Component Development Using Servlet & JSP Technologies (EE6) - Chapter 1...
 Web Component Development Using Servlet & JSP Technologies (EE6) - Chapter 1... Web Component Development Using Servlet & JSP Technologies (EE6) - Chapter 1...
Web Component Development Using Servlet & JSP Technologies (EE6) - Chapter 1...
WebStackAcademy
 
Training Webinar: Detect Performance Bottlenecks of Applications
Training Webinar: Detect Performance Bottlenecks of ApplicationsTraining Webinar: Detect Performance Bottlenecks of Applications
Training Webinar: Detect Performance Bottlenecks of Applications
OutSystems
 
(ATS4-PLAT08) Server Pool Management
(ATS4-PLAT08) Server Pool Management(ATS4-PLAT08) Server Pool Management
(ATS4-PLAT08) Server Pool Management
BIOVIA
 
Web performance optimization - MercadoLibre
Web performance optimization - MercadoLibreWeb performance optimization - MercadoLibre
Web performance optimization - MercadoLibre
Pablo Moretti
 
Web performance mercadolibre - ECI 2013
Web performance   mercadolibre - ECI 2013Web performance   mercadolibre - ECI 2013
Web performance mercadolibre - ECI 2013
Santiago Aimetta
 
MySQL X protocol - Talking to MySQL Directly over the Wire
MySQL X protocol - Talking to MySQL Directly over the WireMySQL X protocol - Talking to MySQL Directly over the Wire
MySQL X protocol - Talking to MySQL Directly over the Wire
Simon J Mudd
 
Realtime traffic analyser
Realtime traffic analyserRealtime traffic analyser
Realtime traffic analyser
Alex Moskvin
 
Migrate from Oracle to Aurora PostgreSQL: Best Practices, Design Patterns, & ...
Migrate from Oracle to Aurora PostgreSQL: Best Practices, Design Patterns, & ...Migrate from Oracle to Aurora PostgreSQL: Best Practices, Design Patterns, & ...
Migrate from Oracle to Aurora PostgreSQL: Best Practices, Design Patterns, & ...
Amazon Web Services
 
Load testing in Zonky with Gatling
Load testing in Zonky with GatlingLoad testing in Zonky with Gatling
Load testing in Zonky with Gatling
Petr Vlček
 
Slow things down to make them go faster [FOSDEM 2022]
Slow things down to make them go faster [FOSDEM 2022]Slow things down to make them go faster [FOSDEM 2022]
Slow things down to make them go faster [FOSDEM 2022]
Jimmy Angelakos
 
hbaseconasia2019 Test-suite for Automating Data-consistency checks on HBase
hbaseconasia2019 Test-suite for Automating Data-consistency checks on HBasehbaseconasia2019 Test-suite for Automating Data-consistency checks on HBase
hbaseconasia2019 Test-suite for Automating Data-consistency checks on HBase
Michael Stack
 
Performance tuning Grails applications SpringOne 2GX 2014
Performance tuning Grails applications SpringOne 2GX 2014Performance tuning Grails applications SpringOne 2GX 2014
Performance tuning Grails applications SpringOne 2GX 2014
Lari Hotari
 
PHP At 5000 Requests Per Second: Hootsuite’s Scaling Story
PHP At 5000 Requests Per Second: Hootsuite’s Scaling StoryPHP At 5000 Requests Per Second: Hootsuite’s Scaling Story
PHP At 5000 Requests Per Second: Hootsuite’s Scaling Story
vanphp
 
Buytaert kris my_sql-pacemaker
Buytaert kris my_sql-pacemakerBuytaert kris my_sql-pacemaker
Buytaert kris my_sql-pacemakerkuchinskaya
 
Life In The FastLane: Full Speed XPages
Life In The FastLane: Full Speed XPagesLife In The FastLane: Full Speed XPages
Life In The FastLane: Full Speed XPages
Ulrich Krause
 

Similar to Евгений Хыст "Application performance database related problems" (20)

Zero Downtime JEE Architectures
Zero Downtime JEE ArchitecturesZero Downtime JEE Architectures
Zero Downtime JEE Architectures
 
(ATS6-PLAT06) Maximizing AEP Performance
(ATS6-PLAT06) Maximizing AEP Performance(ATS6-PLAT06) Maximizing AEP Performance
(ATS6-PLAT06) Maximizing AEP Performance
 
Open source: Top issues in the top enterprise packages
Open source: Top issues in the top enterprise packagesOpen source: Top issues in the top enterprise packages
Open source: Top issues in the top enterprise packages
 
Fastest Servlets in the West
Fastest Servlets in the WestFastest Servlets in the West
Fastest Servlets in the West
 
Advanced web application architecture - Talk
Advanced web application architecture - TalkAdvanced web application architecture - Talk
Advanced web application architecture - Talk
 
Web Component Development Using Servlet & JSP Technologies (EE6) - Chapter 1...
 Web Component Development Using Servlet & JSP Technologies (EE6) - Chapter 1... Web Component Development Using Servlet & JSP Technologies (EE6) - Chapter 1...
Web Component Development Using Servlet & JSP Technologies (EE6) - Chapter 1...
 
Training Webinar: Detect Performance Bottlenecks of Applications
Training Webinar: Detect Performance Bottlenecks of ApplicationsTraining Webinar: Detect Performance Bottlenecks of Applications
Training Webinar: Detect Performance Bottlenecks of Applications
 
(ATS4-PLAT08) Server Pool Management
(ATS4-PLAT08) Server Pool Management(ATS4-PLAT08) Server Pool Management
(ATS4-PLAT08) Server Pool Management
 
Web performance optimization - MercadoLibre
Web performance optimization - MercadoLibreWeb performance optimization - MercadoLibre
Web performance optimization - MercadoLibre
 
Web performance mercadolibre - ECI 2013
Web performance   mercadolibre - ECI 2013Web performance   mercadolibre - ECI 2013
Web performance mercadolibre - ECI 2013
 
MySQL X protocol - Talking to MySQL Directly over the Wire
MySQL X protocol - Talking to MySQL Directly over the WireMySQL X protocol - Talking to MySQL Directly over the Wire
MySQL X protocol - Talking to MySQL Directly over the Wire
 
Realtime traffic analyser
Realtime traffic analyserRealtime traffic analyser
Realtime traffic analyser
 
Migrate from Oracle to Aurora PostgreSQL: Best Practices, Design Patterns, & ...
Migrate from Oracle to Aurora PostgreSQL: Best Practices, Design Patterns, & ...Migrate from Oracle to Aurora PostgreSQL: Best Practices, Design Patterns, & ...
Migrate from Oracle to Aurora PostgreSQL: Best Practices, Design Patterns, & ...
 
Load testing in Zonky with Gatling
Load testing in Zonky with GatlingLoad testing in Zonky with Gatling
Load testing in Zonky with Gatling
 
Slow things down to make them go faster [FOSDEM 2022]
Slow things down to make them go faster [FOSDEM 2022]Slow things down to make them go faster [FOSDEM 2022]
Slow things down to make them go faster [FOSDEM 2022]
 
hbaseconasia2019 Test-suite for Automating Data-consistency checks on HBase
hbaseconasia2019 Test-suite for Automating Data-consistency checks on HBasehbaseconasia2019 Test-suite for Automating Data-consistency checks on HBase
hbaseconasia2019 Test-suite for Automating Data-consistency checks on HBase
 
Performance tuning Grails applications SpringOne 2GX 2014
Performance tuning Grails applications SpringOne 2GX 2014Performance tuning Grails applications SpringOne 2GX 2014
Performance tuning Grails applications SpringOne 2GX 2014
 
PHP At 5000 Requests Per Second: Hootsuite’s Scaling Story
PHP At 5000 Requests Per Second: Hootsuite’s Scaling StoryPHP At 5000 Requests Per Second: Hootsuite’s Scaling Story
PHP At 5000 Requests Per Second: Hootsuite’s Scaling Story
 
Buytaert kris my_sql-pacemaker
Buytaert kris my_sql-pacemakerBuytaert kris my_sql-pacemaker
Buytaert kris my_sql-pacemaker
 
Life In The FastLane: Full Speed XPages
Life In The FastLane: Full Speed XPagesLife In The FastLane: Full Speed XPages
Life In The FastLane: Full Speed XPages
 

More from Anna Shymchenko

Евгений Руднев: "Programmers Approach to Error Handling"
Евгений Руднев: "Programmers Approach to Error Handling"Евгений Руднев: "Programmers Approach to Error Handling"
Евгений Руднев: "Programmers Approach to Error Handling"
Anna Shymchenko
 
Александр Куцан: "Static Code Analysis in C++"
Александр Куцан: "Static Code Analysis in C++" Александр Куцан: "Static Code Analysis in C++"
Александр Куцан: "Static Code Analysis in C++"
Anna Shymchenko
 
Алесей Решта: “Robotics Sport & Luxoft Open Robotics Club”
Алесей Решта: “Robotics Sport & Luxoft Open Robotics Club” Алесей Решта: “Robotics Sport & Luxoft Open Robotics Club”
Алесей Решта: “Robotics Sport & Luxoft Open Robotics Club”
Anna Shymchenko
 
Орхан Гасимов: "Reactive Applications in Java with Akka"
Орхан Гасимов: "Reactive Applications in Java with Akka"Орхан Гасимов: "Reactive Applications in Java with Akka"
Орхан Гасимов: "Reactive Applications in Java with Akka"
Anna Shymchenko
 
Евгений Хыст: "Server-Side Geo-Clustering Based on Geohash"
Евгений Хыст: "Server-Side Geo-Clustering Based on Geohash"Евгений Хыст: "Server-Side Geo-Clustering Based on Geohash"
Евгений Хыст: "Server-Side Geo-Clustering Based on Geohash"
Anna Shymchenko
 
Денис Прокопюк: “JMX in Java EE applications”
Денис Прокопюк: “JMX in Java EE applications”Денис Прокопюк: “JMX in Java EE applications”
Денис Прокопюк: “JMX in Java EE applications”
Anna Shymchenko
 
Роман Яворский "Introduction to DevOps"
Роман Яворский "Introduction to DevOps"Роман Яворский "Introduction to DevOps"
Роман Яворский "Introduction to DevOps"
Anna Shymchenko
 
Максим Сабарня “NoSQL: Not only SQL in developer’s life”
Максим Сабарня “NoSQL: Not only SQL in developer’s life” Максим Сабарня “NoSQL: Not only SQL in developer’s life”
Максим Сабарня “NoSQL: Not only SQL in developer’s life”
Anna Shymchenko
 
Андрей Лисниченко "SQL Injection"
Андрей Лисниченко "SQL Injection"Андрей Лисниченко "SQL Injection"
Андрей Лисниченко "SQL Injection"
Anna Shymchenko
 
Светлана Мухина "Metrics on agile projects"
Светлана Мухина "Metrics on agile projects"Светлана Мухина "Metrics on agile projects"
Светлана Мухина "Metrics on agile projects"
Anna Shymchenko
 
Андрей Слободяник "Test driven development using mockito"
Андрей Слободяник "Test driven development using mockito"Андрей Слободяник "Test driven development using mockito"
Андрей Слободяник "Test driven development using mockito"
Anna Shymchenko
 
Даурен Муса “IBM WebSphere - expensive but effective”
Даурен Муса “IBM WebSphere - expensive but effective” Даурен Муса “IBM WebSphere - expensive but effective”
Даурен Муса “IBM WebSphere - expensive but effective”
Anna Shymchenko
 
Александр Пашинский "Reinventing Design Patterns with Java 8"
Александр Пашинский "Reinventing Design Patterns with Java 8"Александр Пашинский "Reinventing Design Patterns with Java 8"
Александр Пашинский "Reinventing Design Patterns with Java 8"
Anna Shymchenko
 
Евгений Капинос "Advanced JPA (Java Persistent API)"
Евгений Капинос "Advanced JPA (Java Persistent API)"Евгений Капинос "Advanced JPA (Java Persistent API)"
Евгений Капинос "Advanced JPA (Java Persistent API)"
Anna Shymchenko
 
Event-driven architecture with Java technology stack
Event-driven architecture with Java technology stackEvent-driven architecture with Java technology stack
Event-driven architecture with Java technology stack
Anna Shymchenko
 
Do we need SOLID principles during software development?
Do we need SOLID principles during software development?Do we need SOLID principles during software development?
Do we need SOLID principles during software development?
Anna Shymchenko
 
Guava - Elements of Functional Programming
Guava - Elements of Functional Programming Guava - Elements of Functional Programming
Guava - Elements of Functional Programming
Anna Shymchenko
 
Максим Сабарня и Иван Дрижирук “Vert.x – tool-kit for building reactive app...
 	Максим Сабарня и Иван Дрижирук “Vert.x – tool-kit for building reactive app... 	Максим Сабарня и Иван Дрижирук “Vert.x – tool-kit for building reactive app...
Максим Сабарня и Иван Дрижирук “Vert.x – tool-kit for building reactive app...
Anna Shymchenko
 
Сергей Гончарук "Working with uncertainty"
 	Сергей Гончарук "Working with uncertainty"  	Сергей Гончарук "Working with uncertainty"
Сергей Гончарук "Working with uncertainty"
Anna Shymchenko
 
Александр Денисюк "How not to lose the dynamic of project in process time"
 	Александр Денисюк "How not to lose the dynamic of project in process time"  	Александр Денисюк "How not to lose the dynamic of project in process time"
Александр Денисюк "How not to lose the dynamic of project in process time"
Anna Shymchenko
 

More from Anna Shymchenko (20)

Евгений Руднев: "Programmers Approach to Error Handling"
Евгений Руднев: "Programmers Approach to Error Handling"Евгений Руднев: "Programmers Approach to Error Handling"
Евгений Руднев: "Programmers Approach to Error Handling"
 
Александр Куцан: "Static Code Analysis in C++"
Александр Куцан: "Static Code Analysis in C++" Александр Куцан: "Static Code Analysis in C++"
Александр Куцан: "Static Code Analysis in C++"
 
Алесей Решта: “Robotics Sport & Luxoft Open Robotics Club”
Алесей Решта: “Robotics Sport & Luxoft Open Robotics Club” Алесей Решта: “Robotics Sport & Luxoft Open Robotics Club”
Алесей Решта: “Robotics Sport & Luxoft Open Robotics Club”
 
Орхан Гасимов: "Reactive Applications in Java with Akka"
Орхан Гасимов: "Reactive Applications in Java with Akka"Орхан Гасимов: "Reactive Applications in Java with Akka"
Орхан Гасимов: "Reactive Applications in Java with Akka"
 
Евгений Хыст: "Server-Side Geo-Clustering Based on Geohash"
Евгений Хыст: "Server-Side Geo-Clustering Based on Geohash"Евгений Хыст: "Server-Side Geo-Clustering Based on Geohash"
Евгений Хыст: "Server-Side Geo-Clustering Based on Geohash"
 
Денис Прокопюк: “JMX in Java EE applications”
Денис Прокопюк: “JMX in Java EE applications”Денис Прокопюк: “JMX in Java EE applications”
Денис Прокопюк: “JMX in Java EE applications”
 
Роман Яворский "Introduction to DevOps"
Роман Яворский "Introduction to DevOps"Роман Яворский "Introduction to DevOps"
Роман Яворский "Introduction to DevOps"
 
Максим Сабарня “NoSQL: Not only SQL in developer’s life”
Максим Сабарня “NoSQL: Not only SQL in developer’s life” Максим Сабарня “NoSQL: Not only SQL in developer’s life”
Максим Сабарня “NoSQL: Not only SQL in developer’s life”
 
Андрей Лисниченко "SQL Injection"
Андрей Лисниченко "SQL Injection"Андрей Лисниченко "SQL Injection"
Андрей Лисниченко "SQL Injection"
 
Светлана Мухина "Metrics on agile projects"
Светлана Мухина "Metrics on agile projects"Светлана Мухина "Metrics on agile projects"
Светлана Мухина "Metrics on agile projects"
 
Андрей Слободяник "Test driven development using mockito"
Андрей Слободяник "Test driven development using mockito"Андрей Слободяник "Test driven development using mockito"
Андрей Слободяник "Test driven development using mockito"
 
Даурен Муса “IBM WebSphere - expensive but effective”
Даурен Муса “IBM WebSphere - expensive but effective” Даурен Муса “IBM WebSphere - expensive but effective”
Даурен Муса “IBM WebSphere - expensive but effective”
 
Александр Пашинский "Reinventing Design Patterns with Java 8"
Александр Пашинский "Reinventing Design Patterns with Java 8"Александр Пашинский "Reinventing Design Patterns with Java 8"
Александр Пашинский "Reinventing Design Patterns with Java 8"
 
Евгений Капинос "Advanced JPA (Java Persistent API)"
Евгений Капинос "Advanced JPA (Java Persistent API)"Евгений Капинос "Advanced JPA (Java Persistent API)"
Евгений Капинос "Advanced JPA (Java Persistent API)"
 
Event-driven architecture with Java technology stack
Event-driven architecture with Java technology stackEvent-driven architecture with Java technology stack
Event-driven architecture with Java technology stack
 
Do we need SOLID principles during software development?
Do we need SOLID principles during software development?Do we need SOLID principles during software development?
Do we need SOLID principles during software development?
 
Guava - Elements of Functional Programming
Guava - Elements of Functional Programming Guava - Elements of Functional Programming
Guava - Elements of Functional Programming
 
Максим Сабарня и Иван Дрижирук “Vert.x – tool-kit for building reactive app...
 	Максим Сабарня и Иван Дрижирук “Vert.x – tool-kit for building reactive app... 	Максим Сабарня и Иван Дрижирук “Vert.x – tool-kit for building reactive app...
Максим Сабарня и Иван Дрижирук “Vert.x – tool-kit for building reactive app...
 
Сергей Гончарук "Working with uncertainty"
 	Сергей Гончарук "Working with uncertainty"  	Сергей Гончарук "Working with uncertainty"
Сергей Гончарук "Working with uncertainty"
 
Александр Денисюк "How not to lose the dynamic of project in process time"
 	Александр Денисюк "How not to lose the dynamic of project in process time"  	Александр Денисюк "How not to lose the dynamic of project in process time"
Александр Денисюк "How not to lose the dynamic of project in process time"
 

Recently uploaded

GraphSummit Paris - The art of the possible with Graph Technology
GraphSummit Paris - The art of the possible with Graph TechnologyGraphSummit Paris - The art of the possible with Graph Technology
GraphSummit Paris - The art of the possible with Graph Technology
Neo4j
 
AI Fusion Buddy Review: Brand New, Groundbreaking Gemini-Powered AI App
AI Fusion Buddy Review: Brand New, Groundbreaking Gemini-Powered AI AppAI Fusion Buddy Review: Brand New, Groundbreaking Gemini-Powered AI App
AI Fusion Buddy Review: Brand New, Groundbreaking Gemini-Powered AI App
Google
 
Enhancing Research Orchestration Capabilities at ORNL.pdf
Enhancing Research Orchestration Capabilities at ORNL.pdfEnhancing Research Orchestration Capabilities at ORNL.pdf
Enhancing Research Orchestration Capabilities at ORNL.pdf
Globus
 
How Recreation Management Software Can Streamline Your Operations.pptx
How Recreation Management Software Can Streamline Your Operations.pptxHow Recreation Management Software Can Streamline Your Operations.pptx
How Recreation Management Software Can Streamline Your Operations.pptx
wottaspaceseo
 
Dominate Social Media with TubeTrivia AI’s Addictive Quiz Videos.pdf
Dominate Social Media with TubeTrivia AI’s Addictive Quiz Videos.pdfDominate Social Media with TubeTrivia AI’s Addictive Quiz Videos.pdf
Dominate Social Media with TubeTrivia AI’s Addictive Quiz Videos.pdf
AMB-Review
 
OpenMetadata Community Meeting - 5th June 2024
OpenMetadata Community Meeting - 5th June 2024OpenMetadata Community Meeting - 5th June 2024
OpenMetadata Community Meeting - 5th June 2024
OpenMetadata
 
openEuler Case Study - The Journey to Supply Chain Security
openEuler Case Study - The Journey to Supply Chain SecurityopenEuler Case Study - The Journey to Supply Chain Security
openEuler Case Study - The Journey to Supply Chain Security
Shane Coughlan
 
Orion Context Broker introduction 20240604
Orion Context Broker introduction 20240604Orion Context Broker introduction 20240604
Orion Context Broker introduction 20240604
Fermin Galan
 
Cracking the code review at SpringIO 2024
Cracking the code review at SpringIO 2024Cracking the code review at SpringIO 2024
Cracking the code review at SpringIO 2024
Paco van Beckhoven
 
Understanding Globus Data Transfers with NetSage
Understanding Globus Data Transfers with NetSageUnderstanding Globus Data Transfers with NetSage
Understanding Globus Data Transfers with NetSage
Globus
 
Lecture 1 Introduction to games development
Lecture 1 Introduction to games developmentLecture 1 Introduction to games development
Lecture 1 Introduction to games development
abdulrafaychaudhry
 
Globus Compute wth IRI Workflows - GlobusWorld 2024
Globus Compute wth IRI Workflows - GlobusWorld 2024Globus Compute wth IRI Workflows - GlobusWorld 2024
Globus Compute wth IRI Workflows - GlobusWorld 2024
Globus
 
How to Position Your Globus Data Portal for Success Ten Good Practices
How to Position Your Globus Data Portal for Success Ten Good PracticesHow to Position Your Globus Data Portal for Success Ten Good Practices
How to Position Your Globus Data Portal for Success Ten Good Practices
Globus
 
Text-Summarization-of-Breaking-News-Using-Fine-tuning-BART-Model.pptx
Text-Summarization-of-Breaking-News-Using-Fine-tuning-BART-Model.pptxText-Summarization-of-Breaking-News-Using-Fine-tuning-BART-Model.pptx
Text-Summarization-of-Breaking-News-Using-Fine-tuning-BART-Model.pptx
ShamsuddeenMuhammadA
 
May Marketo Masterclass, London MUG May 22 2024.pdf
May Marketo Masterclass, London MUG May 22 2024.pdfMay Marketo Masterclass, London MUG May 22 2024.pdf
May Marketo Masterclass, London MUG May 22 2024.pdf
Adele Miller
 
Pro Unity Game Development with C-sharp Book
Pro Unity Game Development with C-sharp BookPro Unity Game Development with C-sharp Book
Pro Unity Game Development with C-sharp Book
abdulrafaychaudhry
 
Developing Distributed High-performance Computing Capabilities of an Open Sci...
Developing Distributed High-performance Computing Capabilities of an Open Sci...Developing Distributed High-performance Computing Capabilities of an Open Sci...
Developing Distributed High-performance Computing Capabilities of an Open Sci...
Globus
 
A Study of Variable-Role-based Feature Enrichment in Neural Models of Code
A Study of Variable-Role-based Feature Enrichment in Neural Models of CodeA Study of Variable-Role-based Feature Enrichment in Neural Models of Code
A Study of Variable-Role-based Feature Enrichment in Neural Models of Code
Aftab Hussain
 
Top 7 Unique WhatsApp API Benefits | Saudi Arabia
Top 7 Unique WhatsApp API Benefits | Saudi ArabiaTop 7 Unique WhatsApp API Benefits | Saudi Arabia
Top 7 Unique WhatsApp API Benefits | Saudi Arabia
Yara Milbes
 
Graspan: A Big Data System for Big Code Analysis
Graspan: A Big Data System for Big Code AnalysisGraspan: A Big Data System for Big Code Analysis
Graspan: A Big Data System for Big Code Analysis
Aftab Hussain
 

Recently uploaded (20)

GraphSummit Paris - The art of the possible with Graph Technology
GraphSummit Paris - The art of the possible with Graph TechnologyGraphSummit Paris - The art of the possible with Graph Technology
GraphSummit Paris - The art of the possible with Graph Technology
 
AI Fusion Buddy Review: Brand New, Groundbreaking Gemini-Powered AI App
AI Fusion Buddy Review: Brand New, Groundbreaking Gemini-Powered AI AppAI Fusion Buddy Review: Brand New, Groundbreaking Gemini-Powered AI App
AI Fusion Buddy Review: Brand New, Groundbreaking Gemini-Powered AI App
 
Enhancing Research Orchestration Capabilities at ORNL.pdf
Enhancing Research Orchestration Capabilities at ORNL.pdfEnhancing Research Orchestration Capabilities at ORNL.pdf
Enhancing Research Orchestration Capabilities at ORNL.pdf
 
How Recreation Management Software Can Streamline Your Operations.pptx
How Recreation Management Software Can Streamline Your Operations.pptxHow Recreation Management Software Can Streamline Your Operations.pptx
How Recreation Management Software Can Streamline Your Operations.pptx
 
Dominate Social Media with TubeTrivia AI’s Addictive Quiz Videos.pdf
Dominate Social Media with TubeTrivia AI’s Addictive Quiz Videos.pdfDominate Social Media with TubeTrivia AI’s Addictive Quiz Videos.pdf
Dominate Social Media with TubeTrivia AI’s Addictive Quiz Videos.pdf
 
OpenMetadata Community Meeting - 5th June 2024
OpenMetadata Community Meeting - 5th June 2024OpenMetadata Community Meeting - 5th June 2024
OpenMetadata Community Meeting - 5th June 2024
 
openEuler Case Study - The Journey to Supply Chain Security
openEuler Case Study - The Journey to Supply Chain SecurityopenEuler Case Study - The Journey to Supply Chain Security
openEuler Case Study - The Journey to Supply Chain Security
 
Orion Context Broker introduction 20240604
Orion Context Broker introduction 20240604Orion Context Broker introduction 20240604
Orion Context Broker introduction 20240604
 
Cracking the code review at SpringIO 2024
Cracking the code review at SpringIO 2024Cracking the code review at SpringIO 2024
Cracking the code review at SpringIO 2024
 
Understanding Globus Data Transfers with NetSage
Understanding Globus Data Transfers with NetSageUnderstanding Globus Data Transfers with NetSage
Understanding Globus Data Transfers with NetSage
 
Lecture 1 Introduction to games development
Lecture 1 Introduction to games developmentLecture 1 Introduction to games development
Lecture 1 Introduction to games development
 
Globus Compute wth IRI Workflows - GlobusWorld 2024
Globus Compute wth IRI Workflows - GlobusWorld 2024Globus Compute wth IRI Workflows - GlobusWorld 2024
Globus Compute wth IRI Workflows - GlobusWorld 2024
 
How to Position Your Globus Data Portal for Success Ten Good Practices
How to Position Your Globus Data Portal for Success Ten Good PracticesHow to Position Your Globus Data Portal for Success Ten Good Practices
How to Position Your Globus Data Portal for Success Ten Good Practices
 
Text-Summarization-of-Breaking-News-Using-Fine-tuning-BART-Model.pptx
Text-Summarization-of-Breaking-News-Using-Fine-tuning-BART-Model.pptxText-Summarization-of-Breaking-News-Using-Fine-tuning-BART-Model.pptx
Text-Summarization-of-Breaking-News-Using-Fine-tuning-BART-Model.pptx
 
May Marketo Masterclass, London MUG May 22 2024.pdf
May Marketo Masterclass, London MUG May 22 2024.pdfMay Marketo Masterclass, London MUG May 22 2024.pdf
May Marketo Masterclass, London MUG May 22 2024.pdf
 
Pro Unity Game Development with C-sharp Book
Pro Unity Game Development with C-sharp BookPro Unity Game Development with C-sharp Book
Pro Unity Game Development with C-sharp Book
 
Developing Distributed High-performance Computing Capabilities of an Open Sci...
Developing Distributed High-performance Computing Capabilities of an Open Sci...Developing Distributed High-performance Computing Capabilities of an Open Sci...
Developing Distributed High-performance Computing Capabilities of an Open Sci...
 
A Study of Variable-Role-based Feature Enrichment in Neural Models of Code
A Study of Variable-Role-based Feature Enrichment in Neural Models of CodeA Study of Variable-Role-based Feature Enrichment in Neural Models of Code
A Study of Variable-Role-based Feature Enrichment in Neural Models of Code
 
Top 7 Unique WhatsApp API Benefits | Saudi Arabia
Top 7 Unique WhatsApp API Benefits | Saudi ArabiaTop 7 Unique WhatsApp API Benefits | Saudi Arabia
Top 7 Unique WhatsApp API Benefits | Saudi Arabia
 
Graspan: A Big Data System for Big Code Analysis
Graspan: A Big Data System for Big Code AnalysisGraspan: A Big Data System for Big Code Analysis
Graspan: A Big Data System for Big Code Analysis
 

Евгений Хыст "Application performance database related problems"

  • 2. www.luxoft.com Application Performance: Database-related Problems ● Application performance; ● Common performance problems and their solutions; ● Database-related problems; ● Lock contention; ● Locking mechanism; ● Transaction isolation level; ● URL shortener example; ● Hi/Lo algorithms; ● Payment system example.
  • 3. www.luxoft.com Application Performance ● Key performance metrics: - Request processing time; - Throughput; ● Poor performance: - Long time to process single requests; - Low number of requests processed per second.
  • 8. www.luxoft.com Common Performance Problems and Their Solutions ● Database-related problems; ● JVM performance problems; ● Application specific performance problems; ● Network-related problems.
  • 9. www.luxoft.com Database-related Performance Problems ● Query execution time is too big; ● Too much queries per single business function; ● Database connection management problems.
  • 10. www.luxoft.com Query Execution Time is Too Big ● Missing indexes; ● Slow SQL queries (sub-queries, too many JOINs etc); ● Slow SQL queries generated by ORM; ● Not optimal JDBC fetch size; ● Lack of proper data caching; ● Lock contention.
  • 11. www.luxoft.com Missing Indexes To find out what indexes to create look at query execution plan: EXPLAIN PLAN FOR SELECT isbn FROM book; SELECT * FROM TABLE(DBMS_XPLAN.DISPLAY());
  • 12. www.luxoft.com TABLE ACCESS FULL ● Full table scan is a scan made on a database where each row of the table under scan is read in a sequential order and the columns encountered are checked for the validity of a condition; ● Full table scans are the slowest method of scanning a table in most of the cases; ● Create missing indexes to search by index instead of performing full table scan.
  • 13. www.luxoft.com Slow SQL Queries ● Slow SQL queries (sub-queries, too many JOINs etc): Solution: Rewrite query ● Slow SQL queries generated by ORM: - JPQL/HQL and Criteria API queries are translated to SQL; Solutions: - Rewrite JPQL/HQL, Criteria API queries; - Replace with plain SQL query.
  • 14. www.luxoft.com Not Optimal JDBC Fetch Size JDBC allows to specify the number of rows fetched with each database round-trip for a query, and this number is referred to as the fetch size. Solutions: ● java.sql.Statement.setFetchSize(rows) ● hibernate.jdbc.fetch_size property
  • 15. www.luxoft.com Lack of Proper Data Caching Solutions: ● Enable ORM second-level cache; ● Enable ORM query cache; ● Implement custom cache.
  • 16. www.luxoft.com Lock Contention Operations are waiting to obtain lock for a long time due to high lock contention. Solution: Revise application logic and implementation: ● Update asynchronously; ● Replace updates with inserts (inserts are not blocking).
  • 17. www.luxoft.com Too Much Queries per Single Business Function ● Insert/update queries executed in a loop; ● "SELECT N+1" problem; ● Reduce number calls hitting database.
  • 18. www.luxoft.com Insert/Update Queries Executed in a Loop ● Use JDBC batch (keep batch size less than 1000); ● hibernate.jdbc.batch_size property; ● Periodically flush changes and clear Session/EntityManager to control first-level cache size.
  • 19. www.luxoft.com JDBC Batch Processing PreparedStatement preparedStatement = connection.prepareStatement("UPDATE book SET title=? WHERE isbn=?"); preparedStatement.setString(1, "Patterns of Enterprise Application Architecture"); preparedStatement.setString(2, "007-6092019909"); preparedStatement.addBatch(); preparedStatement.setString(1, "Enterprise Integration Patterns"); preparedStatement.setString(2, "978-0321200686"); preparedStatement.addBatch(); int[] affectedRecords = preparedStatement.executeBatch(); for (int i=0; i<100000; i++) { Book book = new Book(.....); session.save(book); if ( i % 20 == 0 ) { // 20, same as the JDBC batch size // flush a batch of inserts and release memory: session.flush(); session.clear(); } }
  • 20. www.luxoft.com "SELECT N+1" Problem ● The first query will selected root entities only, and each associated collection will be selected with additional query. ● So persistence provider generates N+1 SQL queries, where N is a number of root entities in result list of user query.
  • 21. www.luxoft.com "SELECT N+1" Problem Solutions: ● Use different fetching strategy or entity graph; ● Make child entities aggregate roots and use DAO methods to fetch them: - Replace bidirectional one-to-many mapping with unidirectional; ● Enable second-level and query cache.
  • 22. www.luxoft.com Reduce Number Database Calls Solutions: ● Use Hi/Lo algorithms; ● Enable ORM second-level cache; ● Enable ORM query cache; ● Implement custom cache.
  • 23. www.luxoft.com Database Connection Management Problems ● Application is using too much DB connections: - Application is not closing connections after using Solution: Close all connections after using - DB is not able to handle that much connections application uses Solution: Use connection pooling ● Application is waiting to get connection from pool too long Solution: Increase pool size
  • 24. www.luxoft.com JVM Performance Problems Excessive JVM garbage collections slows down application. Solutions: ● Analyze garbage collector logs: - Send GC data to a log file, enable GC log rotation: -Xloggc:gc.log -XX:+UseGCLogFileRotation -XX:NumberOfGCLogFiles=5 -XX:GCLogFileSize=1M -XX:+PrintGCTimeStamps ● Tune GC: - Use Garbage-First Collector: -XX:+UseG1GC
  • 25. www.luxoft.com Application Specific Performance Problems Resource consuming computations: ● Algorithms with complexity O(N2), O(2N); ● Asymmetric RSA encryption; ● Bcrypt hashing during authentication; ● Etc. Solution: Horizontal scalability. Increase number of instances capable of processing requests and balance load (create cluster).
  • 26. www.luxoft.com Network-related Problems ● Network latency; ● Not configured timeout: - mail.smtp.connectiontimeout Socket connection timeout. Default is infinite timeout. - mail.smtp.timeout Socket read timeout. Default is infinite timeout.
  • 27. www.luxoft.com Reducing Lock Contention ● Database-related problems - Query execution time is too big • Lock contention Solutions: ● Use Hi/Lo algorithms; ● Update asynchronously; ● Replace updates with inserts.
  • 28. www.luxoft.com Locking Mechanism Locks are mechanisms that prevent destructive interaction between transactions accessing the same resource. In general, multi-user databases use some form of data locking to solve the problems associated with: ● data concurrency, ● consistency, ● integrity.
  • 29. www.luxoft.com Isolation Levels vs Locks ● Transaction isolation level does not affect the locks that are acquired to protect data modifications. ● A transaction always gets an exclusive lock on any data it modifies and holds that lock until the transaction completes, regardless of the isolation level set for that transaction. ● For read operations transaction isolation levels primarily define the level of protection from the effects of modifications made by other transactions.
  • 30. www.luxoft.com Preventable Read Phenomena ● Dirty reads - A transaction reads data that has been written by another transaction that has not been committed yet. ● Nonrepeatable reads - A transaction rereads data it has previously read and finds that another committed transaction has modified or deleted the data. ● Phantom reads - A transaction reruns a query returning a set of rows that satisfies a search condition and finds that another committed transaction has inserted additional rows that satisfy the condition.
  • 31. www.luxoft.com Standard Transaction Isolation Levels ● Read uncommited ● Read commited ● Repeatable reads ● Serializable
  • 32. www.luxoft.com Isolation Levels vs Read Phenomena Dirty reads Nonrepeatable reads Phantom reads Read uncommited Possible Possible Possible Read commited Not possible Possible Possible Repeatable reads Not possible Not possible Possible Serializable Not possible Not possible Not possible
  • 33. www.luxoft.com Default Isolation Level Read commited isolation level is default.
  • 34. www.luxoft.com Read Commited Isolation Level In read commited reads are not blocking.
  • 35. www.luxoft.com Read Commited Isolation Level Conflicting writes in read commited transactions.
  • 36. www.luxoft.com URL Shortener Example Requirements: ● Receives URL and returns "shortened" version; ● E.g. post "http://github.com" to "http://url-shortener/s/" and get back "http://url-shortener/s/2Bi"; ● The shortened URL can be resolved to original URL. E.g. "http://url-shortener/s/2Bi" will return "http://github.com"; ● Shortened URLs that were not accessed longer than some specified amount of time should be deleted.
  • 37. www.luxoft.com URL Shortener Example ● Each time URL is submitted a new record is inserted into the database; ● Insert operations do not introduce locks in database; ● For primary key generation database sequence is used; ● The Hi/Lo algorithm allows to reduce number of database hits to improve performance.
  • 38. www.luxoft.com URL Shortener Example ● Original URL’s primary key is converted to radix 62: - Radix 62 alphabet contains digits lower- and upper-case letters: 10000 in radix 10 = 2Bi in radix 62; ● String identifying original URL is converted back to radix 10 to get primary key value and original URL can be found by ID.
  • 39. www.luxoft.com URL Shortener Example E.g. URL "http://github.com/" shortened to "http://url- shortener/s/2Bi": ● Inserting new record to database with id 10000 for original URL "http://github.com/" representing "shortened" URL ● Converting id 10000 to radix 62: 2Bi
  • 40. www.luxoft.com URL Shortener Example ● During each shortened URL resolving last view timestamp is updated in database and total number of views column is incremented; ● These update should be asynchronous to not reduce performance due to lock contention; ● Absence of update operations gives application better scalability and throughput.
  • 41. www.luxoft.com Update Asynchronously ● When URL is resolved JMS message is sent to queue; ● Application consumes messages from queue and updates records in database; ● During URL resolving there are no update operations.
  • 42. www.luxoft.com Hi/Lo Algorithms The usage of Hi/Lo algorithm allows different application nodes not to block each other.
  • 43. www.luxoft.com Hi/Lo Algorithms ● JPA mapping: @SequenceGenerator(name = "MY_SEQ", sequenceName = "MY_SEQ", allocationSize = 50) allocationSize = N - fetch the next value from the database once in every N persist calls and locally (in-memory) increment the value in between. ● Sequence DDL: CREATE SEQUENCE MY_SEQ INCREMENT BY 50 START WITH 50; INCREMENT BY should match allocationSize START WITH should be greater or equal to allocationSize
  • 44. www.luxoft.com Payment System Example Requirements: ● Users can add funds on their accounts (add funds) ● Users can pay to shops with funds from their accounts (payment) ● Users and shops can withdraw money from their accounts (withdraw funds) ● Account balance must be always up to date
  • 45. www.luxoft.com Simple solution 1 ● Store account balance in table and update on each operation. ● Advantage: - Simple
  • 46. www.luxoft.com Simple solution 1 - Data model Table ACCOUNT_BALANCE ACCOUNT_ID BALANCE
  • 47. www.luxoft.com Simple solution 1 - Queries UPDATE ACCOUNT_BALANCE SET BALANCE = BALANCE + :amount WHERE ACCOUNT_ID = :account SELECT ACCOUNT_ID, BALANCE FROM ACCOUNT_BALANCE WHERE ACCOUNT_ID = :account
  • 48. www.luxoft.com Simple solution 1 - Problems ● Update operations introduce locks; ● During Christmas holidays users can make hundreds of payments simultaneously; ● Due to lock contention payments will be slow; ● System have low throughput.
  • 49. www.luxoft.com Simple solution 2 ● Do not store account balance at all; ● Store details of each transaction; ● Calculate balance dynamically based on transaction log; ● Advantages: - Still simple enough; - No update operations at all.
  • 50. www.luxoft.com Simple solution 2 - Data model Table TRANSACTION_LOG TX_ID TX_TYPE TX_DATE ACCOUNT_ID TX_AMOUNT
  • 51. www.luxoft.com Simple solution 2 - Queries INSERT INTO TRANSACTION_LOG(TX_ID, TX_TYPE, TX_DATE, ACCOUNT_ID, TX_AMOUNT) VALUES(:id, :type, :date, :account, :amount) SELECT ACCOUNT_ID, SUM(TX_AMOUNT) AS BALANCE FROM TRANSACTION_LOG WHERE ACCOUNT_ID = :account
  • 52. www.luxoft.com Simple solution 2 - Problems ● Users can make thousands of transactions per day; ● During Christmas holidays users can make thousands of payments per hour; ● Number of transactions continuously grow; ● More records in TRANSACTION_LOG table - slower requests.
  • 53. www.luxoft.com Better solution ● Store balance on yesterday in table; ● Update account balance once a day in background; ● Store details of each transaction; ● Calculate balance dynamically based on value of balance on yesterday and transactions made today from transaction log.
  • 54. www.luxoft.com Better solution - Data model Table ACCOUNT_BALANCE Table TRANSACTION_LOG ACCOUNT_ID BALANCE_DATE BALANCE TX_ID TX_TYPE TX_DATE ACCOUNT_ID TX_AMOUNT
  • 55. www.luxoft.com Better solution - Queries INSERT INTO TRANSACTION_LOG(TX_ID, TX_TYPE, TX_DATE, ACCOUNT_ID, TX_AMOUNT) VALUES(:id, :type, :date, :account, :amount) -- Executed once a day at midnight UPDATE ACCOUNT_BALANCE SET BALANCE = BALANCE + :transactionLogSum, BALANCE_DATE = :lastTransactionLogDate WHERE ACCOUNT_ID = :account
  • 56. www.luxoft.com Better solution - Queries SELECT ACCOUNT_ID, BALANCE_DATE, BALANCE AS CACHED_BALANCE FROM ACCOUNT_BALANCE WHERE ACCOUNT_ID = :account SELECT ACCOUNT_ID, MAX(TX_DATE) AS LAST_TX_LOG_DATE, SUM(TX_AMOUNT) AS TX_LOG_SUM FROM TRANSACTION_LOG WHERE ACCOUNT_ID = :account AND TX_DATE > :balanceDate -- BALANCE = CACHED_BALANCE + TX_LOG_SUM
  • 57. www.luxoft.com Better solution - Advantages ● No updates during payment operations - no locks ● No locks - better throughput ● Number of rows in query with SUM operation is limited (1 day) ● Constant query execution time