RestComm / sbc

Restcomm Session Border Controller
http://www.restcomm.com/
21 stars 27 forks source link

Break down REST API for LocationService in multiple APIs #28

Closed deruelle closed 7 years ago

ocarriles commented 7 years ago

@deruelle Does make sense to do a full CRUD api?, just read-only implemented

deruelle commented 7 years ago

I think READ only operations are enough for now. I don't see the need for Create Read and Update. Maybe Delete could be useful for cleanup if some registrations are not cleaned up properly somehow

ocarriles commented 7 years ago

@deruelle LocationService renamed to LocationsEndpoint

ocarriles commented 7 years ago

@deruelle just done, any other requirement for this issue to remain open?

deruelle commented 7 years ago

just done

Did you do a new pull request or commit on that ?

ocarriles commented 7 years ago

@deruelle Location data is now based on AoR (bob@sbc.domain) As a multihome environment, issues still arises when same user try to register to different prospect domains (f.i. bob@sbc.domain.1). Please comment.

deruelle commented 7 years ago

@ocarriles can you describe exactly and potentially with a call flow the issue that still arise ? I'm not sure I got the sbc.domain.1

ocarriles commented 7 years ago

@deruelle Remaining issue is not related to the call flow but to the Location database.

a) SBC offers 2 public services at sbc.domain:5060/UDP and sbc1.domain:5060/TCP b) user bob has a desktop phone that registers to sbc.domain;expires=3600 (bob@sbc.domain) c) user bob has a softphone that registers to sbc1.domain;expires=3600 (bob@sbc1.domain) d) bob@sbc1.domain rewrites backend registration e) bob@sbc.domain will keep its own local registration state alive for the next hour. f) bob@sbc1.domain can make and receive calls g) bob@sbc.domain cannot but already registered h) Locations.size() returns 2

Am I wrong?

deruelle commented 7 years ago

What do you mean by "offers 2 public services at sbc.domain:5060/UDP and sbc1.domain:5060/TCP" ?

shouldn't it be sbc.domain has 2 interfaces 5060/UDP and 5060/TCP ?

if you want to say that 2 devices can register to the same domain and use the same AoR then yes it's possible read https://www.ietf.org/rfc/rfc3261.txt section registrations. The registrar/location database will have 1 AoR and 2 Locations with the IP, port and transport of each device.

ocarriles commented 7 years ago

@deruelle You are right. think I misunderstood AoR concept.