For some reason on the Serverside the content-length is 0 even though this Header was send and recieved.
By adding connection.setChunkedStreamingMode(); when sending a POST solved the issue, however I stil don't know why it's not working with the content-length Header.