[Mini-NDN] [EXT] Sends next request after previously requested files have been received

Junxiao Shi shijunxiao at email.arizona.edu
Thu Sep 17 23:44:28 PDT 2020


Hi Ritu

No, these need to go into a bash script, then invoke the script from Python.
*set -e* is not a flag passed to ndncatchunks, but a separate command
placed just under the shabang line.

Yours, Junxiao


On Thu, Sep 17, 2020, 22:31 Ritu Bordoloi <bordoloi.ritu1988 at gmail.com>
wrote:

> *External Email*
> Dear Junxiao,
>
> Thank you for your quick response.
>
> I tried to follow your suggestion. However, the consumer is not getting
> any files in this case. I am appending my ndncatchunks code below. I think
> I did something wrong there. Can you have a look, please?
>
> host.cmd('ndncatchunks *set -e* /ndn/{}-site/{}/{} | ndndump -v> out{}
> &'.format(hosts[0].name, hosts[0].name, Reqfile, host.name))
>
> Thank you.
>
> Kind regards,
> Ritu
>
>
> On Fri, 18 Sep 2020, 11:51 am Junxiao Shi, <shijunxiao at email.arizona.edu>
> wrote:
>
>> Hi Ritu
>>
>> You can put ndncatchunks commands in a bash script, and invoke the script
>> on the consumer host.
>> On the top of this script, add a *set -e* command. This command causes
>> the script to abort if any command was unsuccessful, which ensures the next
>> retrieval would start only if the previous one succeeds.
>>
>> Yours, Junxiao
>>
>>
>>
>> On Thu, Sep 17, 2020, 21:28 Ritu Bordoloi via Mini-NDN <
>> mini-ndn at lists.cs.ucla.edu> wrote:
>>
>>> *External Email*
>>> Dear All,
>>>
>>> I would like to implement a very simple scenario where a producer
>>> publishes some files and a consumer request for those files. I am using
>>> ndnpuchanks and ndncatchunks commands for publishing and requesting the
>>> files respectively.
>>>
>>> I want the consumer to send the next request once it has successfully
>>> received the previously requested files. Can someone give me an idea on how
>>> to do this?
>>>
>>> Thank you for your help in advance.
>>>
>>> Kind regards,
>>> Ritu
>>>
>>>
-------------- next part --------------
An HTML attachment was scrubbed...
URL: <http://www.lists.cs.ucla.edu/pipermail/mini-ndn/attachments/20200918/4e7a2500/attachment-0001.html>


More information about the Mini-NDN mailing list