Closed balazsracz closed 2 months ago
What would the user see in this case? Should the CDI configuration window close, to indicate that it needs to be reloaded? Or should it automatically reload CDI? And then refresh content?
One approach would be to post a JOptionPane dialog telling the user what happened, with just a "Continue" button. Clicking that closes the window. But that might be too disruptive.
@bobjacobsen Ideally if the node has rebooted and the fields that @balazsracz mentioned changes the cached XML should be discarded and re-pulled from the node as it may have changed. If the users is already in the CDI dialog for the node then I think your JOptionPane approach seems reasonable, the disruptive part may be unavoidable.
OpenLCB and JMRI now invalidate CDI (and close any open edit window) when a firmware download starts.
I think this can be closed.
Resolved with updates.
Currently we cache the CDI's XML structure in memory so long as the program is running. We should invalidate this cache if we see that a given node's hardware name/version/softwarename/version changes. This should catch cases when a node comes up in bootloader mode.