Eclipse Community Forums
Forum Search:

Search      Help    Register    Login    Home
Home » Eclipse Projects » OM2M » Usage of NSCL
Usage of NSCL [message #1403081] Mon, 21 July 2014 08:55 Go to next message
Hao XU is currently offline Hao XUFriend
Messages: 18
Registered: June 2014
Junior Member
Hello,
I have a question on the usage of NSCL. I am confused about the meaning of a NSCL inside the architecture of ETSI M2M.
In the REST API that you have described, the NAs send subscription requests to GSCLs, and the GSCLs send notifications directly to NAs. Even if NAs are registered in the NSCL, but I haven't seen NSCL participate in other procedures.

This is because what you have introduced is a simplified use case?

Thanks for any response.
Re: Usage of NSCL [message #1403812 is a reply to message #1403081] Mon, 28 July 2014 00:53 Go to previous messageGo to next message
Mahdi Ben Alaya is currently offline Mahdi Ben AlayaFriend
Messages: 103
Registered: November 2013
Senior Member
Hello hao,

The NSCL can do all the primitive procedures provided by the GSCL and more, especially that the NSCL knows the ip addresses of all authenticated GSCLs.

Here are some interesting procedures provided by the NSCL:

1) The NSCL acts as proxy to retarget NA requests to the right GSCL. NA sends request to NSCL (e.g GET http://NSCL-IP:NSCL-PORT/om2m/GSCL-ID), NSCL retargets request to GSCL, GSCL sends back response to NSCL, and NSCL retargets back response to NA. The retarget mechanism is seamless for NA. NA don't care of the GSCL IP and port.

2)The NSCL can act as proxy between several GSCLs. If we have GSCL1 and GSCL2 both authenticated to the NSCL, then a sensor connected to GSCL1 is able to send a request to an actuator connected to GSCL2 via the NSCL. GSCL1 don't care of GSCL2 IP and port (and vice versa).

3) NA can create a container on the NSCL, and use it as contactURI to subscribe to GSCL resource. The notifications will be retargeted from GSCL to NSCL and stored on the NA container.

4) A constraint GSCL can announce some applications on the NSCL. Announced resources will be created under NSCL-ID/scls collection. The GSCL benefits of an external data base to store its data. (e.g A smart meter can create all its measuring data on to NSCL)

5) A GSCL can announce some resources on the NSCL to advertise them in order to simplify their discovery by NAs. NAs will easily find, on the NSCL, links to original resources located on the GSCL.

Mahdi
Re: Usage of NSCL [message #1403843 is a reply to message #1403812] Mon, 28 July 2014 09:04 Go to previous messageGo to next message
Hao XU is currently offline Hao XUFriend
Messages: 18
Registered: June 2014
Junior Member
Hello Mahdi Ben Alaya:
Thanks for your response.
For the first procedure that you have described, e.g GET http://NSCL-IP:NSCL-PORT/om2m/GSCL-ID: "om2m/" is the sclBaseContext of NSCL? This type of uri is defined like this in specification of ETSI M2M?
Re: Usage of NSCL [message #1403852 is a reply to message #1403843] Mon, 28 July 2014 09:45 Go to previous messageGo to next message
Mahdi Ben Alaya is currently offline Mahdi Ben AlayaFriend
Messages: 103
Registered: November 2013
Senior Member
Hello,

Protocol schema, ip, port and context are the protocol-dependent part of the uri used only as a point of contact (POC) to access the SCL server. An SCL can provide severals POCs.
scl-id/path/to/resource is the generic part of the uri used as targeID to identify the resource within the platform. The targetID can be mapped to different POCs. It is even possible to toggle from http to coap.

The context is a specific part that enables to define different listening routes for the same port. It optimizes the server resources.
For example, in OM2M we have two contexts for the same port:
"/" context routes to the resource browser web interface
"/om2m" context routes to the SCL API
"/other" context can be an extension for other services.

ETSI focuses on the targetID and don't define any rule for the context.


[Updated on: Mon, 28 July 2014 10:08]

Report message to a moderator

Re: Usage of NSCL [message #1403858 is a reply to message #1403852] Mon, 28 July 2014 09:55 Go to previous messageGo to next message
Hao XU is currently offline Hao XUFriend
Messages: 18
Registered: June 2014
Junior Member
Thanks very much for your response. It's very clear.
Re: Usage of NSCL [message #1698328 is a reply to message #1403858] Sun, 14 June 2015 00:05 Go to previous messageGo to next message
daniel ebanja is currently offline daniel ebanjaFriend
Messages: 7
Registered: November 2014
Junior Member
Hello Mahdi,

just wanted to ask concerning point number 4 in your reply:
Taking the example of the smart meter, does this mean that the application resource is not created in the corresponding GSCL but only on the NSCL or is it created on both?
Could you please illustrate the announcement mechanism with an example?

Thanks
Re: Usage of NSCL [message #1698595 is a reply to message #1698328] Tue, 16 June 2015 14:57 Go to previous message
Mahdi Ben Alaya is currently offline Mahdi Ben AlayaFriend
Messages: 103
Registered: November 2013
Senior Member
Hello Daniel,

Regarding scenario N°4 (Announcement),
The smart meter application is created locally on the gateway under GSCL/applications/SmartMeter, and an announced smart meter application is created automatically on the server under NSCL/scls/GSCL/applications/SmartMeterAnnc.
So technically yes the application is created in both, however the data is not duplicated. Two benefits here:
- SmartMeterAnnc contains only a link to SmartMeter. This enables to simplify the discovery process so an application can directly find relevant links to applications on the server without the need to search for them in each gateway.
- You can chose to store your Smart Meter data on the server since real containers could be created under an announced application such SmartMeterAnnc.

By default, the announcement is deactivated when creating an application.
You have to add the "announceTo" tag, set "activated" to true, and of course specify the SCL link where you want to announce your application (e.g. nscl).
You can update your application representation like this:

POST http://ip:port/om2m/gscl/applications 

<om2m:application xmlns:om2m="http://uri.etsi.org/m2m" appId="SmartMeter">
  <om2m:announceTo>
    <om2m:activated>true</om2m:activated>
    <om2m:sclList>
       <reference>nscl</reference>
    </om2m:sclList>
  </om2m:announceTo>
</om2m:application>


Then you can retrieve the announced applications on the NSCL under nscl/scls/gscl/applications

GET http://ip:port/om2m/nscl/scls/gscl/applications

<om2m:applications xmlns:om2m="http://uri.etsi.org/m2m" xmlns:xmime="http://www.w3.org/2005/05/xmlmime">
   <om2m:accessRightID>nscl/accessRights/AR_ADMIN</om2m:accessRightID>
   <om2m:creationTime>2014-05-05T12:09:44.683+02:00</om2m:creationTime>
   <om2m:lastModifiedTime>2014-05-05T12:16:11.659+02:00</om2m:lastModifiedTime>
   <om2m:applicationCollection />
   <om2m:applicationAnncCollection>
       <om2m:namedReference id="Heating_App_001Annc">nscl/scls/gscl/applications/SmartMeterAnnc</om2m:namedReference>
   </om2m:applicationAnncCollection>
   <om2m:subscriptionsReference>nscl/scls/gscl/applications/subscriptions</om2m:subscriptionsReference>
    <om2m:mgmtObjsReference>nscl/scls/gscl/applications/mgmtObjs</om2m:mgmtObjsReference>
</om2m:applications>


Best regards,
Mahdi
Previous Topic:OM2M & oneM2M
Next Topic:migrate OM2M bundle to apache felix
Goto Forum:
  


Current Time: Sat Aug 01 22:23:22 GMT 2015

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

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