Skip to content

Instantly share code, notes, and snippets.

View dsyer's full-sized avatar

Dave Syer dsyer

View GitHub Profile
@dsyer
dsyer / reactor.md
Created June 2, 2014 14:10
FRP Notes

Notes on Reactive Programming

Reactive Programming is sexy (again) and a lot of people are making a lot of noise about it at the moment, not all of which is very easy to understand for an outsider and lowly enterprise Java developer like me. These notes are what I came up with to help me clarify my understanding of what the noise is about. I have tried to keep them as concrete as possible, and promise not to mention "denotational semantics" because I don't have a higher degree in Computer Science (and if I did it's hard to see how it would help). If you are looking

@dsyer
dsyer / wipe.md
Last active August 29, 2015 14:05
Notes on WebInvocationPrivilegeEvaluator in Java config

From WebSecurityConfigurerAdapter.init(WebSecurity):

public void init(final WebSecurity web) throws Exception {
  final HttpSecurity http = getHttp();
  web
    .addSecurityFilterChainBuilder(http)
    .postBuildAction(new Runnable() {
      public void run() {
 FilterSecurityInterceptor securityInterceptor = http.getSharedObject(FilterSecurityInterceptor.class);

Keybase proof

I hereby claim:

  • I am dsyer on github.
  • I am dsyer (https://keybase.io/dsyer) on keybase.
  • I have a public key whose fingerprint is 032D F42A 76D3 4CD8 DE76 BEFC 257D 4510 E2E1 1827

To claim this, I am signing this object:

java.lang.IllegalArgumentException: null
at sun.reflect.NativeConstructorAccessorImpl.newInstance0(Native Method)
at sun.reflect.NativeConstructorAccessorImpl.newInstance(NativeConstructorAccessorImpl.java:62)
at sun.reflect.DelegatingConstructorAccessorImpl.newInstance(DelegatingConstructorAccessorImpl.java:45)
at java.lang.reflect.Constructor.newInstance(Constructor.java:408)
at org.springframework.beans.BeanUtils.instantiateClass(BeanUtils.java:147)
at org.springframework.data.convert.ReflectionEntityInstantiator.createInstance(ReflectionEntityInstantiator.java:76)
at org.springframework.data.convert.ClassGeneratingEntityInstantiator.createInstance(ClassGeneratingEntityInstantiator.java:83)
at org.springframework.data.mongodb.core.convert.MappingMongoConverter.read(MappingMongoConverter.java:251)
at org.springframework.data.mongodb.core.convert.MappingMongoConverter.read(MappingMongoConverter.java:231)
This is a simple Spring Batch demo project that pulls data from a
database and then outputs it to a flat file. It uses (Hibernate) JPA
and an embedded HSQL DB. Includes all dependencies in the a lib directory.
package org.springframework.amqp.rabbit.core;
import static org.junit.Assert.assertEquals;
import static org.junit.Assert.assertNotNull;
import org.apache.commons.logging.Log;
import org.apache.commons.logging.LogFactory;
import org.junit.Assume;
import org.junit.Before;
import org.junit.Rule;
target
bin
.classpath
.project
.settings
.springBeans
.DS_Store
*.sw*
@dsyer
dsyer / .gitignore
Created January 17, 2011 11:23
Test project for ActiveMQ topic memory usage
target
activemq-data
bin
.settings
.classpath
.project
@dsyer
dsyer / .gitignore
Created January 22, 2011 12:38
BATCH-1651 test code
target
bin
.settings
.classpath
.project
derby*
embedded*
testcase.zip
lib
@dsyer
dsyer / wtpfix.sh
Created April 9, 2011 09:29
Shell script to fix WTP projects (WAR and JAR)
#!/bin/sh
if [ "$1" = "-h" -o "$1" = "--help" -o "$1" = "-?" ]; then
echo 'Usage: $0 <directory>'
echo ' Fix the WTP configuration in the specified directory and all subdirs.'
echo ' Any file named .classpath is patched to remove excluding="**"'
echo ' (useful for non wtp projects that were generated by m2e).'
echo ' WTP JAR modules are detected by searching for'
echo ' .settings/org.eclipse.wst.common.component in a non-war project.'
echo ' JAR modules are patched to setup .project and .settings correctly'