Skip to content

Instantly share code, notes, and snippets.

@esfand
esfand / .excludes
Created March 9, 2013 08:07 — forked from dwayne/.excludes
# Exclude files that don't need to be on the server
# Used by rsync when deploying code to the server
.excludes
.git
.gitignore
log/
tmp/
@dlhartveld
dlhartveld / ObservableTest.java
Created February 28, 2013 15:16
A few simple test cases for the Observable from https://gist.github.com/dlhartveld/5057313. Uses JUnit and Mockito.
package com.hartveld.examples;
import static org.mockito.Mockito.verify;
import static org.mockito.Mockito.verifyNoMoreInteractions;
import java.util.function.Consumer;
import org.junit.Test;
import org.junit.runner.RunWith;
import org.mockito.Mock;
import org.mockito.runners.MockitoJUnitRunner;
@ProLoser
ProLoser / alerts.html
Last active October 9, 2019 18:38
AngularJS Bootstrap implemented without any additional code
<h1>Alert</h1>
<p>Bootstrap JS</p>
<div class="alert fade in">
<button type="button" class="close" data-dismiss="alert">×</button>
<strong>Holy guacamole!</strong> Best check yo self, you're not looking too good.
</div>
<p></p><a ng-click="alert=true">Open Alert (AngularJS)</a></p>
<div class="alert fade" ng-class="{in:alert}">
<button type="button" class="close" ng-click="alert=false">×</button>
@esfand
esfand / gist:2260989
Created March 31, 2012 08:52 — forked from joliver/gist:1311195
NServiceBusCommitDispatcher
public sealed class NServiceBusCommitDispatcher : IPublishMessages
{
private const string AggregateIdKey = "AggregateId";
private const string CommitVersionKey = "CommitVersion";
private const string EventVersionKey = "EventVersion";
private const string BusPrefixKey = "Bus.";
private readonly IBus bus;
public NServiceBusCommitDispatcher(IBus bus)
{
@esfand
esfand / tutorial.rst
Created February 9, 2012 18:49 — forked from mojavelinux/tutorial.asciidoc
JBoss Java EE workshop

JBoss Java EE workshop

This tutorial steps through creating, testing and deploying an application using the JBoss Java EE tools and runtimes. You can show up with nothing but Java and a passion to learn. By the end, you'll have a full application running in the cloud.

Here's the development stack we'll be using:

  • OpenShift Express
  • git
  • JBoss Forge
@zephiransas
zephiransas / .gitignore
Created December 28, 2011 01:26
Websocket Test
.classpath
.project
.settings/*
target
@jbrisbin
jbrisbin / gist:1444077
Created December 7, 2011 18:50
Reactor-based framework versus Node.js streaming

I've been hacking away recently at a JVM framework for doing asynchronous, non-blocking applications using a variation of the venerable Reactor pattern. The core of the framework is currently in Java. I started with Scala then went with Java and am now considering Scala again for the core. What can I say: I'm a grass-is-greener waffler! :) But it understands how to invoke Groovy Closures, Scala anonymous functions, and Clojure functions, so you can use the framework directly without needing wrappers.

I've been continually micro-benchmarking this framework because I feel that the JVM is a better foundation on which to build highly-concurrent, highly-scalable, C100K applications than V8 or Ruby. The problem has been, so far, no good tools exist for JVM developers to leverage the excellent performance and manageability of the JVM. This yet-to-be-publicly-released framework is an effort to give Java, Groovy, Scala, [X JVM language] developers access to an easy-to-use programming model that removes the necessity

@dsyer
dsyer / .gitignore
Created October 26, 2011 16:28
Dave Syer: Demos for s2gx2011
target/
*/src/main/*/META-INF/
.access_token
.result
.classpath
.project
.DS_Store
.settings/
*.iml
*.iws
@tbroyer
tbroyer / Address.java
Created January 15, 2011 00:29
Before/after GWT 2.1 Editors
package net.ltgt.gwt.samples.editors.shared;
public class Address {
private String street;
private String city;
private String zip;
private String state;
public String getStreet() { return this.street; }