Splunk Search

Is it possible to leverage view used by other app that doesn't exist in splunkjs/mvc?

rnelson30
Engager

Hi,

I am trying to create a splunk app that mimics as much of the Search and Report functionality as possible with some additional customizations. At the moment I am trying to import the field_extractor view into my application, however I do not see documentation to support incorporating views that do not exist in the splunkjs/mvc directory. 

Is this possible?

Labels (1)
0 Karma
1 Solution

VatsalJagani
SplunkTrust
SplunkTrust

@rnelson30 - I'm guesssing this is a JS file you are referring to (search_mrsparkle/exposed/js/views/search/results/eventspane/fieldsviewer) - there is a Master.js file inside this folder.

Now what I can remember is that what you are trying to do is not documented. And also not probably how it is intended to be used.

 

View solution in original post

0 Karma

rnelson30
Engager

Thank you for the response. That's not exactly what I'm going for. I have a custom application that needs to leverage an existing Splunk view. It exists in: 

search_mrsparkle/exposed/js/views/search/results/eventspane/fieldsviewer

However, since it does not have a corresponding file in splunkjs/mvc like your example above, I am not sure how to incorporate it. 

I hope this provides some clarity. Thanks!

0 Karma

VatsalJagani
SplunkTrust
SplunkTrust

@rnelson30 - I'm guesssing this is a JS file you are referring to (search_mrsparkle/exposed/js/views/search/results/eventspane/fieldsviewer) - there is a Master.js file inside this folder.

Now what I can remember is that what you are trying to do is not documented. And also not probably how it is intended to be used.

 

0 Karma

VatsalJagani
SplunkTrust
SplunkTrust

@rnelson30 - As of what I'm understanding you are trying to add third-party visualization into your dashboard with JavaScript.

This document should be helpful - https://dev.splunk.com/enterprise/tutorials/tutorialcreatecustom/addthirdparty/

Basically in JS, you can need to import JS file for that third-party visualization.

require([
    "/static/app/customviewtutorial/chart.js",
    "splunkjs/mvc",
    "splunkjs/mvc/searchmanager",
    "splunkjs/mvc/simplexml/ready!"
], function( 
    // Keep these variables in the same order as the libraries above:
    chart,
    mvc,
    SearchManager
) {

 

I hope this helps!!!

0 Karma
Get Updates on the Splunk Community!

Enterprise Security Content Update (ESCU) | New Releases

In December, the Splunk Threat Research Team had 1 release of new security content via the Enterprise Security ...

Why am I not seeing the finding in Splunk Enterprise Security Analyst Queue?

(This is the first of a series of 2 blogs). Splunk Enterprise Security is a fantastic tool that offers robust ...

Index This | What are the 12 Days of Splunk-mas?

December 2024 Edition Hayyy Splunk Education Enthusiasts and the Eternally Curious!  We’re back with another ...