It is good practice to use the with keyword when dealing with file objects. This has the advantage that the file is properly closed after its suite finishes, even if an exception is raised on the way. It is also much shorter than writing equivalent try-finally blocks.
Python multithreading. NOTE that although multiple threads can run within the python interpreter, ONLY one thread is being executed by the interpreter at any given time, which is ensured by the GIL (global interpreter lock) in python virtual machine. Python multithreading is more appropriate for I/O-bound applications than for CPU-bound applications as I/O releases GIL.
Java okhttp client trustall certificate (for test only).
In Java, static fields and static methods are common but how about static class? Here is an example.
A working example on how to config postfix with gmail smtp server to send email directly from linux command line and tested on vagrant vm with ubuntu precise 32.
Java multithreading programming demo.
How to pretty print json usually for better visibility.