Dashboards & Visualizations

Can I build a simple dashboard tool taking user input and producing a result?

vm_molson
Explorer

I know this is now what Splunk is, but since we have so much of our current monitoring built into it, I wanted to see if I can just add this also.

I am looking to create a dashboard that a user pulls up and provides values for certain inputs, takes the values, and produces a result based on a pre-defined algorythm.

For (an extremely simple) example:

User has to enter:

  • Number of Cars
  • Number of packages
  • Number of People

And then there is a formula we have stored somewhere that takes the inputs, weights them, and produces a result (i.e. - "take the blue ferry" vs. "take the white ferry").

It would be nice if we could do this, even though it's very simple, since we're asking our users to spend more time in the tool.

TIA!

Labels (1)
0 Karma

jdunlea
Contributor

Yes you can absolutely do that, using a search underlying the dashboard. The search can start off with something like the following to create an event that takes in the variables, and then you can run whatever other commands you wish on top of that event to create the output. 

 

| makeresults count=1 | eval car_count=<value for # of cars>, package_count=<value for # of packages>, person_count=<value for # of people>
| eval car_weight=50, package_weight=20, person_weight=5
| eval car_weighted_value=car_count*car_weight, package_weighted_value=package_count*package_weight, person_weighted_value=person_count*person_weight
| eval total_weighted_value=car_weighted_value+package_weighted_value+person_weighted_value
| eval output=case(total_weighted_value<20,"walk",total_weighted_value>=20 AND total_weighted_value<=100,"take bus", total_weighted_value>100,"take ferry")
| table output



With that being said, it would also depend on the type of "algorithm" you are trying to create here. I would need to know more about that specifically to determine if the Splunk query language could handle it. 

0 Karma

vm_molson
Explorer

Thanks!

So it would just be weighting the input of certain values... it would be cars * 2.6, people * 0.001, packages *.25 to come up with a result.. then looking the result up in a table to determine which size ferry (to extend the example) to take.

0 Karma

jdunlea
Contributor

Yup that could work!

Do you need help with crafting the rest of the search?

0 Karma
Get Updates on the Splunk Community!

Announcing Scheduled Export GA for Dashboard Studio

We're excited to announce the general availability of Scheduled Export for Dashboard Studio. Starting in ...

Extending Observability Content to Splunk Cloud

Watch Now!   In this Extending Observability Content to Splunk Cloud Tech Talk, you'll see how to leverage ...

More Control Over Your Monitoring Costs with Archived Metrics GA in US-AWS!

What if there was a way you could keep all the metrics data you need while saving on storage costs?This is now ...