Misurazione performance. Processing time. Performance. Throughput. Francesco Marchioni Mastertheboss.com Javaday IV Roma 30 gennaio 2010



Similar documents
MID-TIER DEPLOYMENT KB

Deployment Checklist. Liferay Portal 6.1 Enterprise Edition

NetIQ Access Manager 4.1

Apache and Tomcat Clustering Configuration Table of Contents

Liferay Performance Tuning

Chi sono in quattro punti.

ipratico POS Quick Start Guide v. 1.0

Java Performance Tuning

Scaling Progress OpenEdge Appservers. Syed Irfan Pasha Principal QA Engineer Progress Software

IBM System Storage DS3400 Simple SAN Express Kit PN U

UPGRADING TO XI 3.1 SP6 AND SINGLE SIGN ON. Chad Watson Sr. Business Intelligence Developer

Advanced Liferay Architecture: Clustering and High Availability

CA Identity Governance

Oracle Weblogic. Setup, Configuration, Tuning, and Considerations. Presented by: Michael Hogan Sr. Technical Consultant at Enkitec

IBM System Storage DS3400 Simple SAN Ready Express

Performance Optimization For Operational Risk Management Application On Azure Platform

Liferay Portal Performance Best Practices

C.S.E. Nodi Tipici Parametrizzati al /04/2015 Copyright (c) Castalia srl

IBM System Storage DS3400 Simple SAN

Tuning Your GlassFish Performance Tips. Deep Singh Enterprise Java Performance Team Sun Microsystems, Inc.

LED Power. Power Supplies for constant current HI-POWER LEDs 350/700mA Alimentatori per LED in corrente costante HI-POWER 350/700mA 82206/700

How To Test Pressure On A Hydromusic Pump

Optimize GlassFish Performance in a Production Environment Performance White Paper February Abstract

Best practices for performance tuning JBoss Enterprise

[TFS 4.1 ADVANCED GUIDE]

Java Troubleshooting and Performance

Apache Tomcat Tuning for Production

Main Points. File layout Directory layout

Java Garbage Collection Characteristics and Tuning Guidelines for Apache Hadoop TeraSort Workload

How To Manage A Network On A Pnet 2.5 (Net 2) (Net2) (Procedure) (Network) (Wireless) (Powerline) (Wired) (Lan 2) And (Net1) (

JBoss Seam Performance and Scalability on Dell PowerEdge 1855 Blade Servers

Tomcat Tuning. Mark Thomas April 2009

Best practices for performance tuning JBoss Enterprise

WebSphere Performance Monitoring & Tuning For Webtop Version 5.3 on WebSphere 5.1.x

Informatica Master Data Management Multi Domain Hub API: Performance and Scalability Diagnostics Checklist

Programma corso di formazione J2EE

Oracle Corporation Proprietary and Confidential

JVM Performance Study Comparing Oracle HotSpot and Azul Zing Using Apache Cassandra

Configuring multiple Tomcat instances with a single Apache Load Balancer

Oracle WebLogic Server Monitoring and Performance Tuning

Ahsay Offsite Backup Server v5.5. High Availability Option Setup Guide. Ahsay TM Online Backup - Development Department

ActiveVOS Performance Tuning

MDM Multidomain Edition (Version 9.6.0) For Microsoft SQL Server Performance Tuning

IBM WebSphere Portal 7.0 Performance Tuning Guide

JBoss Data Grid Performance Study Comparing Java HotSpot to Azul Zing

How To Lock A File In A Microsoft Microsoft System

- Applet java appaiono di frequente nelle pagine web - Come funziona l'interprete contenuto in ogni browser di un certo livello? - Per approfondire

Identifying Performance Bottleneck using JRockit. - Shivaram Thirunavukkarasu Performance Engineer Wipro Technologies

Cloud Services: cosa sono e quali vantaggi portano alle aziende manifatturiere

JVM Garbage Collector settings investigation

Performance Monitoring and Tuning. Liferay Chicago User Group (LCHIUG) James Lefeu 29AUG2013

Tuning WebSphere Application Server ND 7.0. Royal Cyber Inc.

How To Read Investire In Borsa Con I Trend Pdf

Source code security testing

USE IMPROVE EVANGELIZE. JVM Internals, Stefan Parvu System Administrator.

Robert Honeyman

SCHEMI PREPARAZIONE CAVI per cabling del Beam Splitter

EMC Documentum Content Management Interoperability Services

Performance brief for IBM WebSphere Application Server 7.0 with VMware ESX 4.0 on HP ProLiant DL380 G6 server

Nuovi domini di primo livello - Registra nuove estensioni con FabsWeb_HOST

8Q PRQGR GL FRQWHQLWRUL $ ZRUOG RI HQFORVXUHV

PREPOSITION OF PLACE

An Oracle White Paper March Load Testing Best Practices for Oracle E- Business Suite using Oracle Application Testing Suite

Angelika Langer The Art of Garbage Collection Tuning

BEAJRockit Mission Control. Using JRockit Mission Control in the Eclipse IDE

How To Improve Performance On An Asa 9.4 Web Application Server (For Advanced Users)

«Software Open Source come fattore abilitante dei Progetti per le Smart Cities»

Web Services Performance: Comparing Java 2 TM Enterprise Edition (J2EE TM platform) and the Microsoft.NET Framework

CBC (EUROPE) Srl NOTA APPLICATIVA

Performance Best Practices for Oracle Enterprise Service Bus and Advanced Queueing

Lecture 10. Subnetting & Supernetting. Supernetting. Subnetting. Outline. medium org: N x class C? Class B? Variable Length Subnet Mask (VLSM)

Licenze Microsoft SQL Server 2005

16 ZONE WIRELESS SISTEMA DI SICUREZZA CASA ALLARME AUTO-DIALER

Agenda. Tomcat Versions Troubleshooting management Tomcat Connectors HTTP Protocal and Performance Log Tuning JVM Tuning Load balancing Tomcat

Monitoring HP OO 10. Overview. Available Tools. HP OO Community Guides

Configuring IBM WebSphere Application Server 6.1 to Support SAS 9.2 Web Applications

- ProFTPd: - ftp://ftp.proftpd.org/distrib/source/proftpd tar.gz

This document provides information for tuning the WebServer and NSJSP products on NonStop servers and consists of the following sections:

The JBoss 4 Application Server Web Developer Reference

Corso: Mastering Microsoft Project 2010 Codice PCSNET: MSPJ-11 Cod. Vendor: Durata: 3

JBoss Cookbook: Secret Recipes. David Chia Senior TAM, JBoss May 5 th 2011

Lecture 10. Subnetting & Supernetting

B M C S O F T W A R E, I N C. BASIC BEST PRACTICES. Ross Cochran Principal SW Consultant

This document will list the ManageEngine Applications Manager best practices

Performance Tuning for Oracle WebCenter Content 11g: Strategies & Tactics CHRIS ROTHWELL & PAUL HEUPEL FISHBOWL SOLUTIONS, INC.

PRE ARRIVAL FORM FOR EXCHANGE STUDENTS

Ricercare l efficienza operativa facilitando il cambiamento con soluzioni enterprise avanzate

Solaris series. vetro temperato 6mm tempered thick glass 6mm. Solaris series. Cornerstone of the series is the pivot shower door with opening to

Geo-Platform Introduction

Enterprise Edition Scalability. ecommerce Framework Built to Scale Reading Time: 10 minutes

WEBLOGIC ADMINISTRATION

Transcription:

Misurazione performance Processing time Performance Throughput

Processing time Network Network DB Processing time

Throughput Quantità di dati trasmessi x secondo

Tuning Areas

Tuning Java Virtual Machine

JVM Heap

Configurazione ottimale Stabilire prima la memoria massima da assegnare alla JVM Stabilire il rapporto young/old generation Generalmente si assegna 1/3 - ½ della memoria alla young generation Evitare lo swap della memoria Heap (Mai assegnare un heap > della memoria fisica) Setta -Xms e -Xmx allo stesso valore Esempio: macchina con 2GB RAM. Modifica in run.bat run.sh set JAVA_OPTS=%JAVA_OPTS% -Xms1200m Xmx1200m XX:NewSize=400M XX:MaxNewSize=400M XX:SurvivorRatio=32

Monitorare il Garbage Collector -verbose:gc Stampa informazioni sul GC. (Size live objects prima e dopo la GC, memoria disponibile e tempo speso dal GC. [GC 325407K->83000K(776768K), 0.2300771 secs] [GC 325816K->83372K(776768K), 0.2454258 secs] [Full GC 267628K->83769K(776768K), 1.8479984 secs] XX:+PrintGCDetails stampa statistiche sulle singole aree di memoria [GC [DefNew: 8128K->8128K(8128K), 0.0000558 secs] [Tenured: 17746K->2309K(24576K), 0.1247669 secs] 25874K->2309K(32704K), 0.1250098 secs]

Scenario #1 Young generation bassa Memoria New liberata 99% New Tenured Memoria Totale Liberata 22% [GC [DefNew: 4032K->64K(4032K), 0.0429742 secs] 9350K->7748K(32704K), 0.0431096 secs] [GC [DefNew: 4032K->64K(4032K), 0.0403446 secs] 11716K->10121K(32704K), 0.0404867 secs] [GC [DefNew: 4032K->64K(4032K), 0.0443969 secs] 14089K->12562K(32704K), 0.0445251 secs] La garbage collection della young generation è efficiente ma la maggior parte di questi oggetti non viene rimossa dalla memoria ma vengono trasferiti troppo presto nella tenured generation.

Scenario #2 Young generation eccessiva Memoria New liberata 0% New Tenured Major Collection libera memoria [GC [DefNew: 16000K->16000K(16192K), 0.0000574 secs][tenured: 2973K- >2704K(16384K), 0.1012650 secs] 18973K->2704K(32576K), 1.1015066 secs] [GC [DefNew: 16000K->16000K(16192K), 0.0000518 secs][tenured: 2704K- >2535K(16384K), 0.0931034 secs] 18704K->2535K(32576K), 1.0933519 secs] [GC [DefNew: 16000K->16000K(16192K), 0.0000498 secs][tenured: 2535K- >2319K(16384K), 0.0860925 secs] 18535K->2319K(32576K), 1.0863350 secs] La young generation è troppo estesa per garantire promozioni alla tenured generation. Di conseguenza la collection viene scatenata dalla tenured generation causando major collections.

Scenario #3 Young generation ok Memoria New liberata 99% New Tenured Memoria Totale Liberata 57% [GC [DefNew: 8128K->64K(8128K), 0.0453670 secs] 13000K->7427K(32704K), 0.0454906 secs] [GC [DefNew: 8128K->64K(8128K), 0.0388632 secs] 15491K->9663K(32704K), 0.0390013 secs] [GC [DefNew: 8128K->64K(8128K), 0.0388610 secs] 17727K->11829K(32704K), 0.0389919 secs] La memoria viene liberata in modo rapido ed efficiente tramite minor collections.si avranno major collections solo alla saturazione della tenured generation.

Configurazione ottimale Major Collections

Tuning Application Server

Application Server pools JBoss AS Thread Pool Connection Pool Worker Threads Web Server

JBoss Thread Pool Perchè l'application server usa un Thread Pool?

Risposta Controllo centralizzato sul numero di richieste Prevenire crash server Performance ( se applicazione usa prevalentemente short lived threads)

Configurazione: jboss-service.xml <mbean code="org.jboss.util.threadpool.basicthreadpool" name="jboss.system:service=threadpool"> <attribute name="name">jboss System Threads</attribute> <attribute name="threadgroupname">system Threads</attribute> <attribute name="keepalivetime">60000</attribute> <attribute name="maximumpoolsize">10</attribute> <attribute name="maximumqueuesize">1000</attribute> <attribute name="blockingmode">abort</attribute> </mbean> Dimensione massima del Pool di Threads Dimensione massima della coda di Threads

Come monitorare il Thread Pool?

Database connection pool JBoss AS Connection Pool Database

Configurazione Datasource <local-tx-datasource> <jndi-name>defaultds</jndi-name> <connectionurl>jdbc:hsqldb:${jboss.server.data.dir}${/}hypersonic${/}lo caldb</connection-url> <driver-class>org.hsqldb.jdbcdriver</driver-class> <user-name>sa</user-name> <password></password> <min-pool-size>5</min-pool-size> <max-pool-size>20</max-pool-size> Dimensione min/max del Pool <idle-timeout-minutes>0</idle-timeout-minutes> <track-statements/> Cache prepared statements <prepared-statement-cache-size>32</prepared-statementcache-size> </local-tx-datasource>

Prepared Statement cache Prepared-statement-cache molto ottimizzante perchè tiene aperto il Prepared Statement tra più request usando una cache LRU. Attenzione: può riservare cursori aperti! Di default è 0, quindi è disattivato E' possibile forzare la chiusura di Statements/Resultset con In SELECT a,b,c,d FROM T1 WHERE a =? SELECT a,b,c,d FROM T1 WHERE b =? SELECT a,b,c,d FROM T1 WHERE c =? SELECT a,b,c,d FROM T1 WHERE d =? <track-statements>nowarn</track-statements Out

Monitoring del Connection Pool

Cosa è il Web Server Pool? JBoss AS Worker Threads Web Server

Configurazione Web Pool File server.xml <Connector port="8080"... maxthreads="250" acceptcount="100" minsparethreads="5" maxsparethreads="50" maxhttpheadersize="8192" connectiontimeout="20000" enablelookups="false" /> Threads contemporanei Max Threads in coda Threads di riserva Dimensione max header Timeout request DNS lookup

Threads running vs Spare Threads JBoss AS Worker Threads Web Server Thread running Spare Thread minsparethreads="5"

Threads running vs Spare Threads JBoss AS Worker Threads X X X Deallocati Web Server Thread running Spare Thread maxsparethreads="10"

Monitoring Web Thread Pool

Tuning JSPs <servlet> <servlet-name>jsp</servlet-name> <servletclass>org.apache.jasper.servlet.jspservlet</servletclass>... <init-param> <param-name>development</param-name> <param-value>false</param-value> </init-param> <init-param> <param-name>checkinterval</param-name> <param-value>0</param-value> </init-param> <init-param> <param-name>trimspaces</param-name> <param-value>true</param-value> </init-param>... </servlet>

Percorso di una request Thread Pool Connection Pool max_open_cursors Worker Threads DB Web Server select sql_text from v$open_cursor;

Risorse : www.jboss.org www.mastertheboss.com http://java.sun.com/ http://java.sun.com/docs/hotspot/gc5.0/gc_tuning_5.html

Promotion code Promotion code JDAY Sconto 15% Valido fino al 28/2/2010 http://www.packtpub.com/