Tag: java
-
Support multiple JDKs in Debian Linux
With the relatively recent change in the frequency of Java releases (every six months) it has become pretty much required to be able to have multiple JDKs on one’s development machine, and being able to run/test them at different times, for different projects, or even for the same project. Motivation While some wizardry with symlinks […]
-
Annoying Java Popup when Testing Apache Mesos
Running unit tests for Apache Mesos, enabling Java (i.e., omitting the –disable-java flag in configure) you may run into the annoying “You need to install Java” popup, even though you have Java 8 correctly installed. The only workaround I’ve found so far (until I locate where in the test scripts we invoke the wrong version […]
-
Do Not Allow Bad Smells In Your Code
Smelly Code I have recently been involved in a distributed SaaS application that was originally built by an offshore team; the chosen technologies (REST, Java, MongoDB) were actually valid technical choices for the problem at hand: they then proceeded to get it spectacularly wrong with a bloated (and unmanageable) data schema and an even worse […]
-
Data-driven tests for Spring Data (MongoDB)
When testing a project that uses Spring Data repositories, we may want to insert ‘known-good’ data into arbitrary MongoDB collections, reading it, for example, from JSON iles (typically somewhere in the test/resources subtree). However, some of the data stored in Mongo is in BSON format, which extends the plain JSON format with some Object types […]
-
Code Reviews
As anyone who has worked with me is well aware, I’m a great believer in code reviews – there is much to be said about a number of positive impacts on the project (and the developers’ professional growth too). This is a great article that sums up very well the benefits, as well as a […]
-
AWS re:Invent – my notes (post 2 of 3)
Note – the first post (Notes about the AWS JDK) can be found here The following are the (minimally edited) notes I’ve taken while attending the session at AWS re:Invent conference in Las Vegas, NV on 27-30 November, 2012. Keynote speech by Andy Jassy (Sr. Vice President, Amazon Web Services) It is clear we are still at […]
-
Four Principles of Cloud Computing
From Werner Vogels (Amazon.com CTO) keynote speech at re:Invent: ControllableArchitect with cost in mind ResilientDon’t treat failure as an exception AdaptiveMake no assumptions Data DrivenPut everything in logs
-
Run Android tests in a connected device
Not quite sure as to why it never occurred to me, but it is totally possible and legal to run unit tests inside a real device, connected to your dev box via a USB cable.An obvious advantage is that you are now running your tests in a more “realistic” environment; there are no drawbacks that […]
-
Dump CPU temperature data to a file in Ubuntu
Update: I’ve figured out that it makes a lot more sense to have a reading of the CPU load to correlate with the temperature reading, so I’ve added that too using /usr/bin/uptime.I have written a very simple Java utility to take readings from the CPU temperature sensors utility (/usr/bin/sensor) and dump it to a CSV […]