On this second day at Code One I have again visited interesting sessions. One on security by Jim Manicode and one on cash (or the lack thereof) in Sweden.
— Read more... →This year I’m returning to Oracle Code One (formerly JavaOne) for the third time. I’m planning to write some notes on interesting sessions or other content.
— Read more... →When you’re writing Java applications, chances are you’re using Maven for dependency management. It lets you declare the artifacts you need to build your application. Those artifacts also depend on other artifacts. This means you have transitive dependencies - dependencies you didn’t declare yourself but you need them anyway.
— Read more... →When you want to transmit binary files over SOAP-based webservices, you have two choices: Base64 or Message Transmission Optimization Mechanism (MTOM). The latter is much more efficient, but also harder to troubleshoot if it doesn’t work at once.
Both options have their own typical scenario
As a primer, let’s have a quick look at how “regular” SOAP requests look when transmitted over HTTP. Imagine we have a file upload webservice which accepts files in any format, along with a file name. If we were to upload a file, the request might look like this.
— Read more... →Recently, Twitter brought the renaming of Ozark to Krazo to my attention. It pulled my attention: I had never heard of either projects, and I wondered what they would be about. Ozark (or Krazo) will be the Reference Implementation of the new Model-View-Controller Specification. This MVC specification, also known as JSR 371, was planned for inclusion in Java EE 8, but eventually dropped. Apparently, this didn’t kill the effort. I was curious to see where the specification (and it’s implementation) would be now.
— Read more... →There are many situations when you need to write a SOAP-based webservice. Maybe you are writing a test dummy, or maybe you got the interface from some kind of architect. (Yes, there are other reasons, too.) And chances are you’ll be using Spring-WS to do this.
Recently I was doing that, and I found the following inside the interface definition (WSDL):
<element name="faultMessage" type="common:FaultMessage"/>
<message name="faultMessage">
<part name="faultMessage" element="tns:faultMessage"/>
</message>
<portType name="someName">
<operation name="searchOrder">
<input message="tns:searchOrderRequest"/>
<output message="tns:searchOrderResponse"/>
<fault name="faultMessage" message="tns:faultMessage"/>
</operation>
</portType>
That was a rather challenging thing! In case the operation would fail, it should give a SOAP Fault with a custom element in it:
— Read more... →Recently, my co-worker Willem pulled my attention to the .NET Microservices. Architecture for Containerized .NET Applications e-book. Although I have a strong background in Java and the Java platform, I started reading it, and soon I felt like trying it out. But building software without having automated builds and tests is not the real thing, so that was the first thing I wanted to do. I usually use CircleCI for that, but unfortunately they don’t seem to have an official guide for that.
— Read more... →Often, the size of a code base is measured in terms of “source lines of code” (SLoC).
If you’re interested in the size of your code base - or your client is - this metric provides a way to express that size.
Of course, comments and the like are not considered to be code, so how to determine this metric?
Using grep
is tempting, but it quickly results in a very complex and hard-to-understand approach.