WIP: internals changed to Java8 time api. Rest api not changed yet.