0.51
0.51 (2020-06-29)
This release introduces automatic assignment rules for modem message body parsers.
These rules can be used to assign body parsers to modems across organizations, based on criteria like
tags, manufacturers and peripherals.
Changes
DashboardService
- Fixed a few comments.
EventService
-
Added two new modem message events:
ModemMessageBodyReceivedEvent
is a simplified version of theModemMessageReceivedEvent
that
doesn't have aMessage
object. Instead, it only hasmessage_id
,sent_at
andbody
.
This is useful for the cases where you need a lighter format and are not using body parsing.ModemMessageBodyParsedEvent
is an event that is produced for each message, for each body parser.
If you assign 3 body parsers to modem, they all try to parse the message. Every success produces this event.
This is useful for the cases where you're only interested in the parsed body.- For each of these events, an
EventType
has been added tobase.proto
- For all three message events, an example json has been added under
event-json-examples
.
In the future, more examples for other event types will be placed there.
-
Added new body parser events:
MessageBodyParserEvent.CreatedEvent
is produced when a new body parser is created.MessageBodyParserEvent.UpdatedEvent
is produced when a body parser is updated.MessageBodyParserEvent.DeletedEvent
is produced when a body parser is deleted.MessageBodyParserEvent.AssignedEvent
is produced when a body parser is directly assigned to a modem.MessageBodyParserEvent.UnassignedEvent
is produced when a body parser is removed from to a modem.MessageBodyParserEvent.AutomaticAssignmentEvent.CreatedEvent
is produced when a new automatic assignment rule
for body parsers is created.MessageBodyParserEvent.AutomaticAssignmentEvent.UpdatedEvent
is produced when an automatic assignment rules for
for body parsers is updated.MessageBodyParserEvent.AutomaticAssignmentEvent.DeletedEvent
is produced when an automatic assignment rules for
for body parsers is deleted.- For each of these events, an
EventType
has been added tobase.proto
-
Added a new event
UserValidationUpdatedEvent
when user validation has been updated. -
Fixed a few imports and comments.
ModemService
-
ModemMessage.ParsedBody
was updated to reflect the changes to body parsers:- Added
parser_identifier
toParsedBody
. This field contains a globally unique identifier
for the body parser used to parse the message body. - The
parser_id
is now deprecated in favour of theidentifier
. - Wrapped
result
anderror
in aoneof
, since only one can be present.
- Added
-
Added
UpdateModemStatusRequest.modem_selection
to update the status for multiple modems at the same time.- Deprecated the single modem field
UpdateModemStatusRequest.modem_number
, since the selection covers that case.
- Deprecated the single modem field
-
Fixed a few imports and comments.
ModemMessageBodyParserService
-
Deprecated the assignment-related calls in favour of the new
ModemMessageBodyParserAssignmentService
:- Deprecated
ListAssignedParsers
andListAssignedParsersRequest
- Deprecated
AssignToModems
andAssignModemMessageBodyParserToModemsRequest
- Deprecated
RemoveFromModems
andRemoveModemMessageBodyParserFromModemsRequest
- Deprecated
-
Updated
ModemMessageBodyParser
to match the new global body parser usage better:- Added
identifier
toModemMessageBodyParser
, a globally unique identifier for the body parser. - Added
organization
toModemMessageBodyParser
, to show who owns the body parsers. - Deprecated
id
inModemMessageBodyParser
in favour of theidentifier
. - [B] Dropped
ModemMessageBodyParser.AvailableToChildOrganizations.parser_id_for_child_organizations
in favour of the newidentifier
.
- Added
-
Updated
ModemMessageBodyParserSelection
to match the changes toModemMessageBodyParser
:- [B] Removed
SelectIdentifier
and its related field. - Added
identifiers
to search on identifiers. - Deprecated
ids
inModemMessageBodyParser
in favour ofidentifiers
. - Renamed
exclude_provided_parsers
toonly_owned_parsers
. - Renamed
providers
toowner_organizations
.
- [B] Removed
-
Added
ListModemMessageBodyParsersRequest.exclude_content
to not fill the content of the returned body parsers
(either thecontent_ksy
orsimple_parser
fields). -
Updated
UploadModemMessageBodyParserRequest
,UpdateSimpleModemMessageBodyParserRequest
,
RenameModemMessageBodyParserRequest
andUpdateChildOrganizationAvailabilityRequest
to match the changes
toModemMessageBodyParser
:- Added
identifier
and deprecatedid
.
- Added
-
Updated
TestModemMessageBodyParserRequest
to match the changes toModemMessageBodyParser
:- [B] Removed the
SelectIdentifier
-based field. - Added
identifier
.
- [B] Removed the
ModemMessageBodyParserAutomaticAssignmentService
-
Added
ModemMessageBodyParserAutomaticAssignmentService
to manage automatic assignment rules for body parsers.These rules can be used to automatically assign body parsers to modem that match specific criteria.
For example, all modems with tag "parse-this" and a peripheral "sensor": "water-sensor-brand-x" can be
assigned a parser for the data format for that peripheral.Criteria can be used and combined in a multitude of ways, but here are a few notable uses:
- assign a parser to tag, so assigning it to modems is as easy as adding a tag to that modem
- assign a parser to peripheral, so each modem with that peripheral gets that parser by default
- blacklisting a parser from a tag, so you can set that tag to exclude a modem from being assigned that parser
- blacklisting a parser from a set of modems, so you can exclude a set of modem from being assigned that parser
- add a parser to devices you manufacture, and apply this to child organizations, so that all of your
customers' modems are automatically assigned that parser
ModemMessageBodyParserAssignmentService
- Added
ModemMessageBodyParserAssignmentService
to assign body parsers directly to modems and
list assignments based on direct assignments to modems and the result of applying automatic assignment rules.
TokenService
- Added the
created
Token
toCreateTokenRequest
, so the output is more that just the token string.
Backwards incompatible changes
- [B] Removed
SelectIdentifier
and its related field fromModemMessageBodyParserSelection
.
Use the newidentifier
field instead. - [B] Dropped
parser_id_for_child_organizations
fromModemMessageBodyParser.AvailableToChildOrganizations
.
Use the newidentifier
field instead. - [B] Removed the
SelectIdentifier
-based field fromTestModemMessageBodyParserRequest
.
Use the newidentifiers
field instead.