Allows communication with Queblo through SMS messages, using twilio webhooks. When someone sends a SMS message to Queblo’s twilio number, then twilio makes a call to Queblo
- Body: content of the SMS message
- To: Number of the recepient
- From: Number of the sender
- NumMedia: If the message includes images, this will be an interger greater than 0 or 0 if there are no images
- MediaUrlN: It's the URL of the image included in the SMS message. Its an index that beggings in 0. Ej. MediaUrl0, MediaUrl1
More information in Twilio Docs
[incoming sms]->, [has media]->, [not found]->(unhandle), [found]->(set mediaN as potential)->, [error]->(response SMS), [ok]->(unhandle), [no media]->(store incoming sms), (store incoming sms)-><find worker(2)>, <find worker(2)>[not found]->(unhandle), <find worker(2)>[found]->, [not confirmed]->, [jobs|1|empleos]->(confirm worker)-><save worker(2)>, <save worker(2)>[ok]->(response SMS), <save worker(2)>[error]->(unhandle), [otherwise]->(send confirmation sms)->(end), [confirmed]-><check answer(2)>, <check answer(2)>[jobs|empleos]->(response SMS), <check answer(2)>[otherwise]->(find availability request), (find availability request)->, [lenght = 0]->(response SMS), [lenght > 0]-><check answer(3)>, <check answer(3)>[yes|no|si]->(response SMS), <check answer(3)>[otherwise]->(handle multiple response), [can't process]->(unhandle), (response SMS)->(end), (handle multiple response))
Before performing the test, we downloaded the information of the data base fromuat.queblo.com
Two groups of users were created:
-
A group that behaves like users of the web page: 50 concurrent users that make requests. The batch repeats 10 times.
- Each request retrieves the information of the workers.
-
A group that behaves as twilio: 10 concurrent users where the batch repeats 10 times. The following requests are made randomly:
- an sms with one of the following texts: jobs, 1, yes, all, ultima, si
- an sms with an attached image
There are 60 total concurrent users
After running the tests in the SMS Gateway page begins to have trouble loading
As a result of the above tests, it can be seen that as the SMS Gateway services are not functioning properly and have poor performance. also causing the malfunction of the website
- Ensure that messages are properly managed and that the SMS Gateway service works as expected, for example today when a message with the words: "jobs" or "empleos" sends a confirmation message
- Node.js is handling both services and the website, that causes a malfunction in services reflected in a malfunction of the web page, it is best to separate the website from the services, so one does not affect the other
- About 40% of the requests SMS Gateway service don't end in an appropriate manner making the system unstable