Skip to main content


Eclipse Community Forums
Forum Search:

Search      Help    Register    Login    Home
Home » Eclipse Projects » OM2M » CoAP request Option ONEM2M_FRis not working(CoAP request with Option Option(256, "admin:admin") is not working)
CoAP request Option ONEM2M_FRis not working [message #1751366] Mon, 09 January 2017 12:16 Go to next message
Ashok Athukuri is currently offline Ashok AthukuriFriend
Messages: 14
Registered: November 2015
Junior Member
Hello ,

I am trying to retrieve CSE with GET request from CoAP Client:
So I have set request ption(256, "admin:admin")); hoping this will set PrimitiveRequest FROM field

[/code]
request.getOptions()
			   .setContentFormat(MediaTypeRegistry.APPLICATION_XML)
			   .setAccept(MediaTypeRegistry.APPLICATION_XML)
			   .addOption(new Option(256, "admin:admin")); // FROM OPTION



But it seem its not setting because RequestPrimitive From is not called from below Code.

here is the Code in CoAPServer.java

switch (optionsList.get(i).getNumber()) {
			case CoapOptions.ONEM2M_FR:
				requestPrimitive.setFrom(optionsList.get(i).getStringValue());
				break;


I have added a hard Coded line in code
requestPrimitive.setFrom("admin:admin");


Then its working able to retrieve CSE info.

Is there a bug fix done for this? I am using released version of OM2M code.

Thanks for the help.
Ashok
Re: CoAP request Option ONEM2M_FRis not working [message #1751560 is a reply to message #1751366] Wed, 11 January 2017 13:41 Go to previous message
Ashok Athukuri is currently offline Ashok AthukuriFriend
Messages: 14
Registered: November 2015
Junior Member
This is the solution for the problem https://www.eclipse.org/forums/index.php/t/1083645/
Previous Topic:CoAP Authentication in Request Option Bug
Next Topic:Supports for mgmtCmd
Goto Forum:
  


Current Time: Fri Nov 16 01:20:43 GMT 2018

Powered by FUDForum. Page generated in 0.01501 seconds
.:: Contact :: Home ::.

Powered by: FUDforum 3.0.2.
Copyright ©2001-2010 FUDforum Bulletin Board Software

Back to the top