Hey,
Is there a way to show on bpa information (for example snapshot below) on dashboards?
Thank you.
Hi Guy,
There is no built-in way to show this information in a Dashboard. To be able to show this, you will have to create your own ad-hoc data source. This data source can make use of the GQIDMS and BpaManagerHelper classes to get the results from the tests. I have created a small example to get you started:
using Skyline.DataMiner.Analytics.GenericInterface;
using Skyline.DataMiner.Net.BPA;
using System.Linq;namespace BPAResults
{
[GQIMetaData(Name = “BPAResults”)]
public sealed class BPAResults : IGQIDataSource, IGQIOnInit
{
private GQIDMS _dms;
private IGQILogger _logger;public GQIColumn[] GetColumns()
{
return new GQIColumn[]
{
new GQIStringColumn(“Message”),
new GQIStringColumn(“Impact”),
};
}public GQIPage GetNextPage(GetNextPageInputArgs args)
{
var bpaHelper = new BpaManagerHelper(_dms.GetConnection());
var bpas = bpaHelper.BPAs.ReadAll();
var results = bpaHelper.BPAs.GetLastResults(bpas, DestinationAgent.LocalAgentOnly());return new GQIPage(results.Responses.Select(x =>
{
return new GQIRow(new GQICell[2] {
new GQICell() { Value = x.Message },
new GQICell() { Value = x.Impact },
});
}).ToArray())
{
HasNextPage = false,
};
}public OnInitOutputArgs OnInit(OnInitInputArgs args)
{
_dms = args.DMS;
_logger = args.Logger;return default;
}
}
}