-
Notifications
You must be signed in to change notification settings - Fork 6
Complete persistent iidm implementation #163
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
Conversation
Signed-off-by: Slimane AMAR <[email protected]>
Signed-off-by: Slimane AMAR <[email protected]>
…rminals (#162) Signed-off-by: Slimane AMAR <[email protected]>
Signed-off-by: Slimane AMAR <[email protected]>
Signed-off-by: Slimane AMAR <[email protected]>
Signed-off-by: Slimane AMAR <[email protected]>
5bcc0ce
to
de0f761
Compare
Signed-off-by: Slimane AMAR <[email protected]>
…163) Signed-off-by: Slimane AMAR <[email protected]>
Signed-off-by: Slimane AMAR <[email protected]>
Signed-off-by: Slimane AMAR <[email protected]>
…163) Signed-off-by: Slimane AMAR <[email protected]>
Signed-off-by: Slimane AMAR <[email protected]>
04da2ad
to
331a6e5
Compare
Signed-off-by: Slimane AMAR <[email protected]>
Signed-off-by: Slimane AMAR <[email protected]>
f2dc293
to
b897899
Compare
Signed-off-by: Slimane AMAR <[email protected]>
b897899
to
8283cab
Compare
Signed-off-by: Slimane AMAR <[email protected]>
Signed-off-by: Slimane AMAR <[email protected]>
Signed-off-by: Slimane AMAR <[email protected]>
0791533
to
7e339f0
Compare
…merged and configured) (#163) Signed-off-by: Slimane AMAR <[email protected]>
Signed-off-by: Slimane AMAR <[email protected]>
…breaker topology (#163) Signed-off-by: Slimane AMAR <[email protected]>
Signed-off-by: Slimane AMAR <[email protected]>
Signed-off-by: Slimane AMAR <[email protected]>
…mically created on the fly from attributes (#163) Signed-off-by: Slimane AMAR <[email protected]>
19906aa
to
9544d1c
Compare
Signed-off-by: Slimane AMAR <[email protected]>
Signed-off-by: Slimane AMAR <[email protected]>
7ed5216
to
d9b92ff
Compare
Signed-off-by: Slimane AMAR <[email protected]>
Signed-off-by: Slimane AMAR <[email protected]>
2b0c3db
to
15b0312
Compare
network-store-iidm-impl/src/main/java/com/powsybl/network/store/iidm/impl/VoltageLevelImpl.java
Show resolved
Hide resolved
Signed-off-by: Slimane AMAR <[email protected]>
15b0312
to
3b49ed6
Compare
Signed-off-by: Slimane AMAR <[email protected]>
3b49ed6
to
2a684ba
Compare
…tore into complete_persistent_iidm_implementation
|
||
Graph<Integer, Edge> graph = NodeBreakerTopology.INSTANCE.buildGraph(index, voltageLevelResource); | ||
Graph<Integer, Edge> graph = NodeBreakerTopology.INSTANCE.buildGraph(index, voltageLevelResource, true, true); |
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
Why is this method called with isBusView to true. What is the purpose of this option?
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
The connectivity graph is used to calculate buses in a VL and in node/breaker the calculated buses depends on the chosen view.
BusView : !switch::isOpen
BusBreakerView : !switch::isOpen && !switch::isRetained
But when we just traverse the topology, we do not take into account the switches (open or retained).
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
Maybe i need rename isBusView by includeRetainedSwitches
} | ||
|
||
@Override | ||
public void remove() { | ||
resource.getAttributes().setConverterStationId1(null); |
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
Why do yu need to change the resource as it won't be used anymore?
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
I agree but the tck test AbstractLccTest::testHvdcLineRemove
considers that it must be set to null and checks it
@@ -27,16 +27,19 @@ static HvdcLineImpl create(NetworkObjectIndex index, Resource<HvdcLineAttributes | |||
|
|||
@Override | |||
public HvdcConverterStation<?> getConverterStation1() { | |||
return index.getHvdcConverterStation(resource.getAttributes().getConverterStationId1()).orElseThrow(IllegalStateException::new); | |||
return resource.getAttributes().getConverterStationId1() != null ? index.getHvdcConverterStation(resource.getAttributes().getConverterStationId1()).orElse(null) : null; |
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
Is should not be possible to have this null
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
See comment above
} | ||
|
||
@Override | ||
public HvdcConverterStation<?> getConverterStation2() { | ||
return index.getHvdcConverterStation(resource.getAttributes().getConverterStationId2()).orElseThrow(IllegalStateException::new); | ||
return resource.getAttributes().getConverterStationId2() != null ? index.getHvdcConverterStation(resource.getAttributes().getConverterStationId2()).orElse(null) : null; |
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
Same
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
see comment above
public Collection<Component> getConnectedComponents() { | ||
throw new UnsupportedOperationException("TODO"); | ||
public Collection<Component> getConnectedComponents() { // FIXME : need a reference bus by component | ||
return getBusStream().map(Bus::getConnectedComponent).collect(Collectors.toList()); |
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
This is not correct, as you are going to have here as many ConnectedComponent object as Bus but the aim was to get a list of unique ConnectedComponent
…or optimization purposes (#163) Signed-off-by: Slimane AMAR <[email protected]>
6d28ea0
to
772a17d
Compare
…tore into complete_persistent_iidm_implementation
772a17d
to
a0fb7f9
Compare
# Conflicts: # network-store-server/src/main/java/com/powsybl/network/store/server/NetworkStoreRepository.java # network-store-server/src/main/resources/iidm.cql
Signed-off-by: Geoffroy Jamgotchian <[email protected]>
Kudos, SonarCloud Quality Gate passed! |
Please check if the PR fulfills these requirements (please use
'[x]'
to check the checkboxes, or submit the PR and then click the checkboxes)Does this PR already have an issue describing the problem ? If so, link to this issue using
'#XXX'
and skip the restWhat kind of change does this PR introduce? (Bug fix, feature, docs update, ...)
What is the current behavior? (You can also link to an open issue here)
What is the new behavior (if this is a feature change)?
Does this PR introduce a breaking change or deprecate an API? If yes, check the following:
Other information:
(if any of the questions/checkboxes don't apply, please delete them entirely)