Skip to content

Instantly share code, notes, and snippets.

View lucasponce's full-sized avatar

Lucas Ponce lucasponce

View GitHub Profile
filterer.rb:192:
puts "DELETEME scope: #{scope}"
if scope == LiveMetric
scope = scope.all
end
puts "DELETEME conditions: #{conditions}"
puts "DELETEME include_for_find: #{include_for_find}"
puts "DELETEME options[:order]: #{options[:order]}"
10:30:00.108 [main] TRACE o.i.t.t.EmbeddedTransaction - Created new transaction with Xid=EmbeddedXid{, globalTransactionId = [B0x93E7F7E7D8C69EA5..[64], branchQualifier = [B0x93E7F7E7D8C69EA5..[64]}
10:30:00.108 [main] TRACE o.i.c.i.CacheImpl - Implicit transaction started! Transaction: EmbeddedTransaction{xid=EmbeddedXid{, globalTransactionId = [B0x93E7F7E7D8C69EA5..[64], branchQualifier = [B0x93E7F7E7D8C69EA5..[64]}, status=0}
10:30:00.108 [main] TRACE o.i.t.i.TransactionTable - Created a new local transaction: LocalTransaction{remoteLockedNodes=null, isMarkedForRollback=false, lockedKeys=[], backupKeyLocks=[], topologyId=-1, stateTransferFlag=null} org.infinispan.transaction.synchronization.SyncLocalTransaction@3c
10:30:00.108 [main] TRACE o.i.i.i.InvocationContextInterceptor - Invoked with command PutKeyValueCommand{key=Event-28026b36-8fe4-4332-84c8-524e173a68bf-non-existence-trigger-1498206594719-de05162d-5f26-437d-94ca-664e5574fb14, value=IspnEvent{eventType='ALERT', tenantId='28026b36-8fe4-4332-84c8-52
package main
import (
"fmt"
)
type Tree struct {
Left *Tree
Value int
Right *Tree
@lucasponce
lucasponce / gist:79eeb36f646e6b1db0ce587c3ba9049e
Created January 9, 2018 08:36
Golang example for debugging a concurrency scenario
package main
import (
"fmt"
)
type Tree struct {
Left *Tree
Value int
Right *Tree
@lucasponce
lucasponce / gist:28acb79f6f10fbefce32c9a0e53a8294
Created February 2, 2018 11:23
Error installing preferences service
[lponce@attilan preferences]$ oc get pods -w
NAME READY STATUS RESTARTS AGE
customer-1565913741-prxzh 2/2 Running 0 9m
preferences-1101835085-2qbjl 1/2 ImagePullBackOff 0 4m
preferences-1101835085-2qbjl 1/2 ErrImagePull 0 6m
preferences-1101835085-2qbjl 1/2 ImagePullBackOff 0 6m
preferences-1101835085-2qbjl 1/2 ErrImagePull 0 11m
[lponce@attilan ~]$ oc logs pod/preferences-1101835085-2qbjl -c istio-proxy
ERROR: logging before flag.Parse: I0202 11:10:09.313341 1 main.go:70] Version root@cc5c34bbd1ee-0.4.0-24089ea97c8d244493c93b499a666ddf4010b547-dirty
<<<<<<< HEAD
=======
it('renders envoy degraded', () => {
const health: Health = {
envoy: { healthy: 1, total: 10 },
deploymentStatuses: [{ name: 'A', available: 1, replicas: 1 }, { name: 'B', available: 2, replicas: 2 }],
requests: { requestCount: 0, requestErrorCount: 0 }
};
// SMALL
import * as React from 'react';
import Badge from '../../components/Badge/Badge';
import InOutRateTable from '../../components/SummaryPanel/InOutRateTable';
import RpsChart from '../../components/SummaryPanel/RpsChart';
import { SummaryPanelPropType } from '../../types/Graph';
import * as API from '../../services/Api';
import * as M from '../../types/Metrics';
import graphUtils from '../../utils/Graphing';
import { getAccumulatedTrafficRate } from '../../utils/TrafficRate';
import MetricsOptions from '../../types/MetricsOptions';
Total in 131 ms
Watching for changes in /home/lponce/git/kiali.io/{content,data,layouts,static,themes}
Serving pages from memory
Running in Fast Render Mode. For full rebuilds on change: hugo server --disableFastRender
Web Server is available at http://localhost:1313/ (bind address 127.0.0.1)
Press Ctrl+C to stop
Change detected, rebuilding site
2018-09-04 13:35:45.531 +0200
Source changed "/home/lponce/git/kiali.io/content/features/_index.adoc": CREATE
[lponce@attilan kiali-test-mesh]$ make openshift-deploy-kiali-test-depth
About to deploy Kiali Test Depth to OpenShift
ansible-playbook ./test-service/deploy/ansible/deploy_test_meshes.yml -e deployment_type=Deployment -e number_of_apps=1 -e number_of_services=1 -e number_of_versions=1 -e number_of_namespaces=1 -e '{"meshes": ["kiali-test-depth"]}' -v
Traceback (most recent call last):
File "/home/lponce/git/ansible/bin/ansible-playbook", line 67, in <module>
import ansible.constants as C
File "/home/lponce/git/ansible/lib/ansible/constants.py", line 17, in <module>
from ansible.config.manager import ConfigManager, ensure_type, get_ini_config_value
File "/home/lponce/git/ansible/lib/ansible/config/manager.py", line 16, in <module>
from yaml import load as yaml_load
@lucasponce
lucasponce / IstioWizard.tsx
Created January 17, 2019 13:24
Template for IstioWizard based in Patternfly 3 React (minimal example to get familiar with the subcomponents)
import * as React from 'react';
import { Button, Icon, Wizard } from 'patternfly-react';
type Props = {
show: boolean;
onClose: () => void;
};
type State = {
showWizard: boolean;