In this paper two alternative architectures for service management in IoT and sensor networks are discussed. The first one is based on Open Service Gateway (OSGi) framework and Remote Services for OSGi (R-OSGi) bundle. The second architecture extends the notion of REST (Representational State Transfer) paradigm. There were few purposes of the extension. First, efficient, dynamic searching for devices capable of fulfilling certain requests within actual context was enabled. Second, both the devices and controlling services were distributed. Next, the devices were orchestrated in order to provide complex functionality. Finally, the access to the devices' functionality was standardized. OSGi-based solution was found simpler and better suited for homogeneous sensor networks, while more complex REST-based framework appeared as better suited for heterogeneous and widely distributed IoT devices and services.