Research Article
A Lightweight Location-Aware Fog Framework (LAFF) for QoS in Internet of Things Paradigm
| Inputs: tasks T, start services S, user u, Geo (coord1, coord2) gets integer based coordinates. | | Output: assign nearest Fog-MMD or Fog-TD to the user. | | start; | | submit tasks; | | place operators; | | start services; | | while allusers do | | getlocation; | | if coord > 10 coord < 50 then | | existing reg user; | | else | | reg as new user; | | end | | if reguser then | | if multimedia data then | | if clocation = = plocation then | | if hard to find then | | start search; | | calculate tasks on nodes (); | | offload data from nearest fognode (); | | allocate fog-MMD; | | F (u, T); | | else | | find nearest fog node; | | Search (F1–>Fn); | | end | | else | | register location; | | Geo (coord1, coord2); | | end | | else | | transfer to fog-TD; | | Fl (uu, T); | | end | | else | | unreg user; | | end | | find idle fog node; | | uu (F1–>Fn); | | send to cloud; | | uu (C, T); | | repeat; | | end |
|