Skip to content

Commit 8f97d7e

Browse files
committed
Merge remote-tracking branch 'origin/main' into fix-odata-cud-http-response-evaluation
2 parents be88f1e + 89a1ed5 commit 8f97d7e

6 files changed

Lines changed: 22 additions & 15 deletions

File tree

codestyle/pmd.xml

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -27,7 +27,7 @@
2727
<rule ref="category/java/design.xml/AvoidThrowingRawExceptionTypes">
2828
<priority>3</priority>
2929
</rule>
30-
<rule ref="category/java/errorprone.xml/NonCaseLabelInSwitchStatement">
30+
<rule ref="category/java/errorprone.xml/NonCaseLabelInSwitch">
3131
<priority>3</priority>
3232
</rule>
3333
<rule ref="category/java/bestpractices.xml/PreserveStackTrace">

datamodel/odata-generator-utility/src/main/java/com/sap/cloud/sdk/datamodel/odata/utility/ServiceNameMappings.java

Lines changed: 10 additions & 3 deletions
Original file line numberDiff line numberDiff line change
@@ -38,18 +38,25 @@ private record Value( @Nonnull String value, @Nonnull String comment )
3838
{
3939
}
4040

41+
private ServiceNameMappings( @Nonnull final Path file )
42+
{
43+
this.file = file;
44+
}
45+
4146
/**
4247
* Creates a new instance of {@link ServiceNameMappings} with the specified file.
4348
*
4449
* @param file
4550
* the file to read and write mappings from/to
4651
*/
47-
public ServiceNameMappings( @Nonnull final Path file )
52+
@Nonnull
53+
public static ServiceNameMappings load( @Nonnull final Path file )
4854
{
49-
this.file = file;
55+
final ServiceNameMappings mappings = new ServiceNameMappings(file);
5056
if( Files.exists(file) ) {
51-
populateMappings();
57+
mappings.populateMappings();
5258
}
59+
return mappings;
5360
}
5461

5562
/**

datamodel/odata-v4/odata-v4-generator/src/main/java/com/sap/cloud/sdk/datamodel/odatav4/generator/ODataToVdmGenerator.java

Lines changed: 2 additions & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -293,7 +293,7 @@ private void cleanDirectory( final File outputDir )
293293

294294
private ServiceNameMappings loadPropertiesConfiguration( final File serviceMappingsFile )
295295
{
296-
return new ServiceNameMappings(serviceMappingsFile.toPath());
296+
return ServiceNameMappings.load(serviceMappingsFile.toPath());
297297
}
298298

299299
// Schema definitions are necessary to make the EDMX properties explorable through Olingo API at runtime, example:
@@ -334,7 +334,7 @@ static List<CsdlSchema> loadEdmxSchemas()
334334
private void storeConfiguration( final File serviceMappingsFile, final Iterable<Service> allODataServices )
335335
{
336336
ensureFileExists(serviceMappingsFile);
337-
final ServiceNameMappings mappings = new ServiceNameMappings(serviceMappingsFile.toPath());
337+
final ServiceNameMappings mappings = ServiceNameMappings.load(serviceMappingsFile.toPath());
338338

339339
for( final Service oDataService : allODataServices ) {
340340
final String javaClassNameKey = oDataService.getName() + Service.SERVICE_MAPPINGS_CLASS_SUFFIX;

datamodel/odata/odata-generator/src/main/java/com/sap/cloud/sdk/datamodel/odata/generator/ODataToVdmGenerator.java

Lines changed: 2 additions & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -288,13 +288,13 @@ private void cleanDirectory( final File outputDir )
288288

289289
private ServiceNameMappings loadPropertiesConfiguration( final File serviceMappingsFile )
290290
{
291-
return new ServiceNameMappings(serviceMappingsFile.toPath());
291+
return ServiceNameMappings.load(serviceMappingsFile.toPath());
292292
}
293293

294294
private void storeConfiguration( final File serviceMappingsFile, final Iterable<Service> allODataServices )
295295
{
296296
ensureFileExists(serviceMappingsFile);
297-
final ServiceNameMappings mappings = new ServiceNameMappings(serviceMappingsFile.toPath());
297+
final ServiceNameMappings mappings = ServiceNameMappings.load(serviceMappingsFile.toPath());
298298

299299
for( final Service oDataService : allODataServices ) {
300300
final String javaClassNameKey = oDataService.getName() + Service.SERVICE_MAPPINGS_CLASS_SUFFIX;

dependency-bundles/bom/pom.xml

Lines changed: 2 additions & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -264,13 +264,13 @@
264264
<dependency>
265265
<groupId>org.checkerframework</groupId>
266266
<artifactId>checker-qual</artifactId>
267-
<version>3.49.4</version>
267+
<version>3.49.5</version>
268268
</dependency>
269269
<!-- 2.10 by Caffeine and 2.11 by Guava -->
270270
<dependency>
271271
<groupId>com.google.errorprone</groupId>
272272
<artifactId>error_prone_annotations</artifactId>
273-
<version>2.38.0</version>
273+
<version>2.39.0</version>
274274
</dependency>
275275
</dependencies>
276276
</dependencyManagement>

pom.xml

Lines changed: 5 additions & 5 deletions
Original file line numberDiff line numberDiff line change
@@ -100,15 +100,15 @@
100100
<assertj-vavr.version>0.4.3</assertj-vavr.version>
101101
<mockito.version>5.18.0</mockito.version>
102102
<jsonassert.version>1.5.3</jsonassert.version>
103-
<junit.jupiter.version>5.13.1</junit.jupiter.version>
103+
<junit.jupiter.version>5.13.2</junit.jupiter.version>
104104
<codemodel.version>2.6</codemodel.version>
105105
<olingo-v4.version>5.0.0</olingo-v4.version>
106106
<olingo-v2.version>2.0.13</olingo-v2.version>
107107
<maven-plugin.version>3.9.10</maven-plugin.version>
108108
<maven-plugin-annotations.version>3.15.1</maven-plugin-annotations.version>
109109
<maven-plugin-testing.version>3.3.0</maven-plugin-testing.version>
110110
<caffeine.version>3.2.1</caffeine.version>
111-
<openapi-generator.version>7.13.0</openapi-generator.version>
111+
<openapi-generator.version>7.14.0</openapi-generator.version>
112112
<io-swagger-core-v3.version>2.2.34</io-swagger-core-v3.version>
113113
<io-swagger-parser-v3.version>2.1.30</io-swagger-parser-v3.version>
114114
<io-swagger-core.version>1.6.11</io-swagger-core.version>
@@ -118,7 +118,7 @@
118118
<jakarta-activation.version>2.1.0</jakarta-activation.version>
119119
<qdox.version>2.2.0</qdox.version>
120120
<wiremock.version>3.13.1</wiremock.version>
121-
<checkstyle.version>10.25.1</checkstyle.version>
121+
<checkstyle.version>10.26.1</checkstyle.version>
122122
<byte-buddy.version>1.17.6</byte-buddy.version>
123123
<snakeyaml.version>2.4</snakeyaml.version>
124124
<commons-codec.version>1.18.0</commons-codec.version>
@@ -899,7 +899,7 @@
899899
<plugin>
900900
<groupId>com.github.spotbugs</groupId>
901901
<artifactId>spotbugs-maven-plugin</artifactId>
902-
<version>4.9.3.0</version>
902+
<version>4.9.3.2</version>
903903
<configuration>
904904
<includeFilterFile>${project.rootdir}/codestyle/findbugs.xml</includeFilterFile>
905905
<excludeFilterFile>${project.rootdir}/codestyle/spotbugs-exclusions.xml</excludeFilterFile>
@@ -911,7 +911,7 @@
911911
<plugin>
912912
<groupId>org.apache.maven.plugins</groupId>
913913
<artifactId>maven-pmd-plugin</artifactId>
914-
<version>3.26.0</version>
914+
<version>3.27.0</version>
915915
<configuration>
916916
<rulesets>
917917
<ruleset>${project.rootdir}/codestyle/pmd.xml</ruleset>

0 commit comments

Comments
 (0)