Skip to content

Commit 4343800

Browse files
Merge pull request #212399 from heyams/heya/3.4.1
Update java to 3.4.1
2 parents 097daba + 57791ad commit 4343800

File tree

6 files changed

+46
-46
lines changed

6 files changed

+46
-46
lines changed

articles/azure-monitor/app/java-in-process-agent.md

Lines changed: 3 additions & 3 deletions
Original file line numberDiff line numberDiff line change
@@ -30,7 +30,7 @@ This section shows you how to download the auto-instrumentation jar file.
3030

3131
#### Download the jar file
3232

33-
Download the [applicationinsights-agent-3.4.0.jar](https://github.com/microsoft/ApplicationInsights-Java/releases/download/3.4.0/applicationinsights-agent-3.4.0.jar) file.
33+
Download the [applicationinsights-agent-3.4.1.jar](https://github.com/microsoft/ApplicationInsights-Java/releases/download/3.4.1/applicationinsights-agent-3.4.1.jar) file.
3434

3535
> [!WARNING]
3636
>
@@ -62,7 +62,7 @@ Download the [applicationinsights-agent-3.4.0.jar](https://github.com/microsoft/
6262

6363
#### Point the JVM to the jar file
6464

65-
Add `-javaagent:"path/to/applicationinsights-agent-3.4.0.jar"` to your application's JVM args.
65+
Add `-javaagent:"path/to/applicationinsights-agent-3.4.1.jar"` to your application's JVM args.
6666

6767
> [!TIP]
6868
> For help with configuring your application's JVM args, see [Tips for updating your JVM args](./java-standalone-arguments.md).
@@ -80,7 +80,7 @@ Add `-javaagent:"path/to/applicationinsights-agent-3.4.0.jar"` to your applicati
8080
APPLICATIONINSIGHTS_CONNECTION_STRING=<Copy connection string from Application Insights Resource Overview>
8181
```
8282

83-
- Or you can create a configuration file named `applicationinsights.json`. Place it in the same directory as `applicationinsights-agent-3.4.0.jar` with the following content:
83+
- Or you can create a configuration file named `applicationinsights.json`. Place it in the same directory as `applicationinsights-agent-3.4.1.jar` with the following content:
8484

8585
```json
8686
{

articles/azure-monitor/app/java-spring-boot.md

Lines changed: 7 additions & 7 deletions
Original file line numberDiff line numberDiff line change
@@ -15,24 +15,24 @@ You can enable the Azure Monitor Application Insights agent for Java by adding a
1515

1616
### Usual case
1717

18-
Add the JVM arg `-javaagent:"path/to/applicationinsights-agent-3.4.0.jar"` somewhere before `-jar`, for example:
18+
Add the JVM arg `-javaagent:"path/to/applicationinsights-agent-3.4.1.jar"` somewhere before `-jar`, for example:
1919

2020
```
21-
java -javaagent:"path/to/applicationinsights-agent-3.4.0.jar" -jar <myapp.jar>
21+
java -javaagent:"path/to/applicationinsights-agent-3.4.1.jar" -jar <myapp.jar>
2222
```
2323

2424
### Spring Boot via Docker entry point
2525

26-
If you're using the *exec* form, add the parameter `-javaagent:"path/to/applicationinsights-agent-3.4.0.jar"` to the parameter list somewhere before the `"-jar"` parameter, for example:
26+
If you're using the *exec* form, add the parameter `-javaagent:"path/to/applicationinsights-agent-3.4.1.jar"` to the parameter list somewhere before the `"-jar"` parameter, for example:
2727

2828
```
29-
ENTRYPOINT ["java", "-javaagent:path/to/applicationinsights-agent-3.4.0.jar", "-jar", "<myapp.jar>"]
29+
ENTRYPOINT ["java", "-javaagent:path/to/applicationinsights-agent-3.4.1.jar", "-jar", "<myapp.jar>"]
3030
```
3131

32-
If you're using the *shell* form, add the JVM arg `-javaagent:"path/to/applicationinsights-agent-3.4.0.jar"` somewhere before `-jar`, for example:
32+
If you're using the *shell* form, add the JVM arg `-javaagent:"path/to/applicationinsights-agent-3.4.1.jar"` somewhere before `-jar`, for example:
3333

3434
```
35-
ENTRYPOINT java -javaagent:"path/to/applicationinsights-agent-3.4.0.jar" -jar <myapp.jar>
35+
ENTRYPOINT java -javaagent:"path/to/applicationinsights-agent-3.4.1.jar" -jar <myapp.jar>
3636
```
3737

3838
## Programmatic configuration
@@ -42,7 +42,7 @@ To use the programmatic configuration and attach the Application Insights agent
4242
<dependency>
4343
<groupId>com.microsoft.azure</groupId>
4444
<artifactId>applicationinsights-runtime-attach</artifactId>
45-
<version>3.4.0</version>
45+
<version>3.4.1</version>
4646
</dependency>
4747
```
4848

articles/azure-monitor/app/java-standalone-arguments.md

Lines changed: 16 additions & 16 deletions
Original file line numberDiff line numberDiff line change
@@ -25,18 +25,18 @@ Read the Spring Boot documentation [here](../app/java-in-process-agent.md).
2525
If you installed Tomcat via `apt-get` or `yum`, then you should have a file `/etc/tomcat8/tomcat8.conf`. Add this line to the end of that file:
2626

2727
```
28-
JAVA_OPTS="$JAVA_OPTS -javaagent:path/to/applicationinsights-agent-3.4.0.jar"
28+
JAVA_OPTS="$JAVA_OPTS -javaagent:path/to/applicationinsights-agent-3.4.1.jar"
2929
```
3030

3131
### Tomcat installed via download and unzip
3232

3333
If you installed Tomcat via download and unzip from [https://tomcat.apache.org](https://tomcat.apache.org), then you should have a file `<tomcat>/bin/catalina.sh`. Create a new file in the same directory named `<tomcat>/bin/setenv.sh` with the following content:
3434

3535
```
36-
CATALINA_OPTS="$CATALINA_OPTS -javaagent:path/to/applicationinsights-agent-3.4.0.jar"
36+
CATALINA_OPTS="$CATALINA_OPTS -javaagent:path/to/applicationinsights-agent-3.4.1.jar"
3737
```
3838

39-
If the file `<tomcat>/bin/setenv.sh` already exists, then modify that file and add `-javaagent:path/to/applicationinsights-agent-3.4.0.jar` to `CATALINA_OPTS`.
39+
If the file `<tomcat>/bin/setenv.sh` already exists, then modify that file and add `-javaagent:path/to/applicationinsights-agent-3.4.1.jar` to `CATALINA_OPTS`.
4040

4141

4242
## Tomcat 8 (Windows)
@@ -46,36 +46,36 @@ If the file `<tomcat>/bin/setenv.sh` already exists, then modify that file and a
4646
Locate the file `<tomcat>/bin/catalina.bat`. Create a new file in the same directory named `<tomcat>/bin/setenv.bat` with the following content:
4747

4848
```
49-
set CATALINA_OPTS=%CATALINA_OPTS% -javaagent:path/to/applicationinsights-agent-3.4.0.jar
49+
set CATALINA_OPTS=%CATALINA_OPTS% -javaagent:path/to/applicationinsights-agent-3.4.1.jar
5050
```
5151

5252
Quotes aren't necessary, but if you want to include them, the proper placement is:
5353

5454
```
55-
set "CATALINA_OPTS=%CATALINA_OPTS% -javaagent:path/to/applicationinsights-agent-3.4.0.jar"
55+
set "CATALINA_OPTS=%CATALINA_OPTS% -javaagent:path/to/applicationinsights-agent-3.4.1.jar"
5656
```
5757

58-
If the file `<tomcat>/bin/setenv.bat` already exists, just modify that file and add `-javaagent:path/to/applicationinsights-agent-3.4.0.jar` to `CATALINA_OPTS`.
58+
If the file `<tomcat>/bin/setenv.bat` already exists, just modify that file and add `-javaagent:path/to/applicationinsights-agent-3.4.1.jar` to `CATALINA_OPTS`.
5959

6060
### Running Tomcat as a Windows service
6161

62-
Locate the file `<tomcat>/bin/tomcat8w.exe`. Run that executable and add `-javaagent:path/to/applicationinsights-agent-3.4.0.jar` to the `Java Options` under the `Java` tab.
62+
Locate the file `<tomcat>/bin/tomcat8w.exe`. Run that executable and add `-javaagent:path/to/applicationinsights-agent-3.4.1.jar` to the `Java Options` under the `Java` tab.
6363

6464

6565
## JBoss EAP 7
6666

6767
### Standalone server
6868

69-
Add `-javaagent:path/to/applicationinsights-agent-3.4.0.jar` to the existing `JAVA_OPTS` environment variable in the file `JBOSS_HOME/bin/standalone.conf` (Linux) or `JBOSS_HOME/bin/standalone.conf.bat` (Windows):
69+
Add `-javaagent:path/to/applicationinsights-agent-3.4.1.jar` to the existing `JAVA_OPTS` environment variable in the file `JBOSS_HOME/bin/standalone.conf` (Linux) or `JBOSS_HOME/bin/standalone.conf.bat` (Windows):
7070

7171
```java ...
72-
JAVA_OPTS="-javaagent:path/to/applicationinsights-agent-3.4.0.jar -Xms1303m -Xmx1303m ..."
72+
JAVA_OPTS="-javaagent:path/to/applicationinsights-agent-3.4.1.jar -Xms1303m -Xmx1303m ..."
7373
...
7474
```
7575

7676
### Domain server
7777

78-
Add `-javaagent:path/to/applicationinsights-agent-3.4.0.jar` to the existing `jvm-options` in `JBOSS_HOME/domain/configuration/host.xml`:
78+
Add `-javaagent:path/to/applicationinsights-agent-3.4.1.jar` to the existing `jvm-options` in `JBOSS_HOME/domain/configuration/host.xml`:
7979

8080
```xml
8181
...
@@ -85,7 +85,7 @@ Add `-javaagent:path/to/applicationinsights-agent-3.4.0.jar` to the existing `jv
8585
<jvm-options>
8686
<option value="-server"/>
8787
<!--Add Java agent jar file here-->
88-
<option value="-javaagent:path/to/applicationinsights-agent-3.4.0.jar"/>
88+
<option value="-javaagent:path/to/applicationinsights-agent-3.4.1.jar"/>
8989
<option value="-XX:MetaspaceSize=96m"/>
9090
<option value="-XX:MaxMetaspaceSize=256m"/>
9191
</jvm-options>
@@ -125,20 +125,20 @@ Add these lines to `start.ini`
125125

126126
```
127127
--exec
128-
-javaagent:path/to/applicationinsights-agent-3.4.0.jar
128+
-javaagent:path/to/applicationinsights-agent-3.4.1.jar
129129
```
130130

131131

132132
## Payara 5
133133

134-
Add `-javaagent:path/to/applicationinsights-agent-3.4.0.jar` to the existing `jvm-options` in `glassfish/domains/domain1/config/domain.xml`:
134+
Add `-javaagent:path/to/applicationinsights-agent-3.4.1.jar` to the existing `jvm-options` in `glassfish/domains/domain1/config/domain.xml`:
135135

136136
```xml
137137
...
138138
<java-config ...>
139139
<!--Edit the JVM options here-->
140140
<jvm-options>
141-
-javaagent:path/to/applicationinsights-agent-3.4.0.jar>
141+
-javaagent:path/to/applicationinsights-agent-3.4.1.jar>
142142
</jvm-options>
143143
...
144144
</java-config>
@@ -155,7 +155,7 @@ Java and Process Management > Process definition > Java Virtual Machine
155155
```
156156
In "Generic JVM arguments" add the following JVM argument:
157157
```
158-
-javaagent:path/to/applicationinsights-agent-3.4.0.jar
158+
-javaagent:path/to/applicationinsights-agent-3.4.1.jar
159159
```
160160
After that, save and restart the application server.
161161

@@ -164,7 +164,7 @@ After that, save and restart the application server.
164164

165165
Create a new file `jvm.options` in the server directory (for example `<openliberty>/usr/servers/defaultServer`), and add this line:
166166
```
167-
-javaagent:path/to/applicationinsights-agent-3.4.0.jar
167+
-javaagent:path/to/applicationinsights-agent-3.4.1.jar
168168
```
169169

170170
## Others

articles/azure-monitor/app/java-standalone-config.md

Lines changed: 9 additions & 9 deletions
Original file line numberDiff line numberDiff line change
@@ -32,14 +32,14 @@ You will find more details and additional configuration options below.
3232

3333
## Configuration file path
3434

35-
By default, Application Insights Java 3.x expects the configuration file to be named `applicationinsights.json`, and to be located in the same directory as `applicationinsights-agent-3.4.0.jar`.
35+
By default, Application Insights Java 3.x expects the configuration file to be named `applicationinsights.json`, and to be located in the same directory as `applicationinsights-agent-3.4.1.jar`.
3636

3737
You can specify your own configuration file path using either
3838

3939
* `APPLICATIONINSIGHTS_CONFIGURATION_FILE` environment variable, or
4040
* `applicationinsights.configuration.file` Java system property
4141

42-
If you specify a relative path, it will be resolved relative to the directory where `applicationinsights-agent-3.4.0.jar` is located.
42+
If you specify a relative path, it will be resolved relative to the directory where `applicationinsights-agent-3.4.1.jar` is located.
4343

4444
Alternatively, instead of using a configuration file, you can specify the entire _content_ of the json configuration
4545
via the environment variable `APPLICATIONINSIGHTS_CONFIGURATION_CONTENT`.
@@ -62,7 +62,7 @@ You can also set the connection string using the environment variable `APPLICATI
6262

6363
You can also set the connection string by specifying a file to load the connection string from.
6464

65-
If you specify a relative path, it will be resolved relative to the directory where `applicationinsights-agent-3.4.0.jar` is located.
65+
If you specify a relative path, it will be resolved relative to the directory where `applicationinsights-agent-3.4.1.jar` is located.
6666

6767
```json
6868
{
@@ -140,7 +140,7 @@ Furthermore, sampling is trace ID based, to help ensure consistent sampling deci
140140

141141
### Rate-Limited Sampling
142142

143-
Starting from 3.4.0, rate-limited sampling is available, and is now the default.
143+
Starting from 3.4.1, rate-limited sampling is available, and is now the default.
144144

145145
If no sampling has been configured, the default is now rate-limited sampling configured to capture at most
146146
(approximately) 5 requests per second, along with all the dependencies and logs on those requests.
@@ -268,7 +268,7 @@ Starting from version 3.2.0, if you want to set a custom dimension programmatica
268268

269269
## Connection string overrides (preview)
270270

271-
This feature is in preview, starting from 3.4.0.
271+
This feature is in preview, starting from 3.4.1.
272272

273273
Connection string overrides allow you to override the [default connection string](#connection-string), for example:
274274
* Set one connection string for one http path prefix `/myapp1`.
@@ -437,7 +437,7 @@ You can enable code properties (_FileName_, _ClassName_, _MethodName_, _LineNumb
437437
>
438438
> This feature could add a performance overhead.
439439
440-
This feature is in preview, starting from 3.4.0.
440+
This feature is in preview, starting from 3.4.1.
441441

442442
### LoggingLevel
443443

@@ -483,7 +483,7 @@ To disable auto-collection of Micrometer metrics (including Spring Boot Actuator
483483

484484
Literal values in JDBC queries are masked by default in order to avoid accidentally capturing sensitive data.
485485

486-
Starting from 3.4.0, this behavior can be disabled if desired, e.g.
486+
Starting from 3.4.1, this behavior can be disabled if desired, e.g.
487487

488488
```json
489489
{
@@ -501,7 +501,7 @@ Starting from 3.4.0, this behavior can be disabled if desired, e.g.
501501

502502
Literal values in Mongo queries are masked by default in order to avoid accidentally capturing sensitive data.
503503

504-
Starting from 3.4.0, this behavior can be disabled if desired, e.g.
504+
Starting from 3.4.1, this behavior can be disabled if desired, e.g.
505505

506506
```json
507507
{
@@ -776,7 +776,7 @@ and the console, corresponding to this configuration:
776776
`level` can be one of `OFF`, `ERROR`, `WARN`, `INFO`, `DEBUG`, or `TRACE`.
777777

778778
`path` can be an absolute or relative path. Relative paths are resolved against the directory where
779-
`applicationinsights-agent-3.4.0.jar` is located.
779+
`applicationinsights-agent-3.4.1.jar` is located.
780780

781781
`maxSizeMb` is the max size of the log file before it rolls over.
782782

articles/azure-monitor/app/java-standalone-sampling-overrides.md

Lines changed: 6 additions & 6 deletions
Original file line numberDiff line numberDiff line change
@@ -48,14 +48,14 @@ To begin, create a configuration file named *applicationinsights.json*. Save it
4848
"sampling": {
4949
"overrides": [
5050
{
51-
"telemetryKind": "request",
51+
"telemetryType": "request",
5252
"attributes": [
5353
...
5454
],
5555
"percentage": 0
5656
},
5757
{
58-
"telemetryKind": "request",
58+
"telemetryType": "request",
5959
"attributes": [
6060
...
6161
],
@@ -69,7 +69,7 @@ To begin, create a configuration file named *applicationinsights.json*. Save it
6969

7070
## How it works
7171

72-
`telemetryKind` must be one of `request`, `dependency`, `trace` (log), or `exception`.
72+
`telemetryType` must be one of `request`, `dependency`, `trace` (log), or `exception`.
7373

7474
When a span is started, the type of span and the attributes present on it at that time are used to check if any of the sampling
7575
overrides match.
@@ -104,7 +104,7 @@ This will also suppress collecting any downstream spans (dependencies) that woul
104104
"sampling": {
105105
"overrides": [
106106
{
107-
"telemetryKind": "request",
107+
"telemetryType": "request",
108108
"attributes": [
109109
{
110110
"key": "http.url",
@@ -131,7 +131,7 @@ This will suppress collecting telemetry for all `GET my-noisy-key` redis calls.
131131
"sampling": {
132132
"overrides": [
133133
{
134-
"telemetryKind": "dependency",
134+
"telemetryType": "dependency",
135135
"attributes": [
136136
{
137137
"key": "db.system",
@@ -170,7 +170,7 @@ those will also be collected for all '/login' requests.
170170
"sampling": {
171171
"overrides": [
172172
{
173-
"telemetryKind": "request",
173+
"telemetryType": "request",
174174
"attributes": [
175175
{
176176
"key": "http.url",

articles/azure-monitor/app/java-standalone-upgrade-from-2x.md

Lines changed: 5 additions & 5 deletions
Original file line numberDiff line numberDiff line change
@@ -19,20 +19,20 @@ auto-instrumentation which is provided by the 3.x Java agent.
1919

2020
| 2.x dependency | Action | Remarks |
2121
|----------------|--------|---------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------|
22-
| `applicationinsights-core` | Update the version to `3.4.0` or later | |
23-
| `applicationinsights-web` | Update the version to `3.4.0` or later, and remove the Application Insights web filter your `web.xml` file. | |
24-
| `applicationinsights-web-auto` | Replace with `3.4.0` or later of `applicationinsights-web` | |
22+
| `applicationinsights-core` | Update the version to `3.4.1` or later | |
23+
| `applicationinsights-web` | Update the version to `3.4.1` or later, and remove the Application Insights web filter your `web.xml` file. | |
24+
| `applicationinsights-web-auto` | Replace with `3.4.1` or later of `applicationinsights-web` | |
2525
| `applicationinsights-logging-log4j1_2` | Remove the dependency and remove the Application Insights appender from your log4j configuration. | No longer needed since Log4j 1.2 is auto-instrumented in the 3.x Java agent. |
2626
| `applicationinsights-logging-log4j2` | Remove the dependency and remove the Application Insights appender from your log4j configuration. | No longer needed since Log4j 2 is auto-instrumented in the 3.x Java agent. |
2727
| `applicationinsights-logging-log4j1_2` | Remove the dependency and remove the Application Insights appender from your logback configuration. | No longer needed since Logback is auto-instrumented in the 3.x Java agent. |
28-
| `applicationinsights-spring-boot-starter` | Replace with `3.4.0` or later of `applicationinsights-web` | The cloud role name will no longer default to `spring.application.name`, see the [3.x configuration docs](./java-standalone-config.md#cloud-role-name) for configuring the cloud role name. |
28+
| `applicationinsights-spring-boot-starter` | Replace with `3.4.1` or later of `applicationinsights-web` | The cloud role name will no longer default to `spring.application.name`, see the [3.x configuration docs](./java-standalone-config.md#cloud-role-name) for configuring the cloud role name. |
2929

3030
## Step 2: Add the 3.x Java agent
3131

3232
Add the 3.x Java agent to your JVM command-line args, for example
3333

3434
```
35-
-javaagent:path/to/applicationinsights-agent-3.4.0.jar
35+
-javaagent:path/to/applicationinsights-agent-3.4.1.jar
3636
```
3737

3838
If you were using the Application Insights 2.x Java agent, just replace your existing `-javaagent:...` with the above.

0 commit comments

Comments
 (0)