Improve batch mechanism - 3rd try

Diff from 2nd one:
 . Integrated Andrew and Tyler's suggestion on batchIn script and function prototypes declaration in headers;
 . Fix a CMake Error on RHEL6 by preventing it to check the sanity of CXX compiler for the oBIX project
Probably we can think about bettering the words used in the BATCH.md regarding the non-support of watch.pollChanges and history handlers.

Due to their current implementation, these handlers send back responses by themselves therefore there is no chance for their caller to integrate their responses into an external batchOut contract. Therefore breaching the requirement that the batchOut contract should contain responses for each respective requests in the batchIn contract.

From this perspective we have not fully supported or implemented the batch mechanism to raise whatever POST requests.

Harry


How did I do? 1-click feedback: https://secure.teamhively.com/welcome/rate/7672
________________________________
From: Andrew Ross [notifications@github.com]
Sent: Thursday, October 30, 2014 11:29 AM
To: ONEDC/obix
Cc: Harry Cao
Subject: Re: [obix] Improve batch mechanism - 3rd try (#101)


In docs/BATCH.md:

> +handlerWatchDelete | Yes
> +handlerWatchAdd | Yes
> +handlerWatchRemove | Yes
> +handlerWatchPollRefresh | Yes
> +handlerWatchPollChanges      | No
> +handlerHistoryGet | No
> +handlerHistoryQuery  | No
> +handlerHistoryAppend | No
> +handlerBatch | No
> +
> +
> +
> +In the first place, a batch request should not be allowed to nest within another otherwise a malicious batch request with thousands of level of sub batch requests nested altogether can easily consume the stack memory of relevant oBIX server thread handling such request.
> +
> +In the second place, all history handlers take care of sending back responses by themselves which are likely too massive to be sent via a batchOut contract. As a matter of fact, responses of history handlers are designed not to be sent back via obix_sever_reply_object(). Moreover, history data are sent independently from the batchOut contract, infringing relevant requirement in the oBIX specification.
> +


Are we saying our implementation of history batch commands breaks the oBIX spec?

—
Reply to this email directly or view it on GitHub<https://github.com/ONEDC/obix/pull/101/files#r19583635>.


The information contained in this email and any attachments may be confidential. This email and any attachments are also subject to copyright. No part of them may be reproduced, adapted or transmitted without the written permission of the copyright owner. If you are not the intended recipient, any use, interference with, disclosure or copying of this information is unauthorised and prohibited. If you have received this email in error, please immediately advise the sender by return email and delete the message from your system. All email communications to and from NEXTDC Limited are recorded for the purposes of archival and storage.