Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

upgrade to gridsuite dependencies 36 #123

Merged
merged 5 commits into from
Jan 15, 2025
Merged
Show file tree
Hide file tree
Changes from all commits
Commits
File filter

Filter by extension

Filter by extension


Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view
7 changes: 1 addition & 6 deletions pom.xml
Original file line number Diff line number Diff line change
Expand Up @@ -42,7 +42,7 @@
</developers>

<properties>
<gridsuite-dependencies.version>35</gridsuite-dependencies.version>
<gridsuite-dependencies.version>36</gridsuite-dependencies.version>
<liquibase-hibernate-package>org.gridsuite.shortcircuit.server</liquibase-hibernate-package>
<db-util.version>1.0.5</db-util.version>
</properties>
Expand Down Expand Up @@ -84,11 +84,6 @@
<dependencyManagement>
<dependencies>
<!-- overrides of imports -->
<dependency><!-- To remove when integrate in next release of gridsuite-dependencies or powsybl-ws-dependencies -->
<groupId>com.powsybl</groupId>
<artifactId>powsybl-ws-commons</artifactId>
<version>1.19.0</version>
</dependency>
<!-- imports -->
<dependency>
<groupId>org.gridsuite</groupId>
Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -73,7 +73,9 @@ public UUID runAndSaveResult(UUID networkUuid, String variantId, String receiver
ShortCircuitParameters parameters = fromEntity(parametersUuid.flatMap(parametersRepository::findById).orElseGet(ShortCircuitParametersEntity::new)).parameters();
parameters.setWithFortescueResult(StringUtils.isNotBlank(busId));
parameters.setDetailedReport(false);
return runAndSaveResult(new ShortCircuitRunContext(networkUuid, variantId, receiver, parameters, reportUuid, reporterId, reportType, userId, null, busId));
return runAndSaveResult(new ShortCircuitRunContext(networkUuid, variantId, receiver, parameters, reportUuid, reporterId, reportType, userId,
"default-provider", // TODO : replace with null when fix in powsybl-ws-commons will handle null provider
busId));
}

@Override
Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -152,6 +152,8 @@ private void runAnalysisTest(final Consumer<MockHttpServletRequestBuilder> reque
MessageHeaders.ID, UUID.randomUUID(),
MessageHeaders.TIMESTAMP, System.currentTimeMillis(),
"resultUuid", resultId,
// TODO : remove next line when fix in powsybl-ws-commons will handle null provider
"provider", "default-provider",
"networkUuid", NETWORK_ID.toString(),
HEADER_USER_ID, USER_ID
))).build()));
Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -51,7 +51,7 @@ private TestUtils() {
null,
null,
null,
null,
"default-provider", // TODO : replace with null when fix in powsybl-ws-commons will handle null provider
null
);

Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -33,7 +33,7 @@ static void prepare() throws IOException {
@Test
void testAggregatedLogs() throws Exception {
ShortCircuitRunContext runContext = new ShortCircuitRunContext(null, "variantId", "receiver", new ShortCircuitParameters(),
null, "reporterId", "reportType", "userId", "provider", "busId");
null, "reporterId", "reportType", "userId", "default-provider", "busId");
runContext.setVoltageLevelsWithWrongIsc(Collections.singletonList("VL1"));
final ReportNode result = reportMapper.processReporter(rootReportNode, runContext);
log.debug("Result = {}", RestTemplateConfig.objectMapper().writerWithDefaultPrettyPrinter().writeValueAsString(result));
Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -106,7 +106,8 @@ void testLogsMappersIsCalled() throws Exception {
final String reporterId = "44444444-4444-4444-4444-444444444444";
final ShortCircuitRunContext runContext = new ShortCircuitRunContext(networkUuid, null, null,
new ShortCircuitParameters(), reportUuid, reporterId, "AllBusesShortCircuitAnalysis", null,
null, null);
"default-provider", // TODO : replace with null when fix in powsybl-ws-commons will handle null provider
null);
final ShortCircuitResultContext resultContext = new ShortCircuitResultContext(resultUuid, runContext);
final Network.BusView busViewMocked = Mockito.mock(Network.BusView.class);
ReportNode reportNode = ReportNode.newRootReportNode().withMessageTemplate("test", "test").build();
Expand Down
Loading