Skip to content

Commit

Permalink
Topology protobuf and any notification params (#39)
Browse files Browse the repository at this point in the history
## Description

Created `ComputedTopology` and changed type of notification parameters.
This is a temporary structure util we migrate all the labview part.

## Changes Made

Created `ComputedTopology` and changed type of notification parameters.

## Related Issues

N/A

## Checklist

- [x] I have used a PR title that is descriptive enough for a release
note.
- [x] I have tested these changes locally.
- [x] I have added appropriate tests or updated existing tests.
- [ ] I have tested these changes on a dedicated VM or a customer VM
[name of the VM]
- [x] I have added appropriate documentation or updated existing
documentation.

---------

Co-authored-by: cosimomeli <[email protected]>
Co-authored-by: Cosimo Meli <[email protected]>
Co-authored-by: chicco785 <[email protected]>
  • Loading branch information
4 people authored Feb 19, 2024
1 parent 8bca68e commit f3d4737
Show file tree
Hide file tree
Showing 8 changed files with 664 additions and 198 deletions.
6 changes: 5 additions & 1 deletion RELEASE_NOTES.md
Original file line number Diff line number Diff line change
@@ -1,6 +1,10 @@
# ProtoBuf Release Notes

## 0.0.4-dev - 2024-02-13
## 0.0.4-dev - 2024-02-19

### Features

- Topology protobuf and any notification params (PR #39 by @hiimjako)

### Continuous Integration

Expand Down
16 changes: 9 additions & 7 deletions docs/task.proto.md
Original file line number Diff line number Diff line change
Expand Up @@ -9,8 +9,9 @@ services.

## Imports

| Import | Description |
|--------|-------------|
| Import | Description |
|---------------------------|-------------|
| google/protobuf/any.proto | |



Expand Down Expand Up @@ -99,8 +100,9 @@ direction LR
class Parameter {
+ string name
+ string value
+ google.protobuf.Any value
}
Parameter --> `google.protobuf.Any`
```
### Task Diagram
Expand Down Expand Up @@ -160,10 +162,10 @@ Notification --> `Parameter`
A parameter of a `Task` or `Notification`


| Field | Ordinal | Type | Label | Description |
|---------|---------|----------|-------|----------------------|
| `name` | 1 | `string` | | The parameter name |
| `value` | 2 | `string` | | The parameter value |
| Field | Ordinal | Type | Label | Description |
|---------|---------|-----------------------|-------|----------------------|
| `name` | 1 | `string` | | The parameter name |
| `value` | 2 | `google.protobuf.Any` | | The parameter value |



Expand Down
119 changes: 119 additions & 0 deletions docs/topology.proto.md
Original file line number Diff line number Diff line change
Expand Up @@ -41,6 +41,65 @@ class Topology {
+ bytes tp
}
```
### TopologicalNode Diagram

```mermaid
classDiagram
direction LR
%% A topology Node information.
%% * To be used in ComputedTopology message.
%%
class TopologicalNode {
+ double BaseVoltage
+ string BaseVoltageId
+ string ConnectivityNodeContainerId
+ List~string~ ConnectivityNodeIds
+ List~string~ PowerTransferEndIds
+ List~string~ TerminalIds
}
```
### TopologicalIsland Diagram

```mermaid
classDiagram
direction LR
%% A topology Island information.
%% * To be used in ComputedTopology message.
%%
class TopologicalIsland {
+ List~string~ TopologicalNodeIds
}
```
### ComputedTopology Diagram

```mermaid
classDiagram
direction LR
%% A processed topology information.
%% Headers used in rabbitMQ:
%% * `id` (string): id of the `Topology`
%% * `type` (string): always `ComputedTopology`
%% * `producerId` (string): the id of the producer (e.g. a PMU) linked to the dataset.
%% * `timestampId` (int64): related measurement Unix msec timestamp (if any)
%% * `subnetworkId` (string): the sub network id for which the topology was computed
%%
class ComputedTopology {
+ string eqId
+ Map~string, TopologicalIsland~ topologicalIslands
+ Map~string, TopologicalNode~ topologicalNodes
}
ComputedTopology .. ` TopologicalIsland`
ComputedTopology .. ` TopologicalNode`
```

## Message: Topology
Expand All @@ -65,6 +124,66 @@ Headers used in rabbitMQ:



## Message: TopologicalNode

**FQN**: grid.v1.TopologicalNode

A topology Node information.
* To be used in ComputedTopology message.



| Field | Ordinal | Type | Label | Description |
|-------------------------------|---------|----------|----------|------------------------------------------------------------------|
| `BaseVoltage` | 6 | `double` | | The BaseVoltage in the TopologicalNode. |
| `BaseVoltageId` | 5 | `string` | | The id of the BaseVoltage in the TopologicalNode. |
| `ConnectivityNodeContainerId` | 4 | `string` | | The id of the ConnectivityNodeContainer in the TopologicalNode. |
| `ConnectivityNodeIds` | 2 | `string` | Repeated | The list of ConnectivityNode ids in the TopologicalNode. |
| `PowerTransferEndIds` | 3 | `string` | Repeated | The list of PowerTransferEnd ids in the TopologicalNode. |
| `TerminalIds` | 1 | `string` | Repeated | The list of Terminal ids in the TopologicalNode. |




## Message: TopologicalIsland

**FQN**: grid.v1.TopologicalIsland

A topology Island information.
* To be used in ComputedTopology message.



| Field | Ordinal | Type | Label | Description |
|----------------------|---------|----------|----------|------------------------------------------------------------|
| `TopologicalNodeIds` | 1 | `string` | Repeated | The list of TopologicalNode ids in the TopologicalIsland. |




## Message: ComputedTopology

**FQN**: grid.v1.ComputedTopology

A processed topology information.
Headers used in rabbitMQ:
* `id` (string): id of the `Topology`
* `type` (string): always `ComputedTopology`
* `producerId` (string): the id of the producer (e.g. a PMU) linked to the dataset.
* `timestampId` (int64): related measurement Unix msec timestamp (if any)
* `subnetworkId` (string): the sub network id for which the topology was computed



| Field | Ordinal | Type | Label | Description |
|----------------------|---------|-----------------------------|-------|-------------------------------------------------|
| `eqId` | 1 | `string` | | The id of the EQ file used. |
| `topologicalIslands` | 3 | `string, TopologicalIsland` | Map | The map of TopologicalIslands in the Topology. |
| `topologicalNodes` | 2 | `string, TopologicalNode` | Map | The map of TopologicalNodes in the Topology. |






<!-- Created by: Proto Diagram Tool -->
Expand Down
Loading

0 comments on commit f3d4737

Please sign in to comment.