寻址 Home- communicato通信模型 home Mobile agent Se erver communicator 本地/外来 agent 2/4/2021 Institute of Computer Software, Nanjing University
Home-communicator通信模型 16 communicator home 本地/外来agent Mobile agent Server 2/4/2021 Institute of Computer Software, Nanjing University 16
寻址 Home 记录该节点上“出生”的 agent的动态信息 发生 agent迁移时,需要即时信息更新 Agent迁移必须通知其“home” 频繁的迁移会导致Home的通信量增加 Home[ Mogent「 Mogent Home Mogent Mogent Communicator Communicator Communicator one【 ogent[ Mogent 2/4/2021 Institute of Computer Software, Nanjing University
Home: ▪ 记录该节点上“出生”的agent的动态信息 ▪ 发生agent迁移时,需要即时信息更新 ▪ Agent迁移必须通知其“home” ▪ 频繁的迁移会导致Home的通信量增加 17 2/4/2021 Institute of Computer Software, Nanjing University 17
寻址 Communicator. 记录当前Hos上的所有 agent的信息 Agent迁移时应该 register& unregister 例 mogentManager. Register(mogent mogentManager. un Register(mogent); 2/4/2021 Institute of Computer Software, Nanjing University 18
Communicator: ▪ 记录当前Host上的所有agent的信息 ▪ Agent迁移时应该register & unregister ▪ 例: mogentManager.Register(mogent); mogentManager.unRegister(mogent); 18 2/4/2021 Institute of Computer Software, Nanjing University 18
寻址 寻址示例: Agent A→B:send(B,M) A、B同在一个节点:本地通信 A的名:A:20211936170/002:2021936131 B的名:B:202.19:36.136/1o027:202.119.36.131 A、B不在一个节点:远程通信 A的名:A:202.1936.17o/10o2:202,19.36130 B的名:B:202.19:36.136/1o027:202.119.36135 2/4/2021 Institute of Computer Software, Nanjing University
寻址示例: ▪ Agent A → B:send(B,M) ▪ A、B同在一个节点:本地通信 ▪ A的名:A:202.119.36.170/10022:202.119.36.131 ▪ B的名:B:202.119.36.136/10027:202.119.36.131 ▪ A、B不在一个节点:远程通信 ▪ A的名:A:202.119.36.170/10022:202.119.36.130 ▪ B的名:B:202.119.36.136/10027:202.119.36.135 19 2/4/2021 Institute of Computer Software, Nanjing University 19
寻址 A: send(B, M) A:202.119.36.170/100232:202.11936.131 B:202.119.36.136100247:202.119.36131 A B 202.119.36.131 得到B,M 查B在本节点 将M交给B Agent列表: A:202.119.36.170100232:202.119.36.131 B:202.119.36.136/100247:202.119.36.131 2/4/2021 Institute of Computer Software, Nanjing University
20 202.119.36.131 Agent列表: A:202.119.36.170/100232:202.119.36.131 B:202.119.36.136/100247:202.119.36.131 A:202.119.36.170/100232:202.119.36.131 B:202.119.36.136/100247:202.119.36.131 A B A:send(B,M) 得到B,M 查B在本节点 将M交给B 2/4/2021 Institute of Computer Software, Nanjing University 20