forked from TrueCloudLab/frostfs-api
[#34] bootstrap: Move NodeInfo to netmap
Move NodeInfo message definition to netmap package. Package bootstrap is completely removed from the repository. Signed-off-by: Leonard Lyubich <leonard@nspcc.ru>
This commit is contained in:
parent
f60273beb9
commit
031579a68d
3 changed files with 77 additions and 42 deletions
|
@ -1,42 +0,0 @@
|
|||
syntax = "proto3";
|
||||
|
||||
package bootstrap;
|
||||
|
||||
option go_package = "github.com/nspcc-dev/neofs-api-go/bootstrap";
|
||||
option csharp_namespace = "NeoFS.API.Bootstrap";
|
||||
|
||||
// Groups the information about the NeoFS node.
|
||||
message NodeInfo {
|
||||
// Carries network address of the NeoFS node.
|
||||
string Address = 1;
|
||||
|
||||
// Carries public key of the NeoFS node in a binary format.
|
||||
bytes PublicKey = 2;
|
||||
|
||||
// Groups attributes of the NeoFS node.
|
||||
message Attribute {
|
||||
// Carries string key to the node attribute.
|
||||
string Key = 1;
|
||||
|
||||
// Carries string value of the node attribute.
|
||||
string Value = 2;
|
||||
}
|
||||
|
||||
// // Carries list of the NeoFS node attributes in a string key-value format.
|
||||
repeated Attribute Attributes = 3;
|
||||
|
||||
// Represents the enumeration of various states of the NeoFS node.
|
||||
enum State {
|
||||
// Undefined state.
|
||||
Unknown = 0;
|
||||
|
||||
// Active state on the network.
|
||||
Online = 1;
|
||||
|
||||
// Network unavailable state.
|
||||
Offline = 2;
|
||||
}
|
||||
|
||||
// Carries state of the NeoFS node.
|
||||
State state = 4;
|
||||
}
|
|
@ -54,3 +54,39 @@ message PlacementRule {
|
|||
|
||||
repeated SFGroup SFGroups = 2;
|
||||
}
|
||||
|
||||
// Groups the information about the NeoFS node.
|
||||
message NodeInfo {
|
||||
// Carries network address of the NeoFS node.
|
||||
string Address = 1;
|
||||
|
||||
// Carries public key of the NeoFS node in a binary format.
|
||||
bytes PublicKey = 2;
|
||||
|
||||
// Groups attributes of the NeoFS node.
|
||||
message Attribute {
|
||||
// Carries string key to the node attribute.
|
||||
string Key = 1;
|
||||
|
||||
// Carries string value of the node attribute.
|
||||
string Value = 2;
|
||||
}
|
||||
|
||||
// // Carries list of the NeoFS node attributes in a string key-value format.
|
||||
repeated Attribute Attributes = 3;
|
||||
|
||||
// Represents the enumeration of various states of the NeoFS node.
|
||||
enum State {
|
||||
// Undefined state.
|
||||
Unknown = 0;
|
||||
|
||||
// Active state on the network.
|
||||
Online = 1;
|
||||
|
||||
// Network unavailable state.
|
||||
Offline = 2;
|
||||
}
|
||||
|
||||
// Carries state of the NeoFS node.
|
||||
State state = 4;
|
||||
}
|
|
@ -6,6 +6,8 @@
|
|||
- [netmap/types.proto](#netmap/types.proto)
|
||||
|
||||
- Messages
|
||||
- [NodeInfo](#netmap.NodeInfo)
|
||||
- [NodeInfo.Attribute](#netmap.NodeInfo.Attribute)
|
||||
- [PlacementRule](#netmap.PlacementRule)
|
||||
- [PlacementRule.SFGroup](#netmap.PlacementRule.SFGroup)
|
||||
- [PlacementRule.SFGroup.Filter](#netmap.PlacementRule.SFGroup.Filter)
|
||||
|
@ -27,6 +29,32 @@
|
|||
<!-- end services -->
|
||||
|
||||
|
||||
<a name="netmap.NodeInfo"></a>
|
||||
|
||||
### Message NodeInfo
|
||||
Groups the information about the NeoFS node.
|
||||
|
||||
|
||||
| Field | Type | Label | Description |
|
||||
| ----- | ---- | ----- | ----------- |
|
||||
| Address | [string](#string) | | Carries network address of the NeoFS node. |
|
||||
| PublicKey | [bytes](#bytes) | | Carries public key of the NeoFS node in a binary format. |
|
||||
| Attributes | [NodeInfo.Attribute](#netmap.NodeInfo.Attribute) | repeated | Carries list of the NeoFS node attributes in a string key-value format. |
|
||||
| state | [NodeInfo.State](#netmap.NodeInfo.State) | | Carries state of the NeoFS node. |
|
||||
|
||||
|
||||
<a name="netmap.NodeInfo.Attribute"></a>
|
||||
|
||||
### Message NodeInfo.Attribute
|
||||
Groups attributes of the NeoFS node.
|
||||
|
||||
|
||||
| Field | Type | Label | Description |
|
||||
| ----- | ---- | ----- | ----------- |
|
||||
| Key | [string](#string) | | Carries string key to the node attribute. |
|
||||
| Value | [string](#string) | | Carries string value of the node attribute. |
|
||||
|
||||
|
||||
<a name="netmap.PlacementRule"></a>
|
||||
|
||||
### Message PlacementRule
|
||||
|
@ -102,6 +130,19 @@
|
|||
<!-- end messages -->
|
||||
|
||||
|
||||
<a name="netmap.NodeInfo.State"></a>
|
||||
|
||||
### NodeInfo.State
|
||||
Represents the enumeration of various states of the NeoFS node.
|
||||
|
||||
| Name | Number | Description |
|
||||
| ---- | ------ | ----------- |
|
||||
| Unknown | 0 | Undefined state. |
|
||||
| Online | 1 | Active state on the network. |
|
||||
| Offline | 2 | Network unavailable state. |
|
||||
|
||||
|
||||
|
||||
<a name="netmap.PlacementRule.SFGroup.Filter.SimpleFilter.Operation"></a>
|
||||
|
||||
### PlacementRule.SFGroup.Filter.SimpleFilter.Operation
|
||||
|
|
Loading…
Reference in a new issue