| enable-monitoring | 해당 어플리케이션에 대한 모니터링 여부를 정의한다. false일 경우, 어떠한 데이터도 Anyframe Monitoring Tool GUI에서 보이지 않는다. | |
| jdbc-monitoring-enable | 해당 어플리케이션의 JDBC 실행에 대한 모니터링 여부를 정의한다. | false |
| enable-call-tracing | Anyframe Monitoring Tool을 통해 실행 순서대로 기록될 것인지 정의한다. Anyframe Monitoring Tool GUI에서는 트리 구조로써 보여준다. | false |
| prune-threshold | Anyframe Monitoring Tool이 표현할 수 있는 한계 시간(milliseconds)을 정의한다. 수행시간은 Anyframe Monitoring Tool을 통해 ms보다 더 작은 값으로 줄어든다. | 3000 |
| last-invocations-to-trace | Anyframe Monitoring Tool GUI의 Last Invocations 페이지에 표현될 Invocation 개수를 정의한다. | 0 |
| prepared-statement-monitoring-enable | PreparedStatement 처리시 해당 쿼리문의 인자값을 표현할 것인지를 정의한다. | false |
| mbean-server-provider | MBean server provider의 클래스명을 정의한다. Weblogic server의 net.sf.infrared.weblogic.configmgmt.WLSMBeanServerProvider와 net.sf.infrared.jboss.configmgmt가 보통이며, JBoss server에는 JBossMBeanServerProvider가 있다. Anyframe Monitoring Tool MBean은 MC4K Management Console과 같은 JMX 기반의 툴을 사용하여 설정할 수 있다. 이 MBean은 다음과 같은 속성들을 attribute로 노출하고 있다. : enable-monitoring, jdbc-monitoring-enable, enable-call-tracing, prune-threshold | none |
| collection-strategy | 수집된 데이터를 표현하기 위한 strategy가 정의된 class명을 정의한다. Anyframe Monitoring Tool은 현재 CentralizedCollectionStrategy, net.sf.infrared.agent.transport.impl.CentralizedCollectionStrategy과 유사한 클래스만을 지원한다. default인 DoNothingCollectionStrategy는, 이름에서 알 수 있듯이 아무것도 수행하지 않는다. | net.sf.infrared.agent.transport. impl.DoNothingCollectionStrategy |
| collection-strategy.ccs.remotehost | Anyframe Monitoring Tool이 실행되고 있는 컴퓨터의 ip를 정의한다. 모니터링 대상 어플리케이션으로부터 수집된 데이터는 Socket을 통해 Anyframe Monitoring Tool의 Collertor에게 flush된다. | localhost |
| collection-strategy.ccs.port | Anyframe Monitoring Tool의 Collector가 listening할 해당 컴퓨터의 port를 정의한다. | 7777 |
| collection-strategy.ccs.flush-frequency | Remotehost에서 모니터링 대상 어플리케이션의 데이터가 Collector에 flush되는 주기를 정의한다. flush되는 주기값은 양호한 성능을 위해서 최적화될 필요가 있다. 그 값이 클수록 어플리케이션을 종료하는데 저장할 통계치가 크고, 이에따라 더 많은 메모리가 필요할 것이다. 반면에 낮은 주기값은, 더 큰 network traffic을 뜻한다. | 30000 |
| collection-strategy.ccs.pool | Collector가 flush되기 전에 Thread Pool이 수집된 데이터를 유지할 것인지를 정의한다. | true |
| collection-strategy.ccs.pool.maxThreads | Thread pool에서 허용 가능한 thread의 최대 개수를 정의한다. collection-strategy.ccs.pool 속성이 true일 경우에만 적용할 수 있다. | 1 |
| collection-strategy.ccs.pool.buffer-length | 유지가능한 element의 수를 알려주는 pool buffer의 용량을 정의한다. collection-strategy.ccs.pool 속성이 true일 경우에만 적용할 수 있다. | 100 |
# The sample infrared-agent.properties enable-monitoring true enable-call-tracing true jdbc-monitoring-enable true prune-threshold -1 last-invocations-to-trace 5 prepared-statement-monitoring-enable true collection-strategy net.sf.infrared.agent.transport.impl.CentralizedCollectionStrategy collection-strategy.ccs.remotehost localhost collection-strategy.ccs.port 7777 collection-strategy.ccs.pool false collection-strategy.ccs.flush-frequency 3000
<!-- ... -->
<listener>
<listener-class>net.sf.infrared.agent.setup.InfraREDServletContextListener</listener-class>
</listener>
<filter>
<filter-name>infrared</filter-name>
<filter-class>net.sf.infrared.aspects.servlet.InfraREDServletFilter</filter-class>
</filter>
<filter-mapping>
<filter-name>infrared</filter-name>
<url-pattern>*.do</url-pattern>
</filter-mapping>
<!-- ... -->
<?xml version="1.0" encoding="UTF-8"?> <beans xmlns="http://www.springframework.org/schema/beans" xmlns:xsi="http://www.w3.org/2001/XMLSchema-instance" xmlns:aop="http://www.springframework.org/schema/aop" xsi:schemaLocation="http://www.springframework.org/schema/beans http://www.springframework.org/schema/beans/spring-beans-2.0.xsd http://www.springframework.org/schema/aop http://www.springframework.org/schema/aop/spring-aop-2.0.xsd"> <bean id="anyframe_api_profiler" class="anyframe.common.aop.aspects.ApiAspect" > <property name="layerName" value="APPLICATION_SERVICE"></property> </bean> <bean id="anyframe_api_profiler_aop_autowire" class="anyframe.common.aop.ExclusiveBeanNameAutoProxyCreator"> <property name="beanNames" value="*Service"/> <property name="exclusiveBeanNames" value="anyframe_api_profiler"/> <property name="interceptorNames"> <list> <value>anyframe_api_profiler</value> </list> </property> </bean> </beans>
<?xml version="1.0" encoding="UTF-8"?> <beans xmlns="http://www.springframework.org/schema/beans" xmlns:xsi="http://www.w3.org/2001/XMLSchema-instance" xmlns:aop="http://www.springframework.org/schema/aop" xsi:schemaLocation="http://www.springframework.org/schema/beans http://www.springframework.org/schema/beans/spring-beans-2.0.xsd http://www.springframework.org/schema/aop http://www.springframework.org/schema/aop/spring-aop-2.0.xsd"> <bean id="anyframe_jdbc_profiler" class="anyframe.common.aop.aspects.JdbcAspect" > </bean> <bean id="anyframe_jdbc_profiler_aop_autowire" class="anyframe.common.aop.ExclusiveBeanNameAutoProxyCreator"> <property name="beanNames" value="dataSource"/> <property name="exclusiveBeanNames" value="anyframe_jdbc_profiler"/> <property name="interceptorNames"> <list> <value>anyframe_jdbc_profiler</value> </list> </property> </bean> </beans>
#HSQL Database Engine #Thu Mar 12 13:30:09 KST 2009 hsqldb.script_format=0 #기본적으로는 값을 설정하지 않으나 메모리 문제가 있는 사이트에서는 이와 같이 gc 주기를 줄수 있음(단위 ms) runtime.gc_interval=60000 sql.enforce_strict_size=false #1kb 하나의 레코드의 평균 크기 2^10 = 1024 bytes (프로젝트 상황에 맞게 설정, default 10 권장) hsqldb.cache_size_scale=10 readonly=false #기본값 권장 hsqldb.nio_data_file=true #기본값 권장 (JDK가 NIO를 지원지 않으면 false 로 설정) #4k rows 메모리에 캐쉬할 레코드 갯수 (14의 의미 : 2^14개, 클 수록 성능은 좋아지나, 메모리 많이 점유함) hsqldb.cache_scale=14 version=1.8.0 #테이블 정보를 메모리에 저장할지 디스크에 저장할지 여부 결정? #(기본 Memory로 되어 있으나 서버 메모리 Full나므로 Cache로 설정) hsqldb.default_table_type=cached hsqldb.cache_file_scale=8 #8gb db 정보를 디스크 캐쉬에 저장할 사이즈 (8기가 <-- 상황에 맞게 설정) sql.compare_in_locale=false hsqldb.log_size=200 #hsql 로그 사이즈 (기본값 유지) modified=yes hsqldb.cache_version=1.7.0 hsqldb.original_version=1.8.0 hsqldb.compatible_version=1.8.0