Skip to content

Instantly share code, notes, and snippets.

---
web:
context: /cr
queues:
test.queue.bri:
remote_host: 192.168.1.58
topics:
test.topic.bri:
remote_host: 192.168.1.58
messaging:
Float add(Float x)(Float y) {
return x+y;
}
Float addOne(Float y) = add(1.0);
Float three = addOne(2.0);
@peteroyle
peteroyle / gist:958297
Created May 6, 2011 01:25
AsynchronousInterceptor
/*
* JBoss, Home of Professional Open Source
* Copyright 2008, Red Hat Middleware LLC, and individual contributors
* by the @authors tag. See the copyright.txt in the distribution for a
* full listing of individual contributors.
*
* Licensed under the Apache License, Version 2.0 (the "License");
* you may not use this file except in compliance with the License.
* You may obtain a copy of the License at
* http://www.apache.org/licenses/LICENSE-2.0
@peteroyle
peteroyle / gist:967545
Created May 11, 2011 22:39
buiding forge from git
[INFO] 1error
[INFO] -------------------------------------------------------------
[INFO] ------------------------------------------------------------------------
[INFO] Reactor Summary:
[INFO]
[INFO] Forge - Shell API ................................. FAILURE [4.258s]
[INFO] Forge - Maven Integration APIs .................... SKIPPED
[INFO] Forge - Git Integration ........................... SKIPPED
[INFO] Forge - Parser/Java ............................... SKIPPED
[INFO] Forge - Maven Project Model ....................... SKIPPED
@peteroyle
peteroyle / gist:969969
Created May 13, 2011 04:28
SeamReports Example Usage
@Qualifier
public @interface Selected {
}
@RequestScoped
public class ReportOptions {
public String reportName;
public String format;
@peteroyle
peteroyle / gist:975911
Created May 17, 2011 03:53
Injecting Precompiled Reports using @resource
@Produces @JasperReports @Resource
public Report precompileJasperReport(InjectionPoint ip) {
JasperSeamReportLoader loader = new JasperSeamReportLoader();
Report report = null;
for (Annotation ant : ip.getQualifiers().iterator()) {
if (ant is a @Resource) {
Resource r = (Resource)ant;
InputStream is = getClassloader().getResourceAsStream(r.value());
report = loader.compile(is);
}
@peteroyle
peteroyle / gist:978086
Created May 18, 2011 06:35
proposed module struture
parent
- combined
- dist
- docs
- api
- impl (depends on api)
- spi (depends on impl)
- providers
- scheduling
- quartz (depends on spi)
@peteroyle
peteroyle / gist:990065
Created May 25, 2011 00:36
Unsatisfied Dependency Injecting Properties
------------- Standard Output ---------------
test.jar:
/cron.properties
/META-INF/
/META-INF/beans.xml
/org/
/org/jboss/
/org/jboss/seam/
/org/jboss/seam/cron/
/org/jboss/seam/cron/spi/
@peteroyle
peteroyle / gist:1048438
Created June 27, 2011 07:18
Fedora 15 Appliance Config
name: fedora_15_jeos
summary: Just Enough Operating System based on Fedora
appliances:
- common
os:
name: fedora
version: 15
password: password
hardware:
cpus: 2
@peteroyle
peteroyle / gist:1048439
Created June 27, 2011 07:19
Boxgrinder Trace Building Fedora 15 in AMI
[root@ip-10-128-190-144 boxgrinder]# boxgrinder-build fedora_15_jeos.appl
/usr/lib/ruby/gems/1.8/gems/aws-2.5.5/lib/ses/../awsbase/utils.rb:105: warning: already initialized constant HEX
/usr/lib/ruby/gems/1.8/gems/aws-2.5.5/lib/ses/../awsbase/utils.rb:107: warning: already initialized constant TO_REMEMBER
/usr/lib/ruby/gems/1.8/gems/aws-2.5.5/lib/ses/../awsbase/utils.rb:108: warning: already initialized constant ASCII
/usr/lib/ruby/gems/1.8/gems/aws-2.5.5/lib/ses/../awsbase/errors.rb:128: warning: already initialized constant DEFAULT_CLOSE_ON_4XX_PROBABILITY
/usr/lib/ruby/gems/1.8/gems/aws-2.5.5/lib/ses/../awsbase/parsers.rb:47: warning: already initialized constant DEFAULT_XML_LIBRARY
/usr/lib/ruby/gems/1.8/gems/aws-2.5.5/lib/ses/../awsbase/awsbase.rb:66: warning: already initialized constant AMAZON_PROBLEMS
/usr/lib/ruby/gems/1.8/gems/aws-2.5.5/lib/ses/../awsbase/awsbase.rb:86: warning: already initialized constant DEFAULT_SIGNATURE_VERSION
I, [2011-06-27T02:57:38.252638 #1204] INFO -- : Validating appli