Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

FirmwareManagement.UpdateFirmwareRequest doesn't update DeviceFirmwareHistory #252

Open
ThE-MaRaC opened this issue Jun 4, 2021 · 3 comments

Comments

@ThE-MaRaC
Copy link

FirmwareManagement.UpdateFirmwareRequest operation should update DeviceFirmwareHistory (device_firmware_file table in osgp_core DB) after successful installation of new FW.
There is a separate FirmwareManagement.SaveCurrentDeviceFirmware operation that can be used to manually update DeviceFirmwareHistory, but I assume that this operation should be used only if FW is not installed via GXF.
Please let me know if you need any other info or assistance.

@kevinsmeets
Copy link
Contributor

The operation UpdateFirmwareRequest sends an URL to an SSLD. Later, a GetFirmwareVersionRequest is executed to check if the new firmware version is installed. The database record is updated when the firmware version matches the new expected firmware version.

@ThE-MaRaC
Copy link
Author

But, this process is not automated.
My idea was the following:

  1. UpdateFirmwareRequest sent to SSLD
  2. after successful FW installation SSLD will send an event
  3. GXF receives events and updates DeviceFirmwareHistory

@smvdheijden
Copy link
Member

Actually the process is automated, albeit in a slightly different way. After an SSLD updates it's firmware, it will reboot and register itself. When a device registration is completed, osgp-adapter-domain-core receives a message that is handled by DeviceRegistrationCompletedMessageProcessor which in turn calls FirmwareManagementService.handleSsldPendingFirmwareUpdate which initiates a GetFirmwareVersionRequest.
The same FirmwareManagementService class will handle the response of this request and update the firmware version history when needed.

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
None yet
Projects
None yet
Development

No branches or pull requests

3 participants