Why background task? There are tons of examples where we often need to run a task in background e.g. sending an email, sms or notification, writing some log in file etc. If a task is not required to maintain atomicity and can be executed after some delay, it's a good candidate to run in background. How to run tasks in background in Java? In Java, the easiest way to run a task in background is to create a new thread and execute it. It's quite simple. Here is how to do this: new Thread(new Runnable(){ @Override public void run(){ // your background task } }).start(); It's easy! But there are some maintenance problem with the above code. The major problem is - there is no way to control how many background tasks we want to run simultaneously. For example, if 1000 users registers in your application at a time and you create 1000 background threads to send them a confirmation email, maybe you'll be in trouble. So you ne...
I would recommend to check the following on the topic:
ReplyDelete* https://softwarerecs.stackexchange.com/questions/867/self-hosted-replacement-for-github
* http://www.artificialworlds.net/blog/2014/07/15/what-git-server-should-i-use/
Thank you for your comment
DeleteThanks for mentioning RhodeCode! Please check it out again, we just released version 3.0 which added server-side merges, has the most flexible pull request system including voting and a completely new user interface.
ReplyDeleteBest,
Sebastian (RhodeCode CEO)