Webapp big refactor

#348
add javadoc documentation