Welcome to my encyclopedia of shitty code!
-
The message with Action ” cannot be processed at the receiver, due to a ContractFilter mismatch at the EndpointDispatcher
PROBLEM You get this error message when invoking a web service:- org.springframework.ws.soap.client.SoapFaultClientException: The message with Action ” cannot be processed at the receiver, due to a ContractFilter mismatch at the EndpointDispatcher. This may be because of either a contract mismatch (mismatched Actions between sender and receiver) or a binding/security mismatch between the sender and the… Read More…
-
Cannot process the message because the content type ‘application/soap+xml; charset=utf-8’ was not the expected type ‘text/xml; charset=utf-8’
PROBLEM You are getting this exception when invoking a web service:- org.springframework.ws.client.WebServiceTransportException: Cannot process the message because the content type ‘application/soap+xml; charset=utf-8’ was not the expected type ‘text/xml; charset=utf-8’. [415] SOLUTION You are using the wrong SOAP version. SOAP v1.1 uses text/xml while SOAP v1.2 uses application/soap+xml. If you are using Spring Web Services, add… Read More…
-
Using Spring Web Services and JAXB to Invoke Web Service Based on WSDL
There are several ways to consume a web service based on a WSDL from Java. After trying a couple of approaches, I’m currently leaning towards Spring Web Services and JAXB. The biggest advantage of using both Spring Web Services and JAXB to consume a web service is the flexibility to change the web service URL… Read More…
-
Configuring Quartz Scheduler to Run in Clustered Environment
The goal of running a Quartz job in the clustered environment is NOT to have duplicate running jobs. The triggered job should run just one time regardless of the number of nodes in the clustered environment. Download Quartz and extract the file. Navigate to quartz-x.x.x -> docs -> dbTables and run the database SQL script… Read More…
-
Managing the Order of AJAX Calls on Input Field’s Keyup Event
SCENARIO Consider the following code:- When user types an employee’s name, “Mike”, in the search field, a web service call is fired per character typed. In this example, the following web service calls are made:- Let’s assume this web service searches the input string against databases (or flat files, Facebook API, etc) and returns a… Read More…
-
Pretty Print JSON in JavaScript
PROBLEM You want to display a JSON object in JavaScript. TAKE 1 While this works, I find this approach inconvenient when viewing the output in Firebug because I have to click on each generated link to view the details. TAKE 2 … will generate this:- This approach will display the entire JSON object as one… Read More…
-
Reading Directory/File’s ACL Directly from Java
Prior to Java 7, there’s no way to read a directory/file’s ACL directly from Java. With Java 7, you can write something like this:- When you execute the code above, you will get something like this:- Read More…
-
Managing Log4j Configuration for Both Development and Production Environments
PROBLEM Most of the time, we set the Log4j’s log levels to something lower (debug or info) during our local development. Once it is ready for production, we normally set the Log4j’s log levels to something higher (warn or even error) to prevent meaningless information from flooding the server log. One way to do this… Read More…
About Author

This author has 20+ years of experience in software engineering and cloud engineering. In an industry where knowledge becomes obsolete in the next three months, he learns anything that crosses his path indiscriminately. He floats from one technology to another like a moth and stings the problem sets like a mosquito. This author codes Java while drinking Espresso and writes Spock specifications while listening to Groovy beats. He masters Google Cloud Platform just like how he masters the art of predicting the movement of dark clouds over his backyard, where 60% of the time, he is right every time.
This author suffers from the Dunning-Kruger effect, where he overestimates his competence and underestimates his ignorance. Technology buzzwords never faze him, for he does not know enough to be afraid of in the first place. GCP, GCS, GCR, GKE, GWT… everything sounds the same to him. He never fears acronyms, synonyms, or antonyms, for he has ChatGPT in his back pocket. This author is a jack of all trades but a master of none. He writes like he knows all the answers, yet he googles for better solutions from elsewhere. He fakes it until he makes it; if he doesn’t, that’s okay because he has the attention span of a squirrel. The blog posts are his buried walnuts, in case he needs them one day.
In conclusion, this author is full of something. He apologizes in advance if you are trying to solve your company’s real problems with his shitty solutions. There, he has successfully written paragraphs of nonsense because every professional blogging website needs a section about the author, with a too-cool-to-smile portrait staring sideways into the abyss.