JSON API and Infinity Data Source tutorial for Grafana | How to display the unemployment rate

แชร์
ฝัง
  • เผยแพร่เมื่อ 12 พ.ย. 2024

ความคิดเห็น • 79

  • @volkovlabs
    @volkovlabs  ปีที่แล้ว +5

    Following the previous JSON API video, we created this detailed tutorial making it possible to work with JSON API open data sets for everyone. Check out the blog post for more details: volkovlabs.io/blog/json-api-data-sources-in-grafana-20230104/
    Now we are working on the business dashboard tutorial. Leave a comment below for what to include.

    • @vinodmahant5486
      @vinodmahant5486 ปีที่แล้ว +1

      Can you please create a video on authentication options for JSON API other than basic auth

    • @volkovlabs
      @volkovlabs  ปีที่แล้ว +1

      @@vinodmahant5486 Do you have any specific options on your mind? Are you using or planning to use JSON API or Infinity Data source? Infinity supports many authentication options out of the box.

    • @vinodmahant5486
      @vinodmahant5486 ปีที่แล้ว +1

      @@volkovlabs Thanks for quick response. I have created a dashboard with JSON API datasource, Now I want to secure my rest api, It works with basic auth but I want to use token based authentication for my use case like Oauth2 or header based authentication (where the auth token periodically changes) (JSON API options: Forward Oauth identity, Custom Http Headers)
      Please suggest ?

    • @volkovlabs
      @volkovlabs  ปีที่แล้ว

      @@vinodmahant5486 JSON API configuration displays native Grafana Authentication options, including "Forward OAuth Identity", but we have not tested it in our projects. JSON API is maintained by Grafana, and I would recommend asking on Community Forum (community.grafana.com/new) if you have any issues.

  • @paakire3918
    @paakire3918 ปีที่แล้ว +1

    Hallelujah!!!
    I can finally do something with Grafana...
    thank you my God (and Mrs. Volcov!!!)

    • @volkovlabs
      @volkovlabs  ปีที่แล้ว

      You are very welcome. Happy for you!

  • @seanarney948
    @seanarney948 ปีที่แล้ว +2

    You guys put together such nice and detailed tutorials without all kinds of fluff - I love it!

    • @volkovlabs
      @volkovlabs  ปีที่แล้ว +1

      We don’t do fluff, straight to the point to answer questions and solve problems. Thank you for follow along.

  • @DevProHub
    @DevProHub 4 หลายเดือนก่อน +1

    Awesome video! Thank you very much! Keep going more about building start time and end time query parameters for API call!

    • @volkovlabs
      @volkovlabs  4 หลายเดือนก่อน

      Glad it helped!

  • @saloniipawar6631
    @saloniipawar6631 6 หลายเดือนก่อน +2

    Hi, Can you please make a video on using json api to fetch json data from an url using Path in Json Api. Please add a global variable in the path too which we can select from a drop down.

    • @volkovlabs
      @volkovlabs  6 หลายเดือนก่อน +1

      Very timely request, I am about to make a video like that. Stay tuned!

    • @saloniipawar6631
      @saloniipawar6631 6 หลายเดือนก่อน +1

      @@volkovlabs great ! Please make it soon. It’s quite urgent requirement for my project.

    • @volkovlabs
      @volkovlabs  6 หลายเดือนก่อน

      @@saloniipawar6631 Take a look at the blog post which covers those topics: volkovlabs.io/blog/form-panel-server-based-elements-20240428/

  • @koushik4531
    @koushik4531 4 หลายเดือนก่อน +1

    Hey thanks of info!
    So After doing post request and getting the output, Can I trigger alerts based on the incoming data.

    • @volkovlabs
      @volkovlabs  4 หลายเดือนก่อน

      Infinity is a backend data source and supports Alerting.

  • @tordthelord
    @tordthelord 2 หลายเดือนก่อน +1

    Great video! Is there someone I can copy the final function from? for the smooth line panel?

    • @volkovlabs
      @volkovlabs  2 หลายเดือนก่อน

      You can find smooth line in the Examples: echarts.volkovlabs.io/d/tg6gWiKVk/line?orgId=1

    • @tordthelord
      @tordthelord 2 หลายเดือนก่อน

      context.panel.data.series.map((s) => {
      if (s.refId === "A") {
      yearA = s.fields.find((f) => f.name === "year").values.buffer;
      monthA = s.fields.find((f) => f.name === "periodName").values.buffer;
      valueA = s.fields.find((f) => f.name === "value").values.buffer;
      }
      });
      const month_yearA = monthA.map((d, i) => `${d} ${yearA[i]}`);
      return {
      grid: {
      bottom: "3%",
      containLabel: true,
      left: "3%",
      right: "4%",
      top: "4%"
      },
      series: [
      {
      data: valueA.reverse(),
      smooth: true,
      type: "line"
      }
      ],
      xAxis: {
      data: month_yearA.reverse(),
      type: "category"
      },
      yAxis: {
      type: "value"
      }
      };

  • @SplitZeroOne
    @SplitZeroOne ปีที่แล้ว +2

    Very clear and concise, great video

    • @volkovlabs
      @volkovlabs  ปีที่แล้ว +1

      Appreciate the feedback.

  • @Playback-in-Life
    @Playback-in-Life 9 หลายเดือนก่อน +1

    Thank you very much for the video. Can you please help me to understand more about variables. Like how can we pass multiple value variables to JSON API params.

    • @volkovlabs
      @volkovlabs  9 หลายเดือนก่อน

      Which plugin are you talking about? Both of them has excellent documentation explaining variables: grafana.com/docs/plugins/yesoreyeram-infinity-datasource/latest/

    • @Playback-in-Life
      @Playback-in-Life 9 หลายเดือนก่อน

      @@volkovlabs JSON api

  • @irkost
    @irkost 2 หลายเดือนก่อน +1

    Hello guys! Thanks for the video. Did you manage to install Infinity datasource plugin in Grafana 11 (I use 11.1.4)? I am in an air-gapped environment, so i download zip file from plugins website, unzip it and copy the folder to /var/lib/grafana/plugins/ inside the container and then I restart the container. The "grafana cli plugins ls" command shows that "yesoreyeram-infinity-datasource @ 2.9.5" plugin is installed. However, I cannot see the corresponding datasource in the "Add new connection" section of the Grafana menu. I did the same on Grafana 10.2.1 instance and everything worked as I expected.

    • @volkovlabs
      @volkovlabs  2 หลายเดือนก่อน

      It's a great question to ask on the Community Forum: community.grafana.com/new. Infinity is popular data source and Community can guide you if logs are not helpful.
      I would recommend to look at the Grafana's startup logs to check that plugin was loaded or not. You may see the reason which prevented data source to load. It may be permission issues.

    • @irkost
      @irkost 2 หลายเดือนก่อน +1

      @@volkovlabs Thanks for the link. I actually managed to install it from zip file using grafana cli. No idea why it didn't work after copying the unzipped folder

    • @volkovlabs
      @volkovlabs  2 หลายเดือนก่อน

      @irkost Glad to hear it worked! As I mentioned, can be permissions.

  • @abrahamlincolnarpula6919
    @abrahamlincolnarpula6919 11 หลายเดือนก่อน +1

    Does the JSON API and Infinity Data Source fetch the data continuously from the rest end point(URL) provided. If not how to fetch data in regular interval of time continuously?

    • @volkovlabs
      @volkovlabs  11 หลายเดือนก่อน

      It's called Streaming in Grafana terms and I have not heard about it in both plugins. Looking at Infinity there is no mention for Streaming in Docs and Issues. You can use Dashboard refresh to refresh on interval. Other option is to use the WebSocket data source, which support streaming.

  • @rabiyabegum1631
    @rabiyabegum1631 10 หลายเดือนก่อน +1

    Can you please help me on how to retrieve two specific fields from the JSON payload of 15 health check URLs and display the data in a single table.
    please note that each of the 15 health check URLs contains the same two specific fields in their JSON payloads.
    Also if possible please let me know how to add variables to dashboard for querying the data

    • @volkovlabs
      @volkovlabs  10 หลายเดือนก่อน

      You can add 15 queries to the panel and then use Merge transformation to combine them together.
      JSON API and Infinity data sources support dashboard variables, check out the documentation on how to use them.

  • @chaimeinav
    @chaimeinav ปีที่แล้ว +1

    thank you very much for this clear and short explanation 👏

    • @volkovlabs
      @volkovlabs  ปีที่แล้ว

      You are welcome! Good luck with your project.
      --
      Daria

  • @praveennaik63
    @praveennaik63 11 หลายเดือนก่อน +1

    @volkovlabs how to add the startyear and endyear dynamically, For example, whatever I select from the time picker it should consider that range? is there any way?

    • @volkovlabs
      @volkovlabs  11 หลายเดือนก่อน

      Time Range' To and From are set in Global Variables which you can use in the Data Sources: volkovlabs.io/grafana/variables/#global-variables

    • @praveennaik63
      @praveennaik63 11 หลายเดือนก่อน +1

      @@volkovlabsHow to use these variables in my API request? The documents you shared me, Didnt help

    • @volkovlabs
      @volkovlabs  11 หลายเดือนก่อน

      @@praveennaik63 I just guessed the answer, because the questions is still not clear. What Data Source do you use and how do you specify start and end year?
      --
      Mikhail

  • @maximilianosalibe1710
    @maximilianosalibe1710 10 หลายเดือนก่อน +1

    Nice explanations and visualizations! One thing I noticed is that both panels switch alternatively between ascending and descending curves (the max and the min change places). I guess it has something to do with the .reverse() method that was called on the data. But why doesn't it stay fixed?

    • @volkovlabs
      @volkovlabs  10 หลายเดือนก่อน

      Good catch! I don't remember the details, it was something wrong in the script. Let me know if you able to reproduce it using the latest version of the plugins.

    • @maximilianosalibe1710
      @maximilianosalibe1710 10 หลายเดือนก่อน +1

      @@volkovlabs I am using a specific release of Grafana (v9.2.1) because of the project I am working in. Perhaps I can check that later in a latest release.

  • @alagappan2214
    @alagappan2214 3 หลายเดือนก่อน

    Hey, How can i send dynamic variables as a parameter to the Infinity data source API?

    • @volkovlabs
      @volkovlabs  3 หลายเดือนก่อน

      Please check out the plugin documentation how to use variables: grafana.com/docs/plugins/yesoreyeram-infinity-datasource/latest/

  • @LakshayChopra-h6v
    @LakshayChopra-h6v 11 หลายเดือนก่อน +1

    can you please let me know how to connect with Elasticsearch endpoint using infinity plugin. Also how to query the _source result as a table view ?

    • @volkovlabs
      @volkovlabs  11 หลายเดือนก่อน

      Have you tried the Elastic Search Data Source? grafana.com/docs/grafana/latest/datasources/elasticsearch/. We recommend to use specific data source is available instead of using custom solution using API Data Sources.
      --
      Mikhail

    • @LakshayChopra-h6v
      @LakshayChopra-h6v 10 หลายเดือนก่อน +1

      @@volkovlabs Thanks for the reply, actually I need to perform generate some dynamic fields based on the existing fields in my response data. For this reason I cannot go ahead with the existing ES data source. Anyways I am able to able to achieve the requirement with Infinity DS but is there any such limitation of why it cannot process more than 10000 records ?

    • @volkovlabs
      @volkovlabs  10 หลายเดือนก่อน +1

      @@LakshayChopra-h6v I am not aware of this limitation. If it's not mentioned in the documentation, please submit an issue in the project repository: github.com/grafana/grafana-infinity-datasource.

  • @sudhagar_rajaraman
    @sudhagar_rajaraman ปีที่แล้ว +1

    Clear and good explanation.. Great work 👍

    • @volkovlabs
      @volkovlabs  ปีที่แล้ว

      Appreciate the feedback. What Data Source you decided to use?

    • @sudhagar_rajaraman
      @sudhagar_rajaraman ปีที่แล้ว +1

      @@volkovlabs I'm using influx DB as data source for my grafana dashboard

  • @sowmyasastry1455
    @sowmyasastry1455 ปีที่แล้ว +1

    How do I create a dashboard using these plugins on grafana installed in the Kubernetes cluster. I want to automate so that every time a new pod is created, the dashboard should be already configured.

    • @volkovlabs
      @volkovlabs  ปีที่แล้ว

      Use Provisioning: th-cam.com/video/sGHKY0VmbLw/w-d-xo.html

  • @LearningWithNisa
    @LearningWithNisa 8 หลายเดือนก่อน +1

    thank you for detailed explaination. I have one question , I am using garfana for visualization i want to do a task in which data is filtered by using garfana tool. and send to the algorithm written in python which finds the clusters and send back processed data to garfana (store in database). is there any way to do such task? thanks. looking forward to hear from youl

    • @volkovlabs
      @volkovlabs  8 หลายเดือนก่อน

      Check out the Data Manipulation panel

  • @LuCkY-sq7ge
    @LuCkY-sq7ge 11 หลายเดือนก่อน +1

    i have a API which has historical data and i can get history/5d history/1h history/1w for example. Is it possible to use the grafana timefilter and dynamically request the correct history endpoint? (i get 20 data points out)

    • @volkovlabs
      @volkovlabs  11 หลายเดือนก่อน +1

      Grafana's Time Range To and From values can be accesses using Global Variables `${__from}` and `${__to}`. You can use them in the URL or Payload to request the data.

    • @DevProHub
      @DevProHub 4 หลายเดือนก่อน

      Great to hear that! Could you please create video for that?

  • @MrGh0sT_8124
    @MrGh0sT_8124 ปีที่แล้ว +1

    Thank you for the video, I am using grafana to display Wazuh REST api data into tables or charts. By using both plugins I manage to connect and pull data from api. But all data (json format) is coming into one line in grafana. Is there any way to put data into table format or other charts?

    • @volkovlabs
      @volkovlabs  ปีที่แล้ว

      Both plugins support parsing JSON data into separate columns and rows. Check the documentation for Infinity how to parse JSON: sriramajeyam.com/grafana-infinity-datasource/docs/json

    • @MrGh0sT_8124
      @MrGh0sT_8124 ปีที่แล้ว +1

      @@volkovlabs thank you for the reply and documentation

    • @volkovlabs
      @volkovlabs  ปีที่แล้ว +1

      @@MrGh0sT_8124 Happy Dashboarding!

  • @kotipallisriram7756
    @kotipallisriram7756 ปีที่แล้ว +1

    Thank you very much for your video, one quick question I am using json api to fetch the incident count from Pagerduty to display it in Grafana dashboard everything is working fine but i am not able to give default value for last 24hours data. As of now i am using "since" in param and giving last day date. Tried adding now() also but its fetching last month data. Any suggestion please 🥺

    • @volkovlabs
      @volkovlabs  ปีที่แล้ว +1

      Good question. I am not familiar with Pagerduty API and can't comment on the parameters. I would recommend to ask in Community Forum: community.grafana.com
      --
      Mikhail

  • @AnunPoochuensee
    @AnunPoochuensee ปีที่แล้ว +1

    Hello, I am a starter grafana developer, After install Infinity or JSON API i can't use and there are message "Alerting not supported" Please help or suggestion me many thanks.

    • @volkovlabs
      @volkovlabs  ปีที่แล้ว

      Alerting not supported means that the JSON API is a frontend only plugin and you can't create Alerts based on it. Infinity has a backend and it can be used for Alerts. What do you mean you can't use?

  • @robertpeirce5533
    @robertpeirce5533 6 หลายเดือนก่อน +1

    Are you able to assist me in parsing XML data using Infinity as the datasource. I can GET the raw data using the URL in Grafana using Infinity, but I have not been successful at parsing any of it.

    • @volkovlabs
      @volkovlabs  6 หลายเดือนก่อน

      Infinity Data source is well documented in the Documentation: grafana.com/docs/plugins/yesoreyeram-infinity-datasource/latest/.
      Also, Grafana Forum is a great place to get advice for the Infinity Data Source: community.grafana.com

  • @fortheloveoffood9258
    @fortheloveoffood9258 2 หลายเดือนก่อน +1

    Hello, what do I do if infinity is not available to download?

    • @volkovlabs
      @volkovlabs  2 หลายเดือนก่อน

      What do you mean is not available? Using direct connection to Internet? You can download archive manually and extract it in the plugin folder.

  • @Dallascalo
    @Dallascalo ปีที่แล้ว +1

    Thank you. Helpful video.

    • @volkovlabs
      @volkovlabs  ปีที่แล้ว

      Glad if helped! Do you use JSON API or Infinity?

  • @paakire3918
    @paakire3918 ปีที่แล้ว +1

    Sorry for the double msg (parkinson symptoms)

  • @vladgnatenko3573
    @vladgnatenko3573 ปีที่แล้ว +1

    would it matter if my grafna runs locally? doesn't work for me for some reason

    • @volkovlabs
      @volkovlabs  ปีที่แล้ว

      Are you connecting using Frontend (Browser) or Backend (Grafana Server) mode? Check the Browser -> Console -> Network for the specific error to troubleshoot further.
      --
      Mikhail

    • @vladgnatenko3573
      @vladgnatenko3573 ปีที่แล้ว +1

      @@volkovlabs thank you for your help, ther ewas a problem with json api with 8.2.0 when running in the docker, pulled latest image of graphana and everything worked like magic. Awesome work, used couple graphs from echart

    • @volkovlabs
      @volkovlabs  ปีที่แล้ว

      Glad to hear!

  • @paakire3918
    @paakire3918 ปีที่แล้ว +1

    Hallelujah!!!
    I can finally do something with Grafana...
    thank you my God (and Mrs. Volcov!!!)

    • @volkovlabs
      @volkovlabs  ปีที่แล้ว

      What is your use case? What do you want to accomplish with Grafana?