From this question https://community.dataminer.services/question/recycle-bin-restoring-of-service-template-in-cluster/ it looks like you can only do this by restarting the DataMiner agents in the system.
However I was wondering if there's a way to restore it without restarting the DataMiner software similar like you can restore resources/profiles/Service definitions from a json file without the need to restart DataMiner.
Is the only way to do it currently without a restart:
- manually check the difference and update the service via Cube to match the old service.xml
Can we somehow serialize the service.xml and send it as an update using an slnetcall avoiding the need to restart?
Hi Tim,
There's a few options I think, all of them are very much workarounds that I wouldn't recommend using in production scripts or protocols. They are not guaranteed to remain functional in future versions.
- Send the following request:
SetDataMinerInfoMessage createServiceMessage = new SetDataMinerInfoMessage(){DataMinerID = [YOUR DMA ID],What = (int)NotifyType.Service,IInfo1 = Int32.MaxValue,IInfo2 = Int32.MaxValue,bInfo1 = Int32.MaxValue,bInfo2 = Int32.MaxValue,StrInfo2 = [YOUR service XML],Uia1 = new UIA(new int[] { [SERVICE ID], [DMA ID], false}),}
- If you don't want to use code, export a dummy service using a DELT export. Extract the DELT export package and manually change the contents so it contains your service instead. This is rather tricky.
Worked with: SetDataMinerInfoMessage createServiceMessage = new SetDataMinerInfoMessage
{
DataMinerID = dmaID,
What = (int)NotifyType.Service,
IInfo1 = Int32.MaxValue,
IInfo2 = Int32.MaxValue,
bInfo1 = Int32.MaxValue,
bInfo2 = Int32.MaxValue,
StrInfo2 = fileContent,
Uia1 = new UIA(new int[]
{
servID,
dmaID,
0,
}),
};
Thanks