Tag Archives: Java

Almost Useless Top Tip for Today: Lombok @RequiredArgsConstructor

Wiring up Spring Components using @Autowired is convenient but makes testing harder. A better solution is passing dependencies in through a constructor. However, that means creating a constructor. Lombok to the rescue with the @AllArgsConstructor annotation which will create a … Continue reading

Posted in Programming | Tagged , , | Leave a comment

Spring Slueth Stops JMSListener Consuming Messages

Adding the following dependency causes JMS messages to stop being consumed. <dependency> <groupId>org.springframework.cloud</groupId> <artifactId>spring-cloud-starter-sleuth</artifactId> <version>2.1.0.RELEASE</version> </dependency><dependency> <groupId>org.springframework.cloud</groupId> <artifactId>spring-cloud-starter-sleuth</artifactId> <version>2.1.0.RELEASE</version> </dependency> The issue is that Spring Sleuth prevents the JMSListener from being registered as per: Jms listeners not running To fix … Continue reading

Posted in Programming | Tagged , , | Leave a comment

August Jozi JUG – Docker and MongoDB

Want to learn all about Docker? Then come to the August Jozi JUG! RSVP and details on Meetup. New to Java and keen on learning about MongoDB? The Next Gen talk is just for you! RSVP and details on Meetup.  

Posted in Event | Tagged , | Leave a comment

HMAC SHA512 in Java

When doing some research on authentication tokens I came across the post Don’t Hash Secrets and learn’t of a few new things, one of which was HMAC: Hash-based message authentication code. I use Google Guava for some utility functions, but … Continue reading

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

Unit Testing WebMethods Services With JUnit

Unit tests are ubiquitous (or at least should be) amongst software projects. Some environments are easier to unit test than others, and WebMethods is somewhere in the middle. As the services run on a server and the tests in your … Continue reading

Posted in Programming, Software AG | Tagged , , , | 3 Comments

May Jozi JUG – The Google Guava Libraries

If you’re in the Joburg area and are interested in Java, head over to the May Jozi JUG session on 27 May: Mohamed Akoojee will be discussing various aspects of Google guava libraries and going through some code, working through … Continue reading

Posted in IT, Programming | Tagged , , , | Leave a comment

No Content To Map To Object Due To End Of Input

If you’re using Jersey JAX-RS and get the error “No content to map to Object due to end of input” when your service is called, it may be because you’re attempting to pass in a JSON object while using a … Continue reading

Posted in Programming | Tagged , , , , , | 6 Comments

Single jQuery Ajax Call Results In Two Requests

I implemented simple performance monitoring for a JavaScript/Java application I’m building. This involved writing a Servlet Filter that calls Java Simon code. The Java Simon console application was recording two entries for every single Ajax request that was being made. … Continue reading

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

June 2012 Gauteng User Group Events

Jozi JUG -Why Functional Programming Matters Event website Monday, June 25, 2012 Internet Solutions, The Chill Room, The Campus, Sloane Street, Bryanston Andreas Pauley will be giving us an introduction to functional programming: what it is in essence, how it … Continue reading

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

Glassfish 3: Space In Custom Resource Name Causes Error

I mistakenly added a custom JNDI resource in Glassfish through the administration console with a space in the name. It was ‘application_configuration /download-token’. The space caused an error when the JNDI>Custom Resource page loaded: REST Request ‘http://localhost:4848/management/domain/servers/server/server/resource-ref/application_configuration+%2Fdownload-token’ failed with response … Continue reading

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