Hi Dojo
We made a script that will apply a profile instance to a resource without creating a booking. Logging is included in the profile load scripts using the following method:
Skyline.DataMiner.Library.Solutions.SRM.LifecycleServiceOrchestration.ProfileParameterEntryHelper.LogSuccessResult(string dveName, string parameterName, string value){...}
When creating a booking, a (.html) log file will be automatically generated in the Booking Logging Location (can be configured in the visual overview of the Skyline Booking Manager element, Config tab > General tab > History and Logs > Booking Logging Location). But by just launching the profile load script, the log file is not created. Would it be possible to trigger the creation of this log file manually? From the script that will trigger the profile load script for instance?
Thank you in advance!
Kind regards
hi Michiel
It's possible to log the outcome of applying a profile to a resource.
If the Profile Load Script needs to be tested the SRM framework facilitates that. You can find more info about that here: SRM Framework 1.2.21 facilitates Profile-Load Script testing - DataMiner Dojo
In case you'd need to apply a Profile to a resource outside the context of a booking, the framework also provides functionality for that and allows you to log the outcome. So, there's no need to launch the profile load script directly.
If that's the case here, could you share more details about your use case?
Best regards
Since 1.2.18 (ID_30975) GetOrchestrationHelper also has an overload that takes the Booking Manager as an argument. The helper will then create a log file (format: “Resource_[Resource ID]_[Orchestration time].html”) in the location that’s specified in the Booking Manager.
Hi Peter, yes that’s exactly what I needed. Thanks a lot!
Hi Peter, thank you very much for your reply! It is already possible to launch the profile load scripts using our own “apply profile script”. I would like to know if there is a method available in the SRM framework which will create the log file in the Booking Logging Location. The goal here is to keep using the existing logging method calls in the profile load scripts without adding extra Skyline.DataMiner.Automation.Engine.GenerateInformation() method calls.
To go a bit more in detail, I noticed it’s possible to pass a Skyline.DataMiner.Library.Solutions.SRM.Logging.SrmLogHandler object with the Skyline.DataMiner.Library.Resource.ResourceExtensionMethods.GetOrchestrationHelper() method. To Create the SrmLogHandler object you need to pass a Skyline.DataMiner.Net.ResourceManager.Objects.ReservationInstance object with the SrmLogHandler.Create() method. I tried passing a ReservationInstance object created based on a random Guid but it doesn’t work. I am aware this is not the suggested approach, I’m just trying some things. Would you know if this is possible?
Thank you in advance!