Junos OS registration IDL - Protocol Documentation

Table of Contents

registration_service.proto

Top

This IDL describes the remote procedure calls (RPCs) and messages available for working with the registration service API.

Copyright (c) 2016, Juniper Networks, Inc. All rights reserved.

RegisterReply

The response message containing success or failure of the service. registration request. A result value of true indicates success and false indicates failure. In case of false, error attibute indicates the reason for failure.

FieldTypeLabelDescription
result bool optional

The result. True or False

error string optional

In case of failure, this string will contain the reason.

RegisterRequest

The request message containing the service registration info

FieldTypeLabelDescription
json_input string optional

JSON string from the file emitted using protoc-thrift compiler

file_input string optional

Absolute file path on the router containing json input

target string optional

Target ip-address/unix domain socket for this service For e.g., IPv6 address format will be "[::]:50051", IPv4 address format will be "0.0.0.0:50051" format and unix domain socket format will be "unix:/tmp/test_socket"

register_id string optional

Registration ID that will be used as the filename to store the APIs registered in /opt/lib.proto/<register-id>.json JSD will read the contents of this file upon restart. When the daemon re-registers the APIs, it needs to use the same register ID. This will allow JSD to delete the old file and store the new contents in that file.

skip_authentication bool optional

Boolean variable to indicate if JSD should skip LoginCheck() call for RPCs executed for this package from clients if they are connected using a secure channel

Register

The service Registration definition.

Method NameRequest TypeResponse TypeDescription
RegisterService RegisterRequest RegisterReply

Scalar Value Types

.proto TypeNotesC++ TypeJava TypePython Type
double double double float
float float float float
int32 Uses variable-length encoding. Inefficient for encoding negative numbers – if your field is likely to have negative values, use sint32 instead. int32 int int
int64 Uses variable-length encoding. Inefficient for encoding negative numbers – if your field is likely to have negative values, use sint64 instead. int64 long int/long
uint32 Uses variable-length encoding. uint32 int int/long
uint64 Uses variable-length encoding. uint64 long int/long
sint32 Uses variable-length encoding. Signed int value. These more efficiently encode negative numbers than regular int32s. int32 int int
sint64 Uses variable-length encoding. Signed int value. These more efficiently encode negative numbers than regular int64s. int64 long int/long
fixed32 Always four bytes. More efficient than uint32 if values are often greater than 2^28. uint32 int int
fixed64 Always eight bytes. More efficient than uint64 if values are often greater than 2^56. uint64 long int/long
sfixed32 Always four bytes. int32 int int
sfixed64 Always eight bytes. int64 long int/long
bool bool boolean boolean
string A string must always contain UTF-8 encoded or 7-bit ASCII text. string String str/unicode
bytes May contain any arbitrary sequence of bytes. string ByteString str