Fix connection bug problem in JSON api

A timer is used to close the connection after 500ms to force the
closing. This has to be done because lighttpd mod_proxy keeps the
connection open regardless of the Connection: close; header.
ecore_con_client_del() was als called directly in the
ECORE_CON_EVENT_CLIENT_WRITE event call. This was wrong, and led to data
not being correctly written to client. Now a timer is used to close the
connection _after_ data has been sent, and _only_ if client has not
closed connection by himself.