Explore >> Select a destination


You are here

blog.scaledcode.com
| | www.stackchief.com
1.4 parsecs away

Travel
| | Java multithreading examples including two ways of multithreading, good examples, avoiding deadlock, and how many threads can run.
| | initialcommit.com
5.0 parsecs away

Travel
| | Since String is immutable, it is very costly to use it when constructing a dynamic character string due to the fact that a new memory location will be allocated at each assignment or modification.
| | www.craigpardey.com
4.4 parsecs away

Travel
| | Spring 3.2 has some very nice features for scheduling tasks. The pure Java way of doing this looks something like private ScheduledExecutorService executor = Executors.newSingleThreadScheduledExecutor(); class ScheduledTask implements Runnable { @Override public void run() { System.out.println("Running scheduled task"); } } // Schedule a task every 5 seconds executor.scheduleAtFixedRate(new ScheduledTask(), 1, 5, TimeUnit.SECONDS); // If you don't do this then the JVM won't exit cleanly executor.shutdown(); But now, with the snazzy new Spring scheduling annotations, it can be as simple as this
| | blog.cleancoder.com
14.6 parsecs away

Travel
|