ITeye博客

asianboycn

asianboycn · 共 41 篇文章

webservice implementation

1. generate jaxb from wsdl <groupId>org.apache.axis2</groupId> <artifactId>axis2-wsdl2code-maven-plugin</artifactId> 2. implement SkeletonInterface to write the real web servcie class @WebService(name = "xxx_V1_0", portName = "xxx_SOAP11_Port_HTTP", serviceName = "xxx_V1_0", targetNamespace = "http…

2015-02-12 12:58 · Web service · 评论(0)

Java Signature

to verfiy a sinature Byte 1. You need public key and private key pair KeyPairGenerator kpg = KeyPairGenerator.getInstance("RSA"); kpg.initialize(1024); KeyPair keyPair = kpg.genKeyPair(); 2. to sign using private key Signature sig = Signature.getInstance("MD5WithRSA"); sig.initSign(keyPair.getPriva…

2014-10-31 08:25 · 评论(0)

not include maven folder in jar file

add to relevant plugin when building. <archive> <addMavenDescriptor>false</addMavenDescriptor> </archive>

2014-10-12 04:32 · 评论(0)

websphere create scheduler

EAR project WEB project Hashtable<String, String> env = new Hashtable<String, String>(); env.put(Context.INITIAL_CONTEXT_FACTORY, "com.ibm.websphere.naming.WsnInitialContextFactory"); InitialContext = new InitialContext(env); Scheduler scheduler = (Scheduler)ic.lookup("scheuler_JNDI"); BeanTaskInfo…

2014-10-10 00:02 · EJB · 评论(0)

websphere app server vs mq

Here is a good article taking about Websphere SIBus vs websphere MQ - SIBus is an websphere application server integrated messaging system - MQ is seperated message system http://www.ibm.com/developerworks/websphere/library/techarticles/1109_wallis/1109_wallis.html http://guide.webspheremq.fr/docs/…

2014-10-01 08:14 · 评论(0)

How to use AspectJ at pom file

1. Defined dependencies aspectjrt, and aspectjweaver (search maven yourself) 2. setup aspectj-maven-plugin to compile class at <phase>process-classes</phase><goal>compile</goal>

2014-09-24 08:44 · AspectJ · 评论(0)

jax-ws wsimport generate java from wsdl

working version is as follows as long as you have binding file and wsdl & xsd file ready in the correction folder: <plugin> <groupId>org.jvnet.jax-ws-commons</groupId> <artifactId>jaxws-maven-plugin</artifactId> <version>2.2</version> <executions> <execution> <phase>compile</phase> <goals> <goal>ws…

2014-09-12 12:56 · Web service · 评论(0)

Jaxb2 plugin to avoid xmlelementwrapper

<plugin> <groupId>org.jvnet.jaxb2.maven2</groupId> <artifactId>maven-jaxb2-plugin</artifactId> <version>0.8.1</version> <executions> <execution> <id>jaxb-generate</id> <goals> <goal>generate</goal> </goals> <configuration> <!-- using xmlElementWrapper feature not to generate wrapper class --> <args…

2014-09-12 09:42 · JAXB · 评论(0)

Using was6-maven-plugin to generate ejb stub

to configure th plugin, add the following to your build plugin. <plugin> <groupId>org.codehaus.mojo</groupId> <artifactId>was6-maven-plugin</artifactId> <version>1.2</version> <executions> <execution> <phase>validate</phase> <goals> <goal>ejbdeploy</goal> </goals> </execution> </executions> <config…

2014-09-12 09:36 · EJB · 评论(0)

maven generate customised mojo using annotation

1. create your own Mojo java class with annotation @Mojo(name = "sayhi") public class MyMojo extends AbstractMojo { @Parameter(property="sayhi.location") // seems not working private String outputDirectory; // use this exact name when initialize in configure ... } 2. in the pom, pay attention the f…

2014-09-12 09:33 · Maven · 评论(0)

jaxb binding file sample

TO COMPILE Schema 1. Create JAXB binding file as follows <jxb:bindings version="1.0" xmlns:jxb="http://java.sun.com/xml/ns/jaxb" xmlns:xs="http://www.w3.org/2001/XMLSchema"> <jxb:bindings schemaLocation="file:///@XSD_ROOT_DIR@/../xxxxxx.xsd" node="/xs:schema"> <jxb:globalBindings> <jxb:javaType nam…

2011-12-01 07:00 · XML · Web service · 评论(0)

SCWCD Notes

response.getPrintWriter() & getOutputStream() can not be called on same instance twice, otherwise throw IllegalStateException sendRedirect() can not be called if response is commited/flushed, otherwise exception will be thrown tell browser to get resource from another location ServeletContext -> ge…

2011-10-01 08:11 · Front End · 评论(0)

SCBCD Notes

Client can NOT call EJB direct, but through mediator JMS in case of MDB(Message Driven Bean) Container provides class implementing bean's interface: component interface & home interface Instance of class implementing component interface is called EJBObject client call EJB through two player: EJBObj…

2011-10-01 08:08 · EJB · 评论(0)

XSL Notes

XSL : document vs root http://www.dpawson.co.uk/xsl/sect2/root.html#d9799e301

2011-08-25 13:43 · XML · 评论(0)

Understand PortletPreferences

Reference http://www-10.lotus.com/ldd/portalwiki.nsf/dx/Preference_layers_and_portlet_modes_wp7 Will add details later.

2011-07-15 07:35 · Portlet · 评论(0)