Category Archives: Java

MySql UTF8 character set

MySQL database has two implementations for utf8 character set: utf8 (As of MySQL 4.1) utf8mb4 (As of MySQL 5.5) In this writing, I am going to explain the difference between these two character set and how you can store data … Continue reading

Posted in Java, MySql | Tagged , , , , , , , , , | Leave a comment

Injecting List with Spring from yaml

In my recent project, I need to fill a list from configuration file. With my old habits I just tried to use @Value annotation and my code just broke. Here is what I’ve tried first: application.yaml: AppRunner.java: However, it just … Continue reading

Posted in Java | Tagged , , , , , , , , , , , , | Leave a comment

Adding New Library To Maven Repository

Sometimes, you find a custom library on the internet, or create it by yourself for something special. Probably, you cannot find those kind of libraries in maven repositories and add your maven dependencies for your maven based projects. But, if … Continue reading

Posted in Java | Tagged , , , , , | Leave a comment

How To Authenticate Http Level Provided Web Service

In this post, I will give you a code for to consume web services with protected http basic authentication. I pretend that, there is a web service called SimpleWebService and it has a method that called getDummy. Here is the … Continue reading

Posted in Java | Tagged , , , , , , | Leave a comment

Web Service Application Level Authentication

In some situations we need to protect our private data, so we may want to use authentication mechanism for our web services. In this writing, I will give you an example to how you can create web service authentication level … Continue reading

Posted in Java | Tagged , , , , , , , | Leave a comment

Logging SOAP Web Service Request and Response

In this writing, I will talk about how to log soap request and response xml’s in Java. I used a free weather webservice as a sample for this post. I created a GlobalWeather.jar using JAX-WS from this wsdl. If you … Continue reading

Posted in Java | Tagged , , , , , , , , | 19 Comments

Creating WebService Client with WsImport (Jax-WS)

WsImport is a powerful way to create Java Classes for web services. It is supported by the jdk’s higher than 1.5. We can easily create web service clients using wsimport executable file that comes with jdk installation. Below command create … Continue reading

Posted in Java | Tagged , , , , , , , , | Leave a comment