Java

Building a WS-SOAP Proxy with Mule ESB

A common integration scenario is that a company/organisation has a old internal web-service that they want to expose as a public interface.
Often these internal services have a less than ideal interface which is often auto-generated from some business logic so you do not want to simply expose the existing contract. Instead we want to have a interface more suited for use by external entities. However it is not always practical or possible to rewrite the internal service.

The solution is to build a SOAP proxy with transformation.

Building Mule ESB CE

I found the guides available on mulesoft.org a bit cluttered when it came to how to build the Mule ESB from source.

First of it's the matter of finding the source. Following the guide lines in the official guide you see that it's the SVN repository on codehaus that is the main repo. There is a repository on github however this seems to just be a mirror that does not follow the main repository very well. The trunk is pretty much empty and it seems the branches/mule-3.3.x is where all the action is.

Converting keystores between JKS and P12

From TECH BLOG FOR EJBCA ENTERPRISE OPEN SOURCE PKI's articel Converting keystores between JKS and P12.


Johan dug up these keytool commands, that with in JDK6 and onwards (not in JDK5 and earlier).

JKS → P12

keytool -importkeystore -srckeystore keystore.jks -srcstoretype JKS  -deststoretype PKCS12 -destkeystore keystore.p12

P12 → JKS

Tags: 

Provide one datasource with two different JNDI names in JBoss

While testing your JBoss service it can be very handy to use DefaultDS as your data source. However you will probably not want to hardcode this JNDI name into your code, jboss-server.xml, web.xml or persistence.xml (depending on service you write). There you want to use your own "MyAppDS" JNDI name. So wouldn't it be sweet to be able to bind two different JNDI names to the same datasource ?

It is possible and quite simple however I could not really find any good example while Googling the problem. So here is a short description how I solved my problem.

Tags: 

Using JavaSVN beta with Subclipse

== Why ? ==
The beta version of JavaSVN (1.1.0 beta 4) has support for the ''file://'' protocol.

== Prerequisite ==
# [http://www.eclipse.org Eclipse] 3.x
# Install the latest version of [http://subclipse.tigris.org/ subclipse].
# Donwload the standalone release ot [http://tmate.org/svn/download/ JavaSVN 1.0.1 Beta 4].

== Install ==
Copy '''''ganymed.jar''''' and '''''javasvn.jar''''' from the JavaSVN beta zip to '''''/plugins/org.tigris.subversion.subclipse.core_1.0.3/lib''''' overwriting files with the same name.

Use PC Speaker from Java

Getting the PC speaker to emit a annoying beep might seem to be a quite easy task. And it is provided that you are in a graphical environment such as [http://www.x.org/ X.org] och [http://www.microsoft.com/windows/ MS Windows™]. Then using this easy bit of code will do:

package beeptest;
 
import java.awt.Toolkit;
 
public class BeepTest {
        public static void main(String[] args) {
                try {
                        Toolkit.getDefaultToolkit().beep();
                } catch (Exception e) {
                        e.printStackTrace();
                }
        }
}
Tags: 

JUCpio

== Project summary ==
[http://subversion.pontus.ullgren.com/JUCpio/ SVN]

== What is JUCpio ? ==

JUCpio stands for Java Util CPIO and is a set of classes (a API) for reading and writing cpio files.

It is designed to be similar to [http://java.sun.com/j2se/1.5.0/docs/api/java/util/zip/package-summary.html java.util.zip].

The primary reason I started this project was to learn more about the CPIO file format. The API is currently in a very early stage of development.

== Features ==
=== Implemented ===
* Gives a interface to extract data from cpio files.

Digest The Tortoies And The Hare

== The Tortoies And The Hare ==
I was looking for a API that could help me create a data driven model for a application I was writting at work. Since it was a Java application I turned my eyes towards [http://jakarta.apache.org Jakarta] (a true saviour for us Java coders) and found [http://jakarta.apache.org/commons/digester/ Jakarta Digester]. It seemed to full fill all that I needed. So I took it for a spin.

Pages