This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
def MyClass | |
module Transactional | |
def delete_them | |
db.delete | |
end | |
end | |
# this looks for a transaction module, introspects the methods, | |
# adds new methods to MyClass which create transactions and then calls |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
#! /bin/sh | |
# Generic script for running ruby scripts as daemons using | |
# jsvc and a java class to control the daemon. | |
# | |
# Contains common parameters and start/stop | |
# Things you'll need to set on a per script/daemon basis: | |
# SCRIPT_NAME | |
# | |
# Things you can set: |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
public class JRubyDaemon implements Daemon { | |
private Ruby runtime; | |
private Thread thread; | |
private RubyModule appModule; | |
private boolean debug; | |
private RubyModule daemon; | |
public void init(DaemonContext arguments) throws Exception { |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
include java | |
def benchmark(warmups, loops, &block) | |
(0...warmups).map do | |
start_time = java.lang.System.currentTimeMillis | |
(0...loops).each { yield } | |
time = java.lang.System.currentTimeMillis - start_time | |
$stdout.write("#{time},") | |
time | |
end |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
profile = 'lc' | |
bitrates = [96, 128, 160] | |
files = Dir['*.wav'] | |
prog = '~/lib/nero/linux/neroAacEnc' | |
bitrate_control = ['br', 'cbr'] | |
files.each do |fname| | |
bitrates.each do |rate| | |
bitrate_control.each do |bc| |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
<?xml version="1.0"?><tsung loglevel="info"> | |
<clients> | |
<client host="localhost" use_controller_vm="true" maxusers="10000"/> | |
</clients> | |
<servers> | |
<server port="80" type="tcp" host="staging.playlouder.com"/> | |
</servers> | |
<load> | |
<arrivalphase phase="1" unit="minute" duration="3"> | |
<users unit="second" arrivalrate="200"/> |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
package com.msp; | |
import java.math.BigDecimal; | |
import java.sql.ResultSet; | |
import java.sql.ResultSetMetaData; | |
import java.sql.SQLException; | |
import java.sql.Time; | |
import java.sql.Timestamp; | |
import org.jruby.Ruby; |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
diff --git a/modules/jenkins/manifests/cli.pp b/modules/jenkins/manifests/cli.pp | |
index ca44571..e4d1233 100644 | |
--- a/modules/jenkins/manifests/cli.pp | |
+++ b/modules/jenkins/manifests/cli.pp | |
@@ -8,17 +8,26 @@ class jenkins::cli { | |
fail("Use of private class ${name} by ${caller_module_name}") | |
} | |
- $jar = '/usr/lib/jenkins/jenkins-cli.jar' | |
- $extract_jar = 'unzip /usr/lib/jenkins/jenkins.war WEB-INF/jenkins-cli.jar' |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
{"test":"json","has":"purpose"} |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
bridge name bridge id STP enabled interfaces | |
pactbr1 8000.3e04027bdac7 no veth1pl10020 | |
veth1pl12905 | |
veth1pl3761 | |
veth1pl5487 |
OlderNewer