Skip to content
This repository has been archived by the owner on Apr 16, 2022. It is now read-only.

Commit

Permalink
Add release profile and instruction key property. (#192)
Browse files Browse the repository at this point in the history
Signed-off-by: Pan Li <[email protected]>
  • Loading branch information
Incarnation-p-lee authored Dec 18, 2018
1 parent 9fa0ac5 commit 49dd547
Show file tree
Hide file tree
Showing 2 changed files with 16 additions and 3 deletions.
15 changes: 14 additions & 1 deletion pom.xml
Original file line number Diff line number Diff line change
Expand Up @@ -145,6 +145,7 @@
<resources>
<resource>
<directory>src/main/resources</directory>
<filtering>true</filtering>
<includes>
<include>ApplicationInsights.xml</include>
</includes>
Expand Down Expand Up @@ -304,6 +305,18 @@
<skip.integration.tests>false</skip.integration.tests>
</properties>
</profile>
</profiles>

<profile>
<id>release</id>
<activation>
<property>
<name>release</name>
</property>
</activation>
<properties>
<ai.instrumentKey>${telemetry.instrumentationKey}</ai.instrumentKey>
</properties>
</profile>

</profiles>
</project>
4 changes: 2 additions & 2 deletions src/main/resources/ApplicationInsights.xml
Original file line number Diff line number Diff line change
@@ -1,12 +1,12 @@
<?xml version="1.0" encoding="utf-8"?>
<ApplicationInsights xmlns="http://schemas.microsoft.com/ApplicationInsights/2013/Settings" schemaVersion="2014-05-30">
<!-- The key from the portal: -->
<InstrumentationKey>xxxxxx-xxxx-xxxx-xxxx-xxxxxxxxx-xxxx</InstrumentationKey>
<InstrumentationKey>${ai.instrumentKey}</InstrumentationKey>

<!-- HTTP request component (not required for bare API) -->
<TelemetryModules></TelemetryModules>

<!-- Events correlation (not required for bare API) -->
<!-- These initializers add context data to each event -->
<TelemetryInitializers></TelemetryInitializers>
</ApplicationInsights>
</ApplicationInsights>

0 comments on commit 49dd547

Please sign in to comment.