forked from keptn-sandbox/keptn-on-k3s
-
Notifications
You must be signed in to change notification settings - Fork 0
Commit
This commit does not belong to any branch on this repository, and may belong to a fork outside of the repository.
adding a new demo project definition
Signed-off-by: Andreas Grabner <[email protected]>
- Loading branch information
1 parent
7a891ff
commit a7ee302
Showing
26 changed files
with
1,551 additions
and
1 deletion.
There are no files selected for viewing
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
17 changes: 17 additions & 0 deletions
17
keptn_project_templates/two-stage-delivery-simplenode/dynatrace/dynatrace.conf.yaml
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -0,0 +1,17 @@ | ||
--- | ||
spec_version: '0.1.0' | ||
dashboard: query | ||
attachRules: | ||
tagRule: | ||
- meTypes: | ||
- PROCESS_GROUP_INSTANCE | ||
tags: | ||
- context: CONTEXTLESS | ||
key: keptn_project | ||
value: $PROJECT | ||
- context: CONTEXTLESS | ||
key: keptn_service | ||
value: $SERVICE | ||
- context: CONTEXTLESS | ||
key: keptn_stage | ||
value: $STAGE |
2 changes: 2 additions & 0 deletions
2
keptn_project_templates/two-stage-delivery-simplenode/dynatrace/monaco.conf.yaml
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -0,0 +1,2 @@ | ||
projects: | ||
- simplenode |
172 changes: 172 additions & 0 deletions
172
keptn_project_templates/two-stage-delivery-simplenode/jmeter/basiccheck.jmx
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -0,0 +1,172 @@ | ||
<?xml version="1.0" encoding="UTF-8"?> | ||
<jmeterTestPlan version="1.2" properties="5.0" jmeter="5.1.1 r1855137"> | ||
<hashTree> | ||
<TestPlan guiclass="TestPlanGui" testclass="TestPlan" testname="Testing Sample NodeJs" enabled="true"> | ||
<stringProp name="TestPlan.comments"></stringProp> | ||
<boolProp name="TestPlan.functional_mode">false</boolProp> | ||
<boolProp name="TestPlan.serialize_threadgroups">false</boolProp> | ||
<elementProp name="TestPlan.user_defined_variables" elementType="Arguments" guiclass="ArgumentsPanel" testclass="Arguments" testname="User Defined Variables" enabled="true"> | ||
<collectionProp name="Arguments.arguments"> | ||
<elementProp name="SERVER_URL" elementType="Argument"> | ||
<stringProp name="Argument.name">SERVER_URL</stringProp> | ||
<stringProp name="Argument.value"></stringProp> | ||
<stringProp name="Argument.metadata">=</stringProp> | ||
</elementProp> | ||
<elementProp name="CHECK_PATH" elementType="Argument"> | ||
<stringProp name="Argument.name">CHECK_PATH</stringProp> | ||
<stringProp name="Argument.value">/</stringProp> | ||
<stringProp name="Argument.metadata">=</stringProp> | ||
</elementProp> | ||
<elementProp name="DT_LTN" elementType="Argument"> | ||
<stringProp name="Argument.name">DT_LTN</stringProp> | ||
<stringProp name="Argument.value">Default</stringProp> | ||
<stringProp name="Argument.metadata">=</stringProp> | ||
</elementProp> | ||
<elementProp name="DefaultThinkTime" elementType="Argument"> | ||
<stringProp name="Argument.name">DefaultThinkTime</stringProp> | ||
<stringProp name="Argument.value">250</stringProp> | ||
<stringProp name="Argument.metadata">=</stringProp> | ||
</elementProp> | ||
<elementProp name="PROTOCOL" elementType="Argument"> | ||
<stringProp name="Argument.name">PROTOCOL</stringProp> | ||
<stringProp name="Argument.value">http</stringProp> | ||
<stringProp name="Argument.metadata">=</stringProp> | ||
</elementProp> | ||
<elementProp name="VUCount" elementType="Argument"> | ||
<stringProp name="Argument.name">VUCount</stringProp> | ||
<stringProp name="Argument.value">1</stringProp> | ||
<stringProp name="Argument.metadata">=</stringProp> | ||
</elementProp> | ||
<elementProp name="LoopCount" elementType="Argument"> | ||
<stringProp name="Argument.name">LoopCount</stringProp> | ||
<stringProp name="Argument.value">1</stringProp> | ||
<stringProp name="Argument.metadata">=</stringProp> | ||
</elementProp> | ||
</collectionProp> | ||
</elementProp> | ||
<stringProp name="TestPlan.user_define_classpath"></stringProp> | ||
</TestPlan> | ||
<hashTree> | ||
<ThreadGroup guiclass="ThreadGroupGui" testclass="ThreadGroup" testname="BasicThreadGroup" enabled="true"> | ||
<stringProp name="ThreadGroup.on_sample_error">continue</stringProp> | ||
<elementProp name="ThreadGroup.main_controller" elementType="LoopController" guiclass="LoopControlPanel" testclass="LoopController" testname="Loop Controller" enabled="true"> | ||
<boolProp name="LoopController.continue_forever">false</boolProp> | ||
<stringProp name="LoopController.loops">${__P(LoopCount,${LoopCount})}</stringProp> | ||
</elementProp> | ||
<stringProp name="ThreadGroup.num_threads">${__P(VUCount,${VUCount})}</stringProp> | ||
<stringProp name="ThreadGroup.ramp_time">1</stringProp> | ||
<longProp name="ThreadGroup.start_time">1444323045000</longProp> | ||
<longProp name="ThreadGroup.end_time">1444323045000</longProp> | ||
<boolProp name="ThreadGroup.scheduler">false</boolProp> | ||
<stringProp name="ThreadGroup.duration"></stringProp> | ||
<stringProp name="ThreadGroup.delay"></stringProp> | ||
</ThreadGroup> | ||
<hashTree> | ||
<CookieManager guiclass="CookiePanel" testclass="CookieManager" testname="HTTP Cookie Manager" enabled="true"> | ||
<collectionProp name="CookieManager.cookies"/> | ||
<boolProp name="CookieManager.clearEachIteration">false</boolProp> | ||
</CookieManager> | ||
<hashTree/> | ||
<HeaderManager guiclass="HeaderPanel" testclass="HeaderManager" testname="HTTP Header Manager" enabled="true"> | ||
<collectionProp name="HeaderManager.headers"/> | ||
</HeaderManager> | ||
<hashTree/> | ||
<BeanShellPreProcessor guiclass="TestBeanGUI" testclass="BeanShellPreProcessor" testname="Set Dynatrace Headers" enabled="true"> | ||
<boolProp name="resetInterpreter">true</boolProp> | ||
<stringProp name="parameters"></stringProp> | ||
<stringProp name="filename"></stringProp> | ||
<stringProp name="script">import org.apache.jmeter.util.JMeterUtils; | ||
import org.apache.jmeter.protocol.http.control.HeaderManager; | ||
import java.io; | ||
import java.util; | ||
|
||
// ------------------------------------------------------------------------------------- | ||
// Generate the x-dynatrace-test header based on this best practic | ||
// -> https://www.dynatrace.com/support/help/integrations/test-automation-frameworks/how-do-i-integrate-dynatrace-into-my-load-testing-process/ | ||
// ------------------------------------------------------------------------------------- | ||
String LTN=JMeterUtils.getProperty("DT_LTN"); | ||
if((LTN == null) || (LTN.length() == 0)) { | ||
if(vars != null) { | ||
LTN = vars.get("DT_LTN"); | ||
} | ||
} | ||
if(LTN == null) LTN = "NoTestName"; | ||
|
||
String LSN = (bsh.args.length > 0) ? bsh.args[0] : "Test Scenario"; | ||
String TSN = sampler.getName(); | ||
String VU = ctx.getThreadGroup().getName() + ctx.getThreadNum(); | ||
String headerValue = "LSN="+ LSN + ";TSN=" + TSN + ";LTN=" + LTN + ";VU=" + VU + ";"; | ||
|
||
// ------------------------------------------- | ||
// Set header | ||
// ------------------------------------------- | ||
HeaderManager hm = sampler.getHeaderManager(); | ||
hm.removeHeaderNamed("x-dynatrace-test"); | ||
hm.add(new org.apache.jmeter.protocol.http.control.Header("x-dynatrace-test", headerValue));</stringProp> | ||
</BeanShellPreProcessor> | ||
<hashTree/> | ||
<HTTPSamplerProxy guiclass="HttpTestSampleGui" testclass="HTTPSamplerProxy" testname="Basic Check" enabled="true"> | ||
<elementProp name="HTTPsampler.Arguments" elementType="Arguments" guiclass="HTTPArgumentsPanel" testclass="Arguments" enabled="true"> | ||
<collectionProp name="Arguments.arguments"/> | ||
</elementProp> | ||
<stringProp name="HTTPSampler.domain">${__P(SERVER_URL,${SERVER_URL})}</stringProp> | ||
<stringProp name="HTTPSampler.port">${__P(SERVER_PORT,${SERVER_PORT})}</stringProp> | ||
<stringProp name="HTTPSampler.protocol">${__P(PROTOCOL,${PROTOCOL})}</stringProp> | ||
<stringProp name="HTTPSampler.contentEncoding"></stringProp> | ||
<stringProp name="HTTPSampler.path">${__P(CHECK_PATH,${CHECK_PATH})}</stringProp> | ||
<stringProp name="HTTPSampler.method">GET</stringProp> | ||
<boolProp name="HTTPSampler.follow_redirects">true</boolProp> | ||
<boolProp name="HTTPSampler.auto_redirects">false</boolProp> | ||
<boolProp name="HTTPSampler.use_keepalive">true</boolProp> | ||
<boolProp name="HTTPSampler.DO_MULTIPART_POST">false</boolProp> | ||
<stringProp name="HTTPSampler.embedded_url_re"></stringProp> | ||
<stringProp name="HTTPSampler.connect_timeout"></stringProp> | ||
<stringProp name="HTTPSampler.response_timeout"></stringProp> | ||
</HTTPSamplerProxy> | ||
<hashTree> | ||
<HeaderManager guiclass="HeaderPanel" testclass="HeaderManager" testname="HTTP Header Manager" enabled="true"> | ||
<collectionProp name="HeaderManager.headers"/> | ||
</HeaderManager> | ||
<hashTree/> | ||
</hashTree> | ||
<ConstantTimer guiclass="ConstantTimerGui" testclass="ConstantTimer" testname="Default Think Time" enabled="true"> | ||
<stringProp name="ConstantTimer.delay">{__P(ThinkTime,${DefaultThinkTime})}</stringProp> | ||
</ConstantTimer> | ||
<hashTree/> | ||
</hashTree> | ||
<ResultCollector guiclass="SummaryReport" testclass="ResultCollector" testname="Summary Report" enabled="true"> | ||
<boolProp name="ResultCollector.error_logging">false</boolProp> | ||
<objProp> | ||
<name>saveConfig</name> | ||
<value class="SampleSaveConfiguration"> | ||
<time>true</time> | ||
<latency>true</latency> | ||
<timestamp>true</timestamp> | ||
<success>true</success> | ||
<label>true</label> | ||
<code>true</code> | ||
<message>true</message> | ||
<threadName>true</threadName> | ||
<dataType>true</dataType> | ||
<encoding>false</encoding> | ||
<assertions>true</assertions> | ||
<subresults>true</subresults> | ||
<responseData>false</responseData> | ||
<samplerData>false</samplerData> | ||
<xml>false</xml> | ||
<fieldNames>false</fieldNames> | ||
<responseHeaders>false</responseHeaders> | ||
<requestHeaders>false</requestHeaders> | ||
<responseDataOnError>false</responseDataOnError> | ||
<saveAssertionResultsFailureMessage>false</saveAssertionResultsFailureMessage> | ||
<assertionsResultsToSave>0</assertionsResultsToSave> | ||
<bytes>true</bytes> | ||
<threadCounts>true</threadCounts> | ||
</value> | ||
</objProp> | ||
<stringProp name="filename"></stringProp> | ||
</ResultCollector> | ||
<hashTree/> | ||
</hashTree> | ||
</hashTree> | ||
</jmeterTestPlan> |
45 changes: 45 additions & 0 deletions
45
keptn_project_templates/two-stage-delivery-simplenode/jmeter/jmeter.conf.yaml
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -0,0 +1,45 @@ | ||
--- | ||
spec_version: '0.1.0' | ||
workloads: | ||
- teststrategy: performance_long | ||
vuser: 10 | ||
loopcount: 2000 | ||
thinktime: 250 | ||
acceptederrorrate: 1.0 | ||
script: jmeter/load.jmx | ||
- teststrategy: performance_100 | ||
vuser: 100 | ||
loopcount: 10 | ||
thinktime: 250 | ||
acceptederrorrate: 1.0 | ||
script: jmeter/load.jmx | ||
- teststrategy: performance_50 | ||
vuser: 50 | ||
loopcount: 10 | ||
thinktime: 250 | ||
acceptederrorrate: 1.0 | ||
script: jmeter/load.jmx | ||
- teststrategy: performance_10 | ||
vuser: 50 | ||
loopcount: 10 | ||
thinktime: 250 | ||
acceptederrorrate: 1.0 | ||
script: jmeter/load.jmx | ||
- teststrategy: performance_quick | ||
vuser: 10 | ||
loopcount: 100 | ||
thinktime: 250 | ||
acceptederrorrate: 1.0 | ||
script: jmeter/load.jmx | ||
- teststrategy: performance_peak | ||
vuser: 10 | ||
loopcount: 500 | ||
thinktime: 250 | ||
acceptederrorrate: 1.0 | ||
script: jmeter/load.jmx | ||
- teststrategy: performance | ||
vuser: 10 | ||
loopcount: 100 | ||
thinktime: 250 | ||
acceptederrorrate: 1.0 | ||
script: jmeter/load.jmx |
Oops, something went wrong.