Skip to content

Commit 492380d

Browse files
authored
Merge pull request #75 from chanchiem/master
Add Benchmarking Package
2 parents 9cc58d5 + acabcc5 commit 492380d

9 files changed

Lines changed: 2553 additions & 0 deletions

File tree

aws-xray-recorder-sdk-benchmark/README.md

Lines changed: 1590 additions & 0 deletions
Large diffs are not rendered by default.
Lines changed: 129 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -0,0 +1,129 @@
1+
<?xml version="1.0" encoding="UTF-8"?>
2+
<project xmlns="http://maven.apache.org/POM/4.0.0"
3+
xmlns:xsi="http://www.w3.org/2001/XMLSchema-instance"
4+
xsi:schemaLocation="http://maven.apache.org/POM/4.0.0 http://maven.apache.org/xsd/maven-4.0.0.xsd">
5+
<parent>
6+
<artifactId>aws-xray-recorder-sdk-pom</artifactId>
7+
<groupId>com.amazonaws</groupId>
8+
<version>2.2.1</version>
9+
</parent>
10+
<modelVersion>4.0.0</modelVersion>
11+
12+
<artifactId>aws-xray-recorder-sdk-benchmark</artifactId>
13+
<version>2.2.1</version>
14+
<name>AWS X-Ray Recorder SDK for Java - AWS SDK Benchmark</name>
15+
16+
<packaging>jar</packaging>
17+
18+
<properties>
19+
<java.version>1.8</java.version>
20+
<jmh.version>1.8</jmh.version>
21+
22+
<project.build.sourceEncoding>UTF-8</project.build.sourceEncoding>
23+
<project.reporting.outputEncoding>UTF-8</project.reporting.outputEncoding>
24+
<maven-assembly-plugin.version>2.6</maven-assembly-plugin.version>
25+
<maven-compiler-plugin.version>3.5.1</maven-compiler-plugin.version>
26+
<maven-build-helper-plugin.version>1.12</maven-build-helper-plugin.version>
27+
</properties>
28+
29+
<build>
30+
<plugins>
31+
<plugin>
32+
<groupId>org.codehaus.mojo</groupId>
33+
<artifactId>build-helper-maven-plugin</artifactId>
34+
<version>${maven-build-helper-plugin.version}</version>
35+
<executions>
36+
<execution>
37+
<id>add-test-source</id>
38+
<phase>generate-test-sources</phase>
39+
<goals>
40+
<goal>add-test-source</goal>
41+
</goals>
42+
<configuration>
43+
<sources>
44+
<source>tst/main/java</source>
45+
</sources>
46+
</configuration>
47+
</execution>
48+
</executions>
49+
</plugin>
50+
51+
<plugin>
52+
<groupId>org.apache.maven.plugins</groupId>
53+
<artifactId>maven-compiler-plugin</artifactId>
54+
<version>${maven-compiler-plugin.version}</version>
55+
<configuration>
56+
<source>${java.version}</source>
57+
<target>${java.version}</target>
58+
<compilerVersion>${java.version}</compilerVersion>
59+
</configuration>
60+
<executions>
61+
<execution>
62+
<goals>
63+
<goal>testCompile</goal>
64+
</goals>
65+
66+
<configuration>
67+
<annotationProcessorPaths>
68+
<path>
69+
<groupId>org.openjdk.jmh</groupId>
70+
<artifactId>jmh-generator-annprocess</artifactId>
71+
<version>${jmh.version}</version>
72+
</path>
73+
</annotationProcessorPaths>
74+
</configuration>
75+
</execution>
76+
</executions>
77+
</plugin>
78+
79+
<plugin>
80+
<artifactId>maven-assembly-plugin</artifactId>
81+
<version>${maven-assembly-plugin.version}</version>
82+
<configuration>
83+
<descriptor>tst/main/assembly/benchmarks.xml</descriptor>
84+
</configuration>
85+
<executions>
86+
<execution>
87+
<id>make-assembly</id>
88+
<phase>package</phase>
89+
<goals>
90+
<goal>single</goal>
91+
</goals>
92+
<configuration>
93+
<appendAssemblyId>false</appendAssemblyId>
94+
<finalName>benchmark</finalName>
95+
<attach>true</attach>
96+
<archive>
97+
<manifest>
98+
<mainClass>org.openjdk.jmh.Main</mainClass>
99+
</manifest>
100+
</archive>
101+
</configuration>
102+
</execution>
103+
</executions>
104+
</plugin>
105+
</plugins>
106+
</build>
107+
108+
<dependencies>
109+
<!-- Add X-Ray as a dependency. When adding benchmarks for X-Ray
110+
components other than the core, please add them here -->
111+
<dependency>
112+
<groupId>com.amazonaws</groupId>
113+
<artifactId>aws-xray-recorder-sdk-core</artifactId>
114+
<version>${awsxrayrecordersdk.version}</version>
115+
</dependency>
116+
117+
<!-- Benchmarking Depdendencies -->
118+
<dependency>
119+
<groupId>org.openjdk.jmh</groupId>
120+
<artifactId>jmh-core</artifactId>
121+
<version>${jmh.version}</version>
122+
</dependency>
123+
<dependency>
124+
<groupId>org.openjdk.jmh</groupId>
125+
<artifactId>jmh-generator-annprocess</artifactId>
126+
<version>${jmh.version}</version>
127+
</dependency>
128+
</dependencies>
129+
</project>
Lines changed: 17 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -0,0 +1,17 @@
1+
{
2+
"version": 1,
3+
"default": {
4+
"fixed_target": 0,
5+
"rate": 0.00
6+
},
7+
"rules": [
8+
{
9+
"description": "Rule that samples no request.",
10+
"service_name": "*",
11+
"http_method": "*",
12+
"url_path": "/*",
13+
"fixed_target": 0,
14+
"rate": 0.0
15+
}
16+
]
17+
}
Lines changed: 28 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -0,0 +1,28 @@
1+
<assembly
2+
xmlns="http://maven.apache.org/plugins/maven-assembly-plugin/assembly/1.1.3"
3+
xmlns:xsi="http://www.w3.org/2001/XMLSchema-instance"
4+
xsi:schemaLocation="http://maven.apache.org/plugins/maven-assembly-plugin/assembly/1.1.3 http://maven.apache.org/xsd/assembly-1.1.3.xsd">
5+
<id>benchmarks</id>
6+
<formats>
7+
<format>jar</format>
8+
</formats>
9+
<includeBaseDirectory>false</includeBaseDirectory>
10+
<dependencySets>
11+
<dependencySet>
12+
<outputDirectory>/</outputDirectory>
13+
<useProjectArtifact>true</useProjectArtifact>
14+
<unpack>true</unpack>
15+
<scope>test</scope>
16+
</dependencySet>
17+
</dependencySets>
18+
<fileSets>
19+
<fileSet>
20+
<directory>${project.build.directory}/test-classes</directory>
21+
<outputDirectory>/</outputDirectory>
22+
<includes>
23+
<include>**/*</include>
24+
</includes>
25+
<useDefaultExcludes>true</useDefaultExcludes>
26+
</fileSet>
27+
</fileSets>
28+
</assembly>

0 commit comments

Comments
 (0)