Skip to content

Commit

Permalink
Update data format to push to customEvents table (#35682)
Browse files Browse the repository at this point in the history
* Update data format to push to customEvents table
  • Loading branch information
srnagar authored Jul 21, 2023
1 parent 37dd719 commit 4c3ae20
Show file tree
Hide file tree
Showing 53 changed files with 2,335 additions and 504 deletions.
1 change: 1 addition & 0 deletions eng/.docsettings.yml
Original file line number Diff line number Diff line change
Expand Up @@ -15,6 +15,7 @@ omitted_paths:
- "*/resource-manager/*"
- "sdk/*/mgmt-*/*"
- "sdk/*/swagger/*"
- "sdk/*/codegen/*"
- doc/*
- eng/*
- common/smoke-tests/*
Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -575,4 +575,10 @@ the main ServiceBusClientBuilder. -->
<suppress checks="MissingJavadocType" files="com.azure.core.test.http.HttpClientTests"/>
<suppress checks="JavadocThrowsChecks" files="com.azure.core.test.http.HttpClientTests"/>

<!-- The build tool plugin checkstyle exceptions -->
<suppress checks="com.azure.tools.checkstyle.checks.ExternalDependencyExposedCheck"
files="com.azure.sdk.build.tool.*\.java"/>
<suppress checks="com.azure.tools.checkstyle.checks.GoodLoggingCheck" files="ConsoleLogger.java"/>
<suppress checks="com.azure.tools.checkstyle.checks.ThrowFromClientLoggerCheck"
files="com.azure.sdk.build.tool.*\.java"/>
</suppressions>
Original file line number Diff line number Diff line change
Expand Up @@ -2655,4 +2655,25 @@
<Bug pattern="URF_UNREAD_FIELD"/>
</Match>

<!-- Build tool suppressions -->
<Match>
<Class name="com.azure.sdk.build.tool.ReportGenerator"/>
<Bug pattern="DM_DEFAULT_ENCODING"/>
</Match>
<Match>
<Class name="com.azure.sdk.build.tool.mojo.AzureSdkMojo"/>
<Field name="mojo"/>
<Bug pattern="ST_WRITE_TO_STATIC_FROM_INSTANCE_METHOD"/>
</Match>

<Match>
<Class name="com.azure.sdk.build.tool.util.logging.ConsoleLogger"/>
<Field name="instance"/>
<Bug pattern="LI_LAZY_INIT_STATIC"/>
</Match>
<Match>
<Class name="com.azure.sdk.build.tool.util.logging.MojoLogger"/>
<Field name="instance"/>
<Bug pattern="LI_LAZY_INIT_STATIC"/>
</Match>
</FindBugsFilter>
2 changes: 1 addition & 1 deletion eng/versioning/external_dependencies.txt
Original file line number Diff line number Diff line change
Expand Up @@ -87,7 +87,7 @@ org.apache.logging.log4j:log4j-core;2.17.2
org.apache.logging.log4j:log4j-slf4j-impl;2.17.2
org.apache.maven:maven-core;3.5.4
org.apache.maven.archetype:archetype-packaging;3.2.0
org.apache.maven.archetype:maven-archetype-plugin;3.2.0
org.apache.maven.plugins:maven-archetype-plugin;3.2.0
org.apache.qpid:proton-j;0.33.8
org.apache.qpid:qpid-jms-client;0.53.0
org.apache.tinkerpop:gremlin-driver;3.2.4
Expand Down
2 changes: 1 addition & 1 deletion eng/versioning/version_client.txt
Original file line number Diff line number Diff line change
Expand Up @@ -422,7 +422,7 @@ com.azure.resourcemanager:azure-resourcemanager-iotfirmwaredefense;1.0.0-beta.1;
com.azure.resourcemanager:azure-resourcemanager-quantum;1.0.0-beta.1;1.0.0-beta.2
com.azure.resourcemanager:azure-resourcemanager-sphere;1.0.0-beta.1;1.0.0-beta.2
com.azure.tools:azure-sdk-archetype;1.0.0;1.2.0-beta.1
com.azure.tools:azure-sdk-build-tool;1.0.0-beta.1;1.0.0-beta.2
com.azure.tools:azure-sdk-build-tool;1.0.0-beta.1;1.0.0

# Unreleased dependencies: Copy the entry from above, prepend "unreleased_" and remove the current
# version. Unreleased dependencies are only valid for dependency versions.
Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -472,7 +472,7 @@ private void addSanitizers() {
*
* @param sanitizers the test proxy sanitizers.
*/
protected void addSanitizers(TestProxySanitizer ...sanitizers) {
protected void addSanitizers(TestProxySanitizer... sanitizers) {
this.sanitizers.addAll(Arrays.asList(sanitizers));
}

Expand Down
130 changes: 128 additions & 2 deletions sdk/tools/azure-sdk-archetype/pom.xml
Original file line number Diff line number Diff line change
Expand Up @@ -61,9 +61,9 @@
<pluginManagement>
<plugins>
<plugin>
<groupId>org.apache.maven.archetype</groupId>
<groupId>org.apache.maven.plugins</groupId>
<artifactId>maven-archetype-plugin</artifactId>
<version>3.2.0</version> <!-- {x-version-update;org.apache.maven.archetype:maven-archetype-plugin;external_dependency} -->
<version>3.2.0</version> <!-- {x-version-update;org.apache.maven.plugins:maven-archetype-plugin;external_dependency} -->
</plugin>
</plugins>
</pluginManagement>
Expand Down Expand Up @@ -171,6 +171,132 @@
</executions>
</plugin>
<!-- END: Empty Java Doc -->

<!-- TODO: Move the following plugins to a parent pom -->
<!-- This plugin scans checkstyle issues in the code -->
<plugin>
<groupId>org.apache.maven.plugins</groupId>
<artifactId>maven-checkstyle-plugin</artifactId>
<version>3.1.2</version> <!-- {x-version-update;org.apache.maven.plugins:maven-checkstyle-plugin;external_dependency} -->
<dependencies>
<dependency>
<groupId>com.azure</groupId>
<artifactId>sdk-build-tools</artifactId>
<version>1.0.0</version> <!-- {x-version-update;com.azure:sdk-build-tools;external_dependency} -->
</dependency>
<dependency>
<groupId>com.puppycrawl.tools</groupId>
<artifactId>checkstyle</artifactId>
<version>9.3</version> <!-- {x-version-update;com.puppycrawl.tools:checkstyle;external_dependency} -->
</dependency>
</dependencies>
</plugin>
<!-- This plugin scans reports spotbugs in the code -->
<plugin>
<groupId>com.github.spotbugs</groupId>
<artifactId>spotbugs-maven-plugin</artifactId>
<version>4.2.2</version> <!-- {x-version-update;com.github.spotbugs:spotbugs-maven-plugin;external_dependency} -->
<dependencies>
<dependency>
<groupId>com.azure</groupId>
<artifactId>sdk-build-tools</artifactId>
<version>1.0.0</version> <!-- {x-version-update;com.azure:sdk-build-tools;external_dependency} -->
</dependency>
<dependency>
<groupId>com.github.spotbugs</groupId>
<artifactId>spotbugs</artifactId>
<version>4.2.2</version> <!-- {x-version-update;com.github.spotbugs:spotbugs;external_dependency} -->
</dependency>
<!-- Needed as the version of Spotbugs being used isn't compatible is Java 18+ without this. -->
<dependency>
<groupId>org.ow2.asm</groupId>
<artifactId>asm</artifactId>
<version>9.5</version> <!-- {x-version-update;org.ow2.asm:asm;external_dependency} -->
</dependency>
</dependencies>
<configuration>
<effort>max</effort>
<threshold>Low</threshold>
<xmlOutput>true</xmlOutput>
<spotbugsXmlOutputDirectory>${project.build.directory}/spotbugs</spotbugsXmlOutputDirectory>
<excludeFilterFile>spotbugs/spotbugs-exclude.xml</excludeFilterFile>
<fork>true</fork>
</configuration>
</plugin>

<!-- Checks public surface area for breaking changes. -->
<plugin>
<groupId>org.revapi</groupId>
<artifactId>revapi-maven-plugin</artifactId>
<version>0.14.6</version> <!-- {x-version-update;org.revapi:revapi-maven-plugin;external_dependency} -->
<configuration>
<convertAnalysisConfigurationFiles>true</convertAnalysisConfigurationFiles>
<analysisConfigurationFiles>
<configurationFile>
<resource>revapi/revapi.json</resource>
</configurationFile>
</analysisConfigurationFiles>
<versionFormat>^\d+\.\d+\.\d+$</versionFormat>
<checkDependencies>true</checkDependencies>
<!-- The following configures reporting to file in addition to CLI reporting. -->
<analysisConfiguration>
<revapi.reporter.json id="file-report">
<minSeverity>NON_BREAKING</minSeverity>
<minCriticality>error</minCriticality>
<indent>true</indent>
<output>${project.build.directory}/revapi.json</output>
<keepEmptyFile>false</keepEmptyFile>
</revapi.reporter.json>
</analysisConfiguration>
<pipelineConfiguration>
<filters>
<include>
<item>azure-sdk-tree-provider</item>
</include>
</filters>
</pipelineConfiguration>
</configuration>
<dependencies>
<dependency>
<groupId>com.azure</groupId>
<artifactId>sdk-build-tools</artifactId>
<version>1.0.0</version> <!-- {x-version-update;com.azure:sdk-build-tools;external_dependency} -->
</dependency>
<dependency>
<groupId>org.revapi</groupId>
<artifactId>revapi-java</artifactId>
<version>0.26.1</version> <!-- {x-version-update;org.revapi:revapi-java;external_dependency} -->
</dependency>
<dependency>
<groupId>org.revapi</groupId>
<artifactId>revapi-reporter-json</artifactId>
<version>0.4.5</version> <!-- {x-version-update;org.revapi:revapi-reporter-json;external_dependency} -->
</dependency>
</dependencies>
</plugin>
<plugin>
<groupId>com.azure.tools</groupId>
<artifactId>codesnippet-maven-plugin</artifactId>
<version>1.0.0-beta.8</version> <!-- {x-version-update;com.azure.tools:codesnippet-maven-plugin;external_dependency} -->
<configuration>
<readmeGlob>**/*.md</readmeGlob>
</configuration>
<executions>
<execution>
<id>update-codesnippets</id>
<goals>
<goal>update-codesnippet</goal>
</goals>
</execution>
<execution>
<id>verify-codesnippets</id>
<goals>
<goal>verify-codesnippet</goal>
</goals>
</execution>
</executions>
</plugin>

</plugins>
</build>
</project>
9 changes: 3 additions & 6 deletions sdk/tools/azure-sdk-build-tool/CHANGELOG.md
Original file line number Diff line number Diff line change
@@ -1,14 +1,11 @@
# Release History

## 1.0.0-beta.2 (Unreleased)
## 1.0.0 (2023-07-20)

### Features Added

### Breaking Changes

### Bugs Fixed

### Other Changes
- Enabled sending telemetry to Azure Application Insights.
- Added frequency to track the number of times a service method call is made.

## 1.0.0-beta.1 (2022-02-28)

Expand Down
15 changes: 15 additions & 0 deletions sdk/tools/azure-sdk-build-tool/codegen/README.md
Original file line number Diff line number Diff line change
@@ -0,0 +1,15 @@
``` yaml
input-file: https://raw.githubusercontent.com/Azure/azure-rest-api-specs/master/specification/applicationinsights/data-plane/Monitor.Exporters/preview/v2.1/swagger.json
java: true
output-folder: ../
namespace: com.azure.sdk.build.tool.implementation
generate-client-interfaces: false
service-interface-as-public: true
license-header: MICROSOFT_MIT_SMALL
add-context-parameter: true
context-client-method-parameter: true
directive:
- rename-model:
from: TrackResponse
to: ExportResult
```
Loading

0 comments on commit 4c3ae20

Please sign in to comment.