Title Page
Contents
Acronyms 9
Abstract 12
Chapter One. Introduction 13
1.1. Background 14
1.1.1. Complex Systems 14
1.1.2. Agent Based Modeling 14
1.1.3. Microservice 16
1.2. Problem Description 17
1.3. Research Objective 19
1.4. Outline 19
Chapter Two. Related Work 20
2.1. Agent Based Modeling Frameworks 20
2.1.1. NetLogo 20
2.1.2. Mesa 21
2.1.3. Repast Simphony and HPC 22
2.1.4. MASON and D-MASON 24
2.1.5. Comparison of ABM toolkits 26
2.2. Existing Simulating Web services or Microservices 28
2.3. Limitation of existing works 29
Chapter Three. Proposed System 31
3.1. Overview 31
3.2. Requirement Analysis 32
3.2.1. ABM Simulator 32
3.2.2. Functional and Non-Functional Requirements 32
3.2.3. Requirement-Function-Implementation 33
3.3. User Activity Flow 34
3.3.1. Scenarios 34
3.3.2. Use case Diagram 37
3.3.3. Use Case Description 38
Chapter Four. System Design 44
4.1. System Design Goals and Life Cycle 44
4.2. Microservice System Architecture 45
4.2.1. Services 46
4.2.2. Middleware 47
4.3. Dynamic Models 48
4.3.1. Sequence Diagram 48
4.3.2. Activity Diagram 52
4.4. Hardware to Software Mapping 53
4.5. Database Design 57
4.6. Access Control 58
4.6.1. Administrator: has the following privileges 58
4.6.2. User: has the following privileges 59
Chapter Five. Implementation 60
5.1. Annotation Processing 60
5.1.1. Annotations 61
5.1.2. Output of Annotation Processing 66
5.2. Template Code Generation with Gradle 69
5.2.1. Structure 69
5.2.2. Dependency Configuration Details 70
5.2.3. Output 70
5.3. Kafka Topics for Communication 73
5.3.1. UI Service Consuming Kafka Updates 75
5.3.2. Database Service Consuming Kafka Updates 76
5.4. User Interface 76
5.5. Deployment 82
Chapter Six. Summary 83
References 86
Appendices 93
Appendix 1. Tools and Frameworks 93
Java 93
Spring Boot 94
Maven and Gradle 95
Vaadin 95
Kafka & Zookeeper 96
Project Reactor 97
Docker 97
Zipkin 98
Appendix 2. Selected Code 99
Simulation Visualization 99
Simulation Charting 100
File hosting in File System service 102
Model running Simulation Service 103
Storing simulation data into database using Database Service 105
요약 107
Table 1. Applications of ABM 16
Table 2. Comparison of ABM libraries 26
Table 3. Requirement, Function and Implementation Mapping Table 33
Table 4. System Deployment Use Case 38
Table 5. Template Code Generation Use Case Description 39
Table 6. Sample Model Download Use Case Description 40
Table 7. Modeling ABM Use Case Description 41
Table 8. Running Model Use Case Description 41
Table 9. Querying Simulation Data Use Case Description 42
Table 10. Tools, Libraries and Middleware 55
Table 11. Purpose of Database Tables 58
Table 12. User privileges table 59
Table 13. Annotations table 61
Table 14. Kafka Topics 73
Table 15. Comparison of Existing Works to Current Study 84
Figure 1. Simulating Economy Model with NetLogo 21
Figure 2. Simulating Schelling Segregation Model with Mesa 22
Figure 3. Simulating Zombie Model with Repast Simphony 23
Figure 4. Simulating Life Model with MASON 25
Figure 5. Use Case Diagram 38
Figure 6. Spiral SDLC Model 45
Figure 7. Proposed System Microservice Architecture 46
Figure 8. Template Code generation Sequence Diagram 49
Figure 9. Model Running Sequence Diagram 50
Figure 10. Query Simulation Data Activity Sequence Diagram 51
Figure 11. Running Model Activity Diagram 52
Figure 12. Querying Simulation Data Activity Diagram 53
Figure 13. Software to Hardware Mapping 54
Figure 14. Database Schema 57
Figure 15. ABM Gradle Project Structure 70
Figure 16. Building a Jar File in Gradle 71
Figure 17. Location of Generated Jar File 72
Figure 18. Kafka Topics and Microservices Bindings 74
Figure 19. UI Service Consuming Kafka Updates 75
Figure 20. Database Service Consuming Kafka Updates 76
Figure 21. Dashboard Page 77
Figure 22. Simulation Information form for ABM Gradle Project Generation 78
Figure 23. Sample Models Page 79
Figure 24. Simulation Run Page after Uploading and Running Model File 80
Figure 25. Simulation Run Page after Querying for Data 81