Next week at the SOA4All project first year review (Brussels NESSI office), I will show a prototype of the SOA4All Distributed Service Bus based on PEtALS ESB and on a P2P based library.
Like in every middleware demo, it is always difficult to show something ’sexy’ since exchanging XML messages is not… This time I have a web portal based on GWT which is connected to the Bus which is more funky. The main point is how message are exchanged between PEtALS nodes with P2P and semantic techniques. I think this feature will be available in PEtALS before the end of the project (year 2011), so stay tuned.
PEtALS, soa4all
p2p, PEtALS, soa4all
A Ant java call like :
<target name=”run”>
<java classname=”foo.bar.App” fork=”false”>
<classpath refid=”app.classpath” />
</java>
</target>
becomes :
<target name=”run”>
<java classname=”foo.bar.App” fork=”yes“>
<classpath refid=”app.classpath” />
<sysproperty key=”DEBUG” value=”true” />
<jvmarg value=”-Xrunjdwp:transport=dt_socket,server=y,suspend=y,address=8000″ />
</java>
</target>
and is ready to be launch and ‘remote debugged’ from a tool like Eclipse IDE.
java
java
Here is a quick (and easy) tip on how to handle static resources with Jetty6 (this is really nice and quick to setup such things for a demo ;o)). Here is the code :
1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18
19
20
21
22
23
24
25
26
27
| package foo.bar;
import org.mortbay.jetty.Server;
import org.mortbay.jetty.handler.ContextHandlerCollection;
import org.mortbay.jetty.nio.SelectChannelConnector;
import org.mortbay.jetty.servlet.Context;
/**
* @author Christophe HAMERLING - eBM WebSourcing
*
*/
public class JettyServer {
public static void main(String[] args) throws Exception {
Server server = new Server();
final ContextHandlerCollection contexts = new ContextHandlerCollection();
final Context context = new Context(contexts, "/", Context.SESSIONS);
context.setResourceBase(System.getProperty("user.home"));
context.addServlet("org.mortbay.jetty.servlet.DefaultServlet", "/");
final SelectChannelConnector nioConnector = new SelectChannelConnector();
nioConnector.setPort(1978);
server.addConnector(nioConnector);
server.setHandler(contexts);
server.start();
}
} |
This will display your home directory on http://localhost:1978
Cheers
java
java, jetty
Here are a serie of tips when developing under Mac OS X after mostly 8 years in the Linux word.
First tip : The aliases in the Terminal (because I really think that the Terminal is cool
) )
1. Create a .profile file in your $HOME folder
cd $HOME
touch .profile
2. Add aliases in this .profile file
pico .profile
and then syntax is alias foo=’bar’. For example, here are some of my aliases :
alias tx=’open /Applications/TextEdit.app/’
alias mvn2=’/Users/chamerling/Developpement/bin/mvn/apache-maven-2.0.10/bin/mvn’
alias meclipse=’mvn2 eclipse:eclipse’
alias mpetals=’mvn2 archetype:generate -DarchetypeCatalog=http://petals.ow2.org’
Non classé
mac osx