Skip to content

Instantly share code, notes, and snippets.

$client = new Zend_Http_Client('http://example.org');
$client->setHeaders('X-Trace', oboe_get_context());
$response = $client->request();
oboe_set_context($response->getHeader('X-Trace'));
ubuntu@ip-192-168-0-246:~$ cat supervisord.conf
[supervisord]
nodaemon=true
[program:tracelyzer]
command=/etc/init.d/tracelyzer start -D
[program:apache2]
command=/usr/sbin/apache2 -DFOREGROUND
var tv = require('traceview');
tv.traceMode = 'always';
var express = require('express');
var app = express();
var cb0 = function (req, res, next){
console.log('cb0');
next();
@adam-hert
adam-hert / hello.py
Last active March 3, 2016 22:10
Python_Start_Trace
import oboe
from oboeware import loader
loader.load_inst_modules()
oboe.config['tracing_mode'] = 'always'
#start a trace
oboe.start_trace('Backend', keys=None, xtr=None)
# Do some 'work'
<html>
<head>
<script type="text/javascript" src="http://d1g52r1j47671p.cloudfront.net/spa-timing.js"></script>
<script type ='text/javascript'>
//define Your RUM key
var key = 'Your_key_here';
//Define the tracer and appName
var tracer = new Tracer({
rumKey: key,
@adam-hert
adam-hert / Tomcat+custom instrumentation.txt
Created March 15, 2016 18:19
Tomcat6 + custom instrumentation
//instructions for instrumenting a tomcat app and adding custom instrumentation
apt-get update
//Install the needfull java stuff
apt-get install -y tomcat6 ant openjdk-7-jdk
//install traceview base package
wget files.appneta.. yada yada yada
//install java instrumentation
@adam-hert
adam-hert / HelloTrace.java
Created April 8, 2016 21:12
Instrument a non-servlet java application
/**
* The HelloTrace class is an example of how to instrument a non-servlet java application
* simply traces "Hello World!" to standard output.
*/
//import the tracelytics-api.jar (/usr/local/tracelytics/tracelytics-api.jar)
import com.tracelytics.api.ext.*;
class HelloTrace {
public static void main(String[] args) {
//Start a trace (In a servlet, we do this automatically at the start of the request)
@adam-hert
adam-hert / javaagent.json
Last active June 24, 2016 17:48
agent.urlSampleRates
{
"agent.logging":"info",
"agent.tracingMode":"always",
"agent.traceAjax":false,
"agent.jdbcInstAll":false,
"agent.jdbcInstParams":true,
"agent.jdbcSanitize":0,
"monitor.jmx.interval":30000,
"monitor.jmx.scopes":
; Configuration file for AppNeta TraceView PHP instrumentation via the
; `oboe.so` extension. For help configuring the extension, please visit:
; https://support.appneta.com/cloud/configuring-php-instrumentation
extension=oboe.so
[oboe]
; oboe.tracing: When traces should be initiated for incoming requests. Valid
; options change behavior when the incoming request is already part of a trace:
; "always" - Continue existing traces, otherwise attempt to start a new one.
<?php
print('hello');
?>