powsybl / powsybl-afs

AFS modules for powsybl
Mozilla Public License 2.0
3 stars 1 forks source link

Remove ifnotexist when inserting node_data_name #65

Closed pl-buiquang closed 3 years ago

pl-buiquang commented 3 years ago

Please check if the PR fulfills these requirements (please use '[x]' to check the checkboxes, or submit the PR and then click the checkboxes)

What kind of change does this PR introduce? (Bug fix, feature, docs update, ...) Bug fix

What is the current behavior? (You can also link to an open issue here) Since https://github.com/powsybl/powsybl-afs/pull/55, the data names are removed before any new write to the data output stream. It happens that the recreation of the data name at the end, protected with ifNotExists, does not pick up consistently the prior deletion, and therefore sometimes does not recreate the data name.

What is the new behavior (if this is a feature change)? Now the data name is always created (removing the ifNotExists clause since the data name is always deleted before). Also, the Insert#ifNotExists is stated to impact performance, so performance should also be improved.

sonarcloud[bot] commented 3 years ago

Kudos, SonarCloud Quality Gate passed!

Bug A 0 Bugs
Vulnerability A 0 Vulnerabilities
Security Hotspot A 0 Security Hotspots
Code Smell A 0 Code Smells

No Coverage information No Coverage information
No Duplication information No Duplication information

warning The version of Java (1.8.0_275) you have used to run this analysis is deprecated and we will stop accepting it soon. Please update to at least Java 11. Read more here