<div dir="ltr">We should consider data segment,Why NDN protocol to consider it , just like IP?<div><br></div><div>Sorry for make this email divided into two parts.</div><div><br></div><div>Thank you for Junxiao. </div><div><br></div><div>yours,qhsong</div><div><br></div></div><div class="gmail_extra"><br><div class="gmail_quote">2015-08-03 15:44 GMT+08:00 ndn ndn <span dir="ltr"><<a href="mailto:ndn@sqh.me" target="_blank">ndn@sqh.me</a>></span>:<br><blockquote class="gmail_quote" style="margin:0 0 0 .8ex;border-left:1px #ccc solid;padding-left:1ex"><div dir="ltr">Dear Junxiao,<div>After seen your email, I test my program again. I found I have something wrong in my memory. The problem isn't crash, It just <b>gives me a exception message</b>. I make a mistake. Sorry for that.</div><div><br></div><div>Limit the content payload in half of <span style="font-size:14px">practical limit can not make best efficient in transmission.Why not to set a function  to get the max content payload? As a application programmer, We shoul</span></div></div><div class="HOEnZb"><div class="h5"><div class="gmail_extra"><br><div class="gmail_quote">2015-08-03 10:34 GMT+08:00 Junxiao Shi <span dir="ltr"><<a href="mailto:shijunxiao@email.arizona.edu" target="_blank">shijunxiao@email.arizona.edu</a>></span>:<br><blockquote class="gmail_quote" style="margin:0 0 0 .8ex;border-left:1px #ccc solid;padding-left:1ex"><div lang="EN-US"><div><p>Hi Qihan</p><p><u></u> <u></u></p><p><span style="font-family:Consolas">face.getMaxNdnPacketSize()</span> gives the practical limit of NDN packet length.</p><p>For a Data packet, this length not only includes the Content payload, but also includes the Name, MetaInfo, and Signature.</p><p>There’s no general algorithm to compute the limit of payload size, because Signature is generated after Content is prepared, and theoretically its length can depend on the Content (although all defined signing algorithms don’t do that).</p><p>In most cases, <b>it’s safe to limit your Content payload to be half of that practical limit</b>.</p><p><u></u> <u></u></p><p><u></u> <u></u></p><p>On the other hand, I notice a problem in ndn-ccl-api description for getMaxNdnPacketSize:</p><p align="left" style="text-align:left"><span style="background:white">This is a static method to get the practical limit of the size of a network-layer packet. If a packet is larger than this, the library or application MAY drop it.</span></p><p>This description permits the library to drop the packet when limit is exceeded instead of crashing, but you are observing a crash.</p><p>You may file a bug on the Redmine site of the specific library you are using (eg. ndn-cpp).</p><p><u></u> <u></u></p><p>Yours, Junxiao</p><p><u></u> <u></u></p><div style="border:none;border-top:solid #e1e1e1 1.0pt;padding:3.0pt 0in 0in 0in"><p style="border:none;padding:0in"><br><b>From: </b>ndn ndn<br><b>Sent: </b>Sunday, August 2, 2015 06:21<br><b>To: </b><a href="mailto:ndn-interest@lists.cs.ucla.edu" target="_blank">ndn-interest@lists.cs.ucla.edu</a><br><b>Subject: </b>[Ndn-interest] How to calculate max data bytes per packet?</p></div><div><div><p class="MsoNormal"><span style="font-family:"Times New Roman",serif"><u></u> <u></u></span></p><p class="MsoNormal"><span style="font-family:"Times New Roman",serif"><u></u> <u></u></span></p><div><div><p class="MsoNormal"><span style="font-size:12.0pt;font-family:"Times New Roman",serif">Hello everyone,</span><span style="font-size:12.0pt;font-family:"Times New Roman",serif"><u></u><u></u></span></p></div><p class="MsoNormal"><span style="font-size:12.0pt;font-family:"Times New Roman",serif">Recently,I want to send a large packet via NDN.When I using NDN-CCL,face.getMaxNdnPacketSize() can get the max packet size in NDN network.<u></u><u></u></span></p><div><p class="MsoNormal"><span style="font-size:12.0pt;font-family:"Times New Roman",serif">But I use data.setContent() to set face.getMaxNdnPacketSize() bytes data,the program crashed,it tells me the size of data is too large than max NDN packet size.<u></u><u></u></span></p></div><div><p class="MsoNormal"><span style="font-size:12.0pt;font-family:"Times New Roman",serif"><u></u> <u></u></span></p></div><div><p class="MsoNormal"><span style="font-size:12.0pt;font-family:"Times New Roman",serif">So,How to get the max data size I can send?It make me confuse for a long time.<u></u><u></u></span></p></div></div><p class="MsoNormal"><span style="font-size:12.0pt;font-family:"Times New Roman",serif"><u></u> <u></u></span></p><p class="MsoNormal"><u></u> <u></u></p><p class="MsoNormal"><u></u> <u></u></p></div></div></div></div></blockquote></div><br></div>
</div></div></blockquote></div><br></div>