Skip to content

Instantly share code, notes, and snippets.

View namoshizun's full-sized avatar
👋

Di Lu namoshizun

👋
View GitHub Profile
@namoshizun
namoshizun / heatmaply_click_workaround.R
Created September 26, 2018 06:38
Use plotly's default source name to capture click event on heatmaply
library(heatmaply)
library(shiny)
library(plotly)
ui <- fluidPage(
titlePanel("Old Faithful Geyser Data"),
mainPanel(
plotlyOutput(outputId = 'heatmap')
)
import React from 'react';
import { useState, useEffect } from 'react'
function App() {
const [count, setCount] = useState(0)
// Should print the latest count a render happens
console.log(count)
useEffect(() => {
console.log('In effect')
---
apiVersion: v1
kind: ConfigMap
metadata:
name: metricbeat-daemonset-modules
namespace: kube-system
labels:
k8s-app: metricbeat
data:
system.yml: |-
[
{
"database": "load_planner",
"index": "saas-base",
"nodes": {
"table": "saas_api_user",
"schema": "public",
"columns": [],
"transform": {
"rename": {
import time
import random
from elasticapm import Client, instrument
from elasticapm.base import get_client as get_apm_client
from elasticapm.contrib.celery import register_exception_tracking, register_instrumentation
from elasticapm.traces import execution_context
from celery import Celery
from celery.canvas import group