Frequently Asked Questions - Message and File StorageEstimated reading time: 4 minutes
- Where is messages stored?
- Can I store all the messages on my own server?
- What is the retention period of messages stored in the database?
- Where does Mesibo stores all the files?
- Can I store my files on public cloud platforms like Amazon S3, Google etc?
- Which protocol should I use to upload files?
- Does Mesibo provide any APIs for uploading and downloading files?
Where is messages stored?
There are three types of storage mesibo uses to store your data:
Local Device Storage: The messages sent and received by a user can be stored in a local database at the user end for faster access. You can enable a local database to store all incoming & outgoing messages and other information by using setDatabse while initializing mesibo.
Server-Side Storage: When User A sends a message to User B and if User B is not online, mesibo stores messages on the server till User B comes online. Once the message is delivered to User B, it is deleted from the server unless the retention option is enabled. If you enable the retention option, all the communication between your users is stored on the server. If you are hosting mesibo on your servers using mesibo on-premise, all the messages will be saved on your own database.
File Storage: All the files you transfer using mesibo are stored in a file server. The mesibo does not mandate where you store your files. You can store your files on your private file server or AWS, Azure, or any such cloud hosts. You need to write a file handler so that mesibo can upload to or download files from your server.
Can I store all the messages on my own server?
Yes, you can, it is part of our in-premises offerings. Visit On-Premise Installation to learn more.
What is the retention period of messages stored in the database?
Mesibo offers an unlimited message retention period, only limited by the storage quota and usage. You can at any time, clear storage from the Mesibo console or using the backend API.
Where does Mesibo stores all the files?
Mesibo does not store any files on Mesibo servers. Instead, Mesibo lets you store all your files (images, videos, documents etc.) on your server(s). This allows you to control your files and protect your sensitive data.
You need to write a small upload and download handler which will be called whenever Mesibo needs to send or receive files. When mesibo needs to send a file, your upload handler will be called with the file path using which you can upload the file and let mesibo know about the location where the file was uploaded. On the remote side, the download handler will be called with that location so that the remote side can download the file. For more information, refer to the mesibo application source code on GitHub and also FileTransferHandler reference document.
Can I store my files on public cloud platforms like Amazon S3, Google etc?
Absolutely, there are two ways
- once you upload files on your server, you can then upload them to one of the cloud providers of your choice and send the link back to your upload handler.
- Sign the request from the server and then directly send it. Refer to the documentation of your cloud provider. If you are using Amazon S3, refer here
Which protocol should I use to upload files?
Mesibo does not mandate protocol or how and where you store your files. You can use HTTPS or any property protocol. As long as you provide upload and download hander, Mesibo will work with any kind of protocols.
Does Mesibo provide any APIs for uploading and downloading files?
Yes, Mesibo HTTP is a very fast cross-platform library allows you to upload and download files to or from your server. Refer to the mesibo application source code on GitHub and Mesibo HTTP reference document.
Android File Upload Example
Mesibo.Http http = new Mesibo.Http(); http.url = "https://example.com"; http.postBundle = b; http.uploadFile = filePath; http.execute();
iOS File Upload Example
MesiboHttp *http = [MesiboHttp new]; http.url = @"https://example.com"; http.uploadFile = filePath; http.postBundle = post; [http execute];