###### tags: `modern system` # Converto ## Change Log |ver.|Date|Description|Author| |----|----|----|----| |1.0.0| 2020-02-05| First release | Ruby | ## Category [TOC] <!-- - [Introduction](#Introduction) - [Main Functions](#Main%20Functions) - [Data Forwarding](#Data%20Forwarding) - [Raw Data Storage](#Raw%20Data%20Storage) --> --- ## Introduction ![](https://i.imgur.com/NNpOcIL.jpg) The responsbility of *Converto* includes the following items: (i) **Data forwarding.** *Converto* will subscribe all topics that send from OBDs. Then, it will parse and transfer the data, which is known as raw data, to many events. Finally, it will send these events through AWS SQS to the related microservices. (ii) **Raw data storage.** *Converto* will write the raw data in local file. Then, send these data to AWS S3 every hour. ## Related Services - VM-325 - [Tripo](/SJofhmFM8) - Sensol - Alerto - Vehicol - Drivo - Devicio ## Main Functions ### Data Forwarding ##### Step-by-step process 1. Receives L1, L2, L3 reports, simple event, and value added event sent by [VM-325](https://drive.google.com/open?id=1alH0HSkOWeqIYvH3yKBe8A-kbbKlt4YS). 2. Transfer the raw data into the [events](/b3XKz_hYQou7S3Depah19Q) while receiving the report 3. Send each event through AWS SQS after transfering the data to each service. The SQS url is named as *{AWS_URL}/{sender_service}_{receiver_service}.fifo*. ### Raw Data Storage ##### Step-by-step process 1. Write the raw data in `/app/logs/raw_data_{year}{month}{date}{hour}.txt` after receiving a report. For example, if a report is sent at 14:00 in 2020 July 5th, it should be written in file `/app/logs/raw_data_2020070514.txt`. 2. Upload the raw data to S3. The local file will be uploaded every hour. The file will be stored in the folder of the month. Following shows an example. ![](https://i.imgur.com/NKTpYO1.png) ![](https://i.imgur.com/ZJ5W5vT.png)