I have a plugin that has been running fine for the last handful of XProtect versions (Management Client), however in 2023 R1 we noticed a crash just before the plugin was loaded. After further investigation it seems that the Hardware.FillChildren call is causing the crash, if this code is commented out, the plugin runs okay.
Has anyone seen this before, any idea what’s going on?
Hi @Brad Lackey,
I think I ran into the same issue myself when updating MilestonePSTools to use the 23.1 nuget packages. I reported it to the SDK team as it seems to be a breaking change with no documentation available yet.
Here’s what I did to resolve it but I’m not sure it’s valid to do this in a plugin off the top of my head:
VideoOS.Platform.Proxy.ConfigApi.ConfigurationApiManager.BypassApiGateway = false;
VideoOS.Platform.Configuration.Instance.ConfigurationApiManager.UseRestApiWhenAvailable = false;
This forces the SDK to skip the new API Gateway even if it’s available. This method along with QueryItems isn’t implemented in the REST API and instead of the SDK falling back to old APIs for calls like these, the calls simply fail right now.
If you get a chance to verify whether or not this resolves the issue for now, please let us know so we can add this feedback to the current issue report.
Hi Josh,
Thanks for the comment and suggestion, unfortunately when when mutating those properties at the plugin’s entry point it appears to have no effect and the same NotImplementedException is thrown when attempting to FillChildren.
It looks like these particular API methods will be made to automatically fall back to the older endpoints for the next version. Given that it was a breaking change, this would usually mean a cumulative patch would be made for the current version. I think that will be the case but I’ll have to check with the SDK team to verify.