目的
- 了解JAVA程序性能调优的过程、原理以及常见方法;在这方面做到“知道自己不知道”;
- 不用了解太多细节,这些细节的学习需要结合大量实践,只能有机会再深入。
TODO/疑问
- 为什么优化GC时,要按照“确定内存需求" -> "延迟调优" -> "吞吐量调优"的顺序? 是因为这些指标之间存在该顺序表明的依赖关系?
- 如何定义性能需求?
| wget http://repos.fedorapeople.org/repos/dchen/apache-maven/epel-apache-maven.repo -O /etc/yum.repos.d/epel-apache-maven.repo | |
| yum install apache-maven |
目的
TODO/疑问
| import com.fasterxml.jackson.annotation.JsonPropertyOrder; | |
| import com.fasterxml.jackson.databind.ObjectWriter; | |
| import com.fasterxml.jackson.dataformat.csv.CsvMapper; | |
| import com.fasterxml.jackson.dataformat.csv.CsvSchema; | |
| import java.io.BufferedOutputStream; | |
| import java.io.File; | |
| import java.io.FileNotFoundException; | |
| import java.io.FileOutputStream; | |
| import java.io.IOException; | |
| import java.io.OutputStreamWriter; |
| #! /bin/sh | |
| # | |
| # chkconfig: - 55 45 | |
| # description: The memcached daemon is a network memory cache service. | |
| # processname: memcached | |
| # config: /etc/sysconfig/memcached | |
| # pidfile: /var/run/memcached/memcached.pid | |
| # Standard LSB functions | |
| #. /lib/lsb/init-functions |
| var CryptoJS = require('crypto-js') | |
| var request = require('request-promise') | |
| /* | |
| * npm install crypto-js request-promise request | |
| * node wx_t1t_hack.js | |
| */ | |
| // export function testEncription(msg, fullKey) { | |
| // var fullKey = fullKey.slice(0, 16) |
(by @andrestaltz)
If you prefer to watch video tutorials with live-coding, then check out this series I recorded with the same contents as in this article: Egghead.io - Introduction to Reactive Programming.
| /* TOP SLOW REQUESTS */ | |
| /* time is in microseconds */ | |
| SELECT creation_time | |
| ,last_execution_time | |
| ,total_physical_reads | |
| ,total_logical_reads | |
| ,total_logical_writes | |
| , execution_count | |
| , total_worker_time | |
| , total_elapsed_time |
| http://rusanu.com/2014/02/24/how-to-analyse-sql-server-performance/ | |
| White Papers: | |
| Waits and Queues White-Paper (2005) http://technet.microsoft.com/en-us/library/cc966413.aspx | |
| Waits and Queues after 2005 - http://msdn.microsoft.com/en-us/library/ms179984.aspx | |
| sys.dm_exec_requests What is executing right now | |
| sys.dm_os_waiting_tasks Currently waiting tasks | |
| sys.dm_os_wait_stats Aggregated statistics about all wait types | |
| sys.dm_exec_query_stats runtime execution statistics for most queries |
| git config merge.renormalize true # prevents unnecessary merge conflicts, http://stackoverflow.com/a/12194759/23566 |
| --from http://sqlblog.com/blogs/john_paul_cook/archive/2009/08/24/using-the-processes-query-outside-of-activity-monitor.aspx | |
| /* ACTIVITY MONITOR */ | |
| /* Processes */ | |
| SELECT | |
| [Session ID] = s.session_id, |