Moving lots of logic into server interface