-
Notifications
You must be signed in to change notification settings - Fork 3
/
pom.xml
269 lines (255 loc) · 10.3 KB
/
pom.xml
1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18
19
20
21
22
23
24
25
26
27
28
29
30
31
32
33
34
35
36
37
38
39
40
41
42
43
44
45
46
47
48
49
50
51
52
53
54
55
56
57
58
59
60
61
62
63
64
65
66
67
68
69
70
71
72
73
74
75
76
77
78
79
80
81
82
83
84
85
86
87
88
89
90
91
92
93
94
95
96
97
98
99
100
101
102
103
104
105
106
107
108
109
110
111
112
113
114
115
116
117
118
119
120
121
122
123
124
125
126
127
128
129
130
131
132
133
134
135
136
137
138
139
140
141
142
143
144
145
146
147
148
149
150
151
152
153
154
155
156
157
158
159
160
161
162
163
164
165
166
167
168
169
170
171
172
173
174
175
176
177
178
179
180
181
182
183
184
185
186
187
188
189
190
191
192
193
194
195
196
197
198
199
200
201
202
203
204
205
206
207
208
209
210
211
212
213
214
215
216
217
218
219
220
221
222
223
224
225
226
227
228
229
230
231
232
233
234
235
236
237
238
239
240
241
242
243
244
245
246
247
248
249
250
251
252
253
254
255
256
257
258
259
260
261
262
263
264
265
266
267
268
269
<?xml version="1.0" encoding="UTF-8"?>
<project xmlns="http://maven.apache.org/POM/4.0.0" xmlns:xsi="http://www.w3.org/2001/XMLSchema-instance"
xsi:schemaLocation="http://maven.apache.org/POM/4.0.0 http://maven.apache.org/xsd/maven-4.0.0.xsd">
<modelVersion>4.0.0</modelVersion>
<groupId>com.hindsightsoftware.upkeep</groupId>
<artifactId>example</artifactId>
<version>1.0-SNAPSHOT</version>
<properties>
<maven.compiler.source>1.8</maven.compiler.source>
<maven.compiler.target>1.8</maven.compiler.target>
<scala.version>2.12.3</scala.version>
<encoding>UTF-8</encoding>
<gatling.version>2.3.0</gatling.version>
<gatling-plugin.version>2.2.4</gatling-plugin.version>
<scala-maven-plugin.version>3.2.2</scala-maven-plugin.version>
<!-- Cloud formation properties -->
<jira.cloudformation.ssh.private.key>${user.home}/.ssh/jira-keypair.pem</jira.cloudformation.ssh.private.key>
<jira.cloudformation.template.url>https://s3.amazonaws.com/quickstart-reference/atlassian/jira/latest/templates/JiraDataCenter.template</jira.cloudformation.template.url>
<jira.cloudformation.conf.file>${project.build.testOutputDirectory}/cloudformation.conf</jira.cloudformation.conf.file>
<jira.cloudformation.region>us-east-1</jira.cloudformation.region>
<jira.cloudformation.stack.name>JIRA-Data-Center</jira.cloudformation.stack.name>
<jira.cloudformation.s3.aws.credentails>${project.basedir}/src/test/resources/s3.aws.user/credentials</jira.cloudformation.s3.aws.credentails>
<jira.cloudformation.s3.aws.config>${project.basedir}/src/test/resources/s3.aws.user/config</jira.cloudformation.s3.aws.config>
<jira.cloudformation.s3.restore.bucket>matusnovak-gatling-tests</jira.cloudformation.s3.restore.bucket>
<jira.cloudformation.s3.restore.psql>sample-project.psql</jira.cloudformation.s3.restore.psql>
<jira.cloudformation.s3.restore.indexes>sample-project-indexes.tar.gz</jira.cloudformation.s3.restore.indexes>
<jira.cloudformation.rds.password>cloudformationexample</jira.cloudformation.rds.password>
<!-- Upload addon properties -->
<jira.addon.upload.url.file>${project.build.testOutputDirectory}/baseurl</jira.addon.upload.url.file>
<jira.addon.file>${project.basedir}/src/test/resources/myPlugin-1.0.0-SNAPSHOT.obr</jira.addon.file>
<jira.addon.key>com.atlassian.tutorial.myPlugin-key</jira.addon.key>
<jira.addon.login.username>admin</jira.addon.login.username>
<jira.addon.login.password>admin</jira.addon.login.password>
<jira.addon.license.enabled>true</jira.addon.license.enabled>
<jira.addon.license.file>${project.basedir}/src/test/resources/timebomb.license</jira.addon.license.file>
<!-- Information required to start EC2 instances and control them via SSH -->
<ssh.private.key>${user.home}/.ssh/gatling-keypair.pem</ssh.private.key>
<ec2.key.pair.name>gatling-keypair</ec2.key.pair.name>
<ec2.security.group>default</ec2.security.group>
<ec2.instance.count>2</ec2.instance.count>
<ec2.end.point>https://ec2.us-east-1.amazonaws.com</ec2.end.point>
<ec2.ami.id>ami-8c1be5f6</ec2.ami.id>
<ec2.force.termination>true</ec2.force.termination>
<ec2.keep.alive>false</ec2.keep.alive>
<!-- Use the file generated by jira-cloudformation-maven-plugin which is stored in test output directory.
See "jira.cloudformation.conf.file" parameter -->
<path.config.file>${project.build.testOutputDirectory}/cloudformation.conf</path.config.file>
<!-- Gatling specific options -->
<gatling.local.home>${project.basedir}/gatling/gatling-charts-highcharts-bundle-${gatling.version}/bin/gatling.sh</gatling.local.home>
<gatling.install.script>${project.basedir}/src/test/resources/install-gatling.sh</gatling.install.script>
<gatling.root>gatling-charts-highcharts-bundle-${gatling.version}</gatling.root>
<gatling.java.opts>-Xms1g -Xmx4g</gatling.java.opts>
<!-- S3 integration settings -->
<s3.upload.enabled>true</s3.upload.enabled>
<s3.bucket>matusnovak-gatling-tests</s3.bucket>
<s3.subfolder>my-gatling-tests-results</s3.subfolder>
<skipDownloadGatling>false</skipDownloadGatling>
<skipCloudFormation>false</skipCloudFormation>
<skipAddonUpload>false</skipAddonUpload>
</properties>
<dependencyManagement>
<dependencies>
<dependency>
<groupId>io.gatling</groupId>
<artifactId>gatling-app</artifactId>
<version>${gatling.version}</version>
</dependency>
<dependency>
<groupId>io.gatling</groupId>
<artifactId>gatling-recorder</artifactId>
<version>${gatling.version}</version>
</dependency>
<dependency>
<groupId>io.gatling.highcharts</groupId>
<artifactId>gatling-charts-highcharts</artifactId>
<version>${gatling.version}</version>
</dependency>
<dependency>
<groupId>org.scala-lang</groupId>
<artifactId>scala-library</artifactId>
<version>${scala.version}</version>
</dependency>
</dependencies>
</dependencyManagement>
<dependencies>
<dependency>
<groupId>io.gatling.highcharts</groupId>
<artifactId>gatling-charts-highcharts</artifactId>
</dependency>
<dependency>
<groupId>io.gatling</groupId>
<artifactId>gatling-app</artifactId>
</dependency>
<dependency>
<groupId>io.gatling</groupId>
<artifactId>gatling-recorder</artifactId>
</dependency>
<dependency>
<groupId>org.scala-lang</groupId>
<artifactId>scala-library</artifactId>
</dependency>
</dependencies>
<build>
<plugins>
<!-- Download gatling standalone application based on version provided in this pom.xml -->
<plugin>
<groupId>org.codehaus.mojo</groupId>
<artifactId>exec-maven-plugin</artifactId>
<version>1.4.0</version>
<executions>
<execution>
<id>exec-download-gatling</id>
<phase>generate-resources</phase>
<configuration>
<workingDirectory>.</workingDirectory>
<executable>src/test/resources/download-gatling.sh</executable>
<arguments>
<argument>${gatling.version}</argument>
</arguments>
<skip>${skipDownloadGatling}</skip>
</configuration>
<goals>
<goal>exec</goal>
</goals>
</execution>
</executions>
</plugin>
<!-- Plugin for creating JIRA Data Center on AWS -->
<plugin>
<groupId>com.hindsightsoftware.upkeep</groupId>
<artifactId>jira-cloudformation-maven-plugin</artifactId>
<version>1.0</version>
<executions>
<execution>
<id>start-cloud-formation</id>
<phase>pre-integration-test</phase>
<goals>
<goal>start</goal>
</goals>
<configuration>
<!-- Parameters needed by the template.
Optional keys need to be explicitly declared with no value -->
<parameters>
<!-- In this example, we are using the default VPC with public
subnets so we can access database and instances more easily.
You should not do this for production environment! However,
we are doing this just for testing purposes. The JIRA template
allows us to define already existing VPC. -->
<VPC>vpc-7fbcd119</VPC>
<ExternalSubnets>subnet-b15306ea,subnet-167ceb2a</ExternalSubnets>
<InternalSubnets>subnet-b15306ea,subnet-167ceb2a</InternalSubnets>
<AssociatePublicIpAddress>true</AssociatePublicIpAddress>
<DBMasterUserPassword>cloudformationexample</DBMasterUserPassword>
<DBPassword>cloudformationexample</DBPassword>
<KeyName>jira-keypair</KeyName>
<CustomDnsName/>
<JiraProduct>Software</JiraProduct>
<ClusterNodeMin>1</ClusterNodeMin>
<ClusterNodeMax>2</ClusterNodeMax>
</parameters>
<!-- What parameters to export once the stack is built?
All params will be exported to jira.cloudformation.conf.file
as key-value pairs -->
<exports>
<param>JIRAURL</param>
<param>LoadBalancerURL</param>
</exports>
<skip>${skipCloudFormation}</skip>
</configuration>
</execution>
<execution>
<id>stop-cloud-formation</id>
<phase>post-integration-test</phase>
<goals>
<goal>stop</goal>
</goals>
</execution>
</executions>
</plugin>
<!-- Plugin for uploading addons into JIRA -->
<plugin>
<groupId>com.hindsightsoftware.upkeep</groupId>
<artifactId>jira-upload-addon-maven-plugin</artifactId>
<version>1.0</version>
<executions>
<execution>
<id>upload-jira-addon</id>
<phase>pre-integration-test</phase>
<goals>
<goal>upload</goal>
</goals>
<configuration>
<skip>${skipAddonUpload}</skip>
</configuration>
</execution>
</executions>
</plugin>
</plugins>
</build>
<profiles>
<!-- Default profile to run Gatling tests locally -->
<profile>
<id>local</id>
<activation>
<activeByDefault>true</activeByDefault>
</activation>
<build>
<plugins>
<plugin>
<groupId>net.alchim31.maven</groupId>
<artifactId>scala-maven-plugin</artifactId>
<version>${scala-maven-plugin.version}</version>
</plugin>
<plugin>
<groupId>io.gatling</groupId>
<artifactId>gatling-maven-plugin</artifactId>
<version>${gatling-plugin.version}</version>
<executions>
<execution>
<configuration>
<runMultipleSimulations>true</runMultipleSimulations>
</configuration>
<phase>integration-test</phase>
<goals>
<goal>integration-test</goal>
</goals>
</execution>
</executions>
</plugin>
</plugins>
</build>
</profile>
<!-- Alternative profile to run Gatling tests on EC2 instances -->
<profile>
<id>remote</id>
<build>
<plugins>
<plugin>
<groupId>com.ea.gatling</groupId>
<artifactId>gatling-aws-maven-plugin</artifactId>
<version>1.0.14</version>
<executions>
<execution>
<phase>integration-test</phase>
<goals>
<goal>execute</goal>
</goals>
</execution>
</executions>
</plugin>
</plugins>
</build>
</profile>
</profiles>
</project>