{"id":35844,"date":"2021-08-31T11:38:42","date_gmt":"2021-08-31T08:38:42","guid":{"rendered":"https:\/\/orbitsoft.com\/blog\/?p=35844"},"modified":"2023-06-09T02:49:08","modified_gmt":"2023-06-08T23:49:08","slug":"mysql-redis-vault-how-orbitsoft-saves-and-protects-data-in-the-posiflora-accounting-system","status":"publish","type":"post","link":"https:\/\/orbitsoft.com\/blog\/mysql-redis-vault-how-orbitsoft-saves-and-protects-data-in-the-posiflora-accounting-system\/","title":{"rendered":"MySQL, Redis, Vault: how OrbitSoft saves and protects data in the PosiFlora accounting system"},"content":{"rendered":"<div class=\"wp-block-lazyblock-case lazyblock-case-2dYb59\"><div class=\"styled-block\">\n  <div class=\"styled-block__main\">\n        <ul class=\"case__list\">\n            \n                    <li class=\"case__item\">\n              \n          <span class=\"case__order\">01<\/span>\n          <div class=\"case__body\">\n            <div class=\"case__title\">\n              <span>Kind of tool<\/span>\n            <\/div>\n            <p>Data base MySQL, Redis, Vault<\/p>          <\/div>\n        <\/li>\n            \n                    <li class=\"case__item\">\n              \n          <span class=\"case__order\">02<\/span>\n          <div class=\"case__body\">\n            <div class=\"case__title\">\n              <span>Where we use it<\/span>\n            <\/div>\n            <p>System of accounting and sales control in PosiFlora the flower business<\/p>          <\/div>\n        <\/li>\n            \n                    <li class=\"case__item\">\n              \n          <span class=\"case__order\">03<\/span>\n          <div class=\"case__body\">\n            <div class=\"case__title\">\n              <span>Tasks required<\/span>\n            <\/div>\n            <p>Keep different types of data separate from each other<\/p>\n<p>Protect confidential data from hacking<\/p>\n<p>Allow for the execution of complex analytical requests<\/p>\n<p>Reserve capacity for when case load increases<\/p>          <\/div>\n        <\/li>\n            \n                    <li class=\"case__item case__item_marked\">\n              \n          <span class=\"case__order\">04<\/span>\n          <div class=\"case__body\">\n            <div class=\"case__title\">\n              <span>Results<\/span>\n            <\/div>\n            <p>Data for over 8,500 users securely protected<\/p>\n<p>Processes up to 15 million API queries daily, and 10 times that on holidays<\/p>\n<p>Saves data even when it\u2019s entered offline<\/p>\n<p>Creates different kinds of reports to assist with business development<\/p>          <\/div>\n        <\/li>\n          <\/ul>\n  <\/div>\n  <\/div><\/div>\n\n<div class=\"wp-block-lazyblock-heading lazyblock-heading-Z15DFFa\"><h2 class=\"article__h\">Flower store income depends on data storage and analysis <\/h2><\/div>\n\n\n<p>PosiFlora is a system of accounting and sales control for the flower business. The majority of customers of PosiFlora are small flower shops.<\/p>\n\n\n\n<p>It\u2019s important for florists to save and properly analyze sales data: which flowers sell better, and which worse, what the average sale total comes to, statistics regarding the average customer, etc. If a mistake is made with the data, the business won&#8217;t be able to plan sales and purchases, and will lose money. We tell you how OrbitSoft organized the data storage system for PosiFlora, and how we help streamline and improve the flower business.<\/p>\n\n\n<div class=\"wp-block-lazyblock-figure lazyblock-figure-Z8brua\"><figure class=\"article__figure \">\n        <div class=\"article__figure-img\" >\n        <img decoding=\"async\" src=\"https:\/\/orbitsoft.com\/blog\/wp-content\/uploads\/a0cc41b7-3fbc-4188-8bc8-4f05ff5a99ad.jpg\" alt=\"\">\n    <\/div>\n        <\/figure><\/div>\n\n<div class=\"wp-block-lazyblock-heading lazyblock-heading-1gHILz\"><h2 class=\"article__h\">Separate data by type, and use different storage for each <\/h2><\/div>\n\n\n<p>There are two ways to store data: put it into one database, or separate it into different databases. Keeping all data in one database is convenient for developers: they need to spend less time updating and searching for the information they need. But this can be unsafe for clients: if you store data for different clients in one database, it\u2019ll be easier to steal; if the database crashes, the system will stop working for all users.<\/p>\n\n\n\n<p>At PosiFlora, the most important thing for us is the reliability of customer data. That&#8217;s why we separated data by type, and designed the architecture so that each type is stored separately:<\/p>\n\n\n\n<ul>\n<li>Client data is stored in a MySQL database<\/li>\n\n\n\n<li>Confidential\/sensitive data is stored in a special Vault database<\/li>\n\n\n\n<li>Operational data is stored in a Redis database<\/li>\n<\/ul>\n\n\n\n<p>Some more detail regarding each solution:<\/p>\n\n\n<div class=\"wp-block-lazyblock-heading lazyblock-heading-ZbXMq2\"><h2 class=\"article__h\">MySQL for storing customer data <\/h2><\/div>\n\n\n<p>The biggest group of data we store is data from PosiFlora clients regarding daily work tasks. The data is entered by florist employees, and they can perform different actions based on it.<\/p>\n\n\n<div class=\"wp-block-lazyblock-figure lazyblock-figure-1nTbOr\"><figure class=\"article__figure \">\n        <div class=\"article__figure-img\" >\n        <img decoding=\"async\" src=\"https:\/\/orbitsoft.com\/blog\/wp-content\/uploads\/ar2.jpeg\" alt=\"\">\n    <\/div>\n                <figcaption>How MySQL helps address client needs<\/figcaption>\n    <\/figure><\/div>\n\n\n<p>We chose MySQL for storing customer data for several reasons.  MySQL:<\/p>\n\n\n\n<ul>\n<li>Allows different types of client data to be kept separated, eliminating the possibility of getting it mixed up.<\/li>\n\n\n\n<li>Allows for the creation of complex analytical queries, so that clients can analyze data and plan their work.<\/li>\n\n\n\n<li>Is easier for analysts to use, as it understands SQL query language.<\/li>\n\n\n\n<li>Data storage slots are easy to expand as more clients are added.<\/li>\n\n\n\n<li>Database is free to use, so it economizes on storage resources.<\/li>\n<\/ul>\n\n\n\n<p>Today, we keep the data of over 8,500 customers safe, and process over 100,000 requests daily.<\/p>\n\n\n<div class=\"wp-block-lazyblock-heading lazyblock-heading-1U6QCx\"><h2 class=\"article__h\">Vault from HashiCorp for storing sensitive data <\/h2><\/div>\n\n\n<p>In addition to user data, we store sensitive data that needs a higher degree of protection against hacking. For greater security, we store such data in a special database called Vault.<\/p>\n\n\n<div class=\"wp-block-lazyblock-figure lazyblock-figure-Z1UBYd6\"><figure class=\"article__figure \">\n        <div class=\"article__figure-img\" >\n        <img decoding=\"async\" src=\"https:\/\/orbitsoft.com\/blog\/wp-content\/uploads\/ar1.jpeg\" alt=\"\">\n    <\/div>\n                <figcaption> How Vault saves sensitive data<\/figcaption>\n    <\/figure><\/div>\n\n\n<p>We chose Vault for increased security for the following reasons:<\/p>\n\n\n\n<ul>\n<li>Several levels of data protection.<\/li>\n\n\n\n<li>Even if the data is downloaded, it will be in a form such as &#8220;785kjjhgdwyegnsSJDC3523JLWK\u201d. An intruder cannot decrypt it without the key.<\/li>\n\n\n\n<li>The key consists of three parts, and is kept by three people.<\/li>\n<\/ul>\n\n\n\n<p>The database with sensitive data works separately from other systems, substantially increasing security. Even if something happens to the rest of the data, the sensitive data is protected.<\/p>\n\n\n<div class=\"wp-block-lazyblock-heading lazyblock-heading-1u7fbO\"><h2 class=\"article__h\">Redis for cached data storage <\/h2><\/div>\n\n\n<p>In addition to user data and sensitive data, we store cache data. We store cache data separate from other data, helping maintain higher system speeds.<\/p>\n\n\n<div class=\"wp-block-lazyblock-figure lazyblock-figure-ZNYHsy\"><figure class=\"article__figure \">\n        <div class=\"article__figure-img\" >\n        <img decoding=\"async\" src=\"https:\/\/orbitsoft.com\/blog\/wp-content\/uploads\/ar3.jpeg\" alt=\"\">\n    <\/div>\n                <figcaption>How Redis helps to speed up the system<\/figcaption>\n    <\/figure><\/div>\n\n\n<p>We chose Redis because it reacts faster to the opening of a page if the database is given the right address. For example, when a salesperson wants uses the stock tab to check if a desired item is in stock, it takes less than a second. If the operative data were stored in MySQL, output would take longe<\/p>\n\n\n<div class=\"wp-block-lazyblock-heading lazyblock-heading-2c35Gv\"><h2 class=\"article__h\">Advantages of a distributed storage system <\/h2><\/div>\n\n\n<ol>\n<li><strong>Security<\/strong>. Eliminates the possibility that data can overlap due to code errors. One client&#8217;s data will never be available to others. Increased security for sensitive data.<\/li>\n\n\n\n<li><strong>Scalability<\/strong>. Some of the data is stored on one server, some on another. This reduces development costs.<\/li>\n\n\n\n<li><strong>Data is easy to update.<\/strong> If we add new functions, e.g., if we limit access to data for employees, we can try this out on one client, and then later expand this to other clients. If something goes wrong, we\u2019ll notice the error immediately and fix it. This keeps everything running smoothly for the vast majority of clients.<\/li>\n\n\n\n<li><strong>High speed of the system.<\/strong> The accounting system doesn&#8217;t freeze while operating, even with an influx of holiday clients.<\/li>\n<\/ol>\n\n\n<div class=\"wp-block-lazyblock-important-block lazyblock-important-block-ZzpbKx\"><div class=\"important-box\">\n  <div class=\"important-box__main\">\n          <p class=\"important-box__h\">Technical Block<\/p>\n      \t<p>Frameworks:<\/p>\n<ul>\n<li>Back-end: Symfony<\/li>\n<li>Web front-end: Angular<\/li>\n<li>Mobile\/desktop app: Qt<\/li>\n<\/ul>\n<p>Programming languages:<\/p>\n<ul>\n<li>Back-end: PHP 7.3-7.4<\/li>\n<li>Web front-end: TypeScript<\/li>\n<li>Mobile\/desktop app: C++<\/li>\n<\/ul>\n<p>Libraries:<\/p>\n<ul>\n<li>Neomer\/JSON:API<\/li>\n<li>Doctrine ORM<\/li>\n<li>Enqueue<\/li>\n<li>League\/Flysystem<\/li>\n<li>Monolog<\/li>\n<li>SwiftMailer<\/li>\n<li>Twig<\/li>\n<\/ul>\n<p>Data Base:<\/p>\n<ul>\n<li>MySQL<\/li>\n<li>Redis<\/li>\n<li>Apache Kafka<\/li>\n<li>RabbitMQ<\/li>\n<li>Couchbase<\/li>\n<li>SQLite<\/li>\n<li>ElasticSearch<\/li>\n<\/ul>\n<p>Platforms and third-party software:<\/p>\n<ul>\n<li>Docker, Docker Compose, Docker Swarm<\/li>\n<li>Consul, from HashiCorp<\/li>\n<li>Vault, from HashiCorp<\/li>\n<li>Kafka Connect<\/li>\n<li>Graylog<\/li>\n<li>Grafana, Graphite, StatsD<\/li>\n<\/ul>  <\/div>\n  <\/div><\/div>\n\n<div class=\"wp-block-lazyblock-banner lazyblock-banner-2s9qvr\"><div \n  class=\"banner\n   \n  \" \n  >\n    <div class=\"banner__body\">\n        <h2 class=\"banner__h\"> We release projects for online and offline business<\/h2>\n        <div class=\"banner__content\">\n            <p><strong>We work with businesses of any scale.<\/strong> Our clients include international companies, large and medium-sized businesses, and startups.<\/p>\n<p><strong>Telecom<\/strong>: cellular operators, Internet service providers.<\/p>\n<p><strong>Finance<\/strong>: electronic payment systems, insurance companies and brokers.<\/p>\n<p><strong>Retail<\/strong>: stores, trade networks.<\/p>\n<p><strong>Internet advertising<\/strong>: advertising agencies, advertising networks.<\/p>\n<p><strong>Medicine<\/strong>: clinics, medical services.<\/p>        <\/div>\n                            <div \n              class=\"banner__button button js-form-modal\n               button_style_light-on-promo2\">\n              Discuss or order development                          <\/div>\n            <\/div>\n    <div class=\"banner__photo\">\n        <img decoding=\"async\" src=\"https:\/\/orbitsoft.com\/blog\/wp-content\/uploads\/friendship.png\" alt=\"\" class=\"banner__img\">\n    <\/div>\n<\/div><\/div>","protected":false},"excerpt":{"rendered":"<p>PosiFlora is a system of accounting and sales control for the flower business. The majority of customers of PosiFlora are small flower shops. It\u2019s important for florists to save and properly analyze sales data: which flowers sell better, and which worse, what the average sale total comes to, statistics regarding the average customer, etc. If [&hellip;]<\/p>\n","protected":false},"author":1,"featured_media":35856,"comment_status":"closed","ping_status":"open","sticky":false,"template":"","format":"standard","meta":[],"categories":[1],"tags":[196],"yoast_head":"<!-- This site is optimized with the Yoast SEO plugin v20.4 - https:\/\/yoast.com\/wordpress\/plugins\/seo\/ -->\n<title>MySQL, Redis, Vault: how OrbitSoft saves and protects data in the PosiFlora accounting system - OrbitSoft Blog<\/title>\n<meta name=\"description\" content=\"It\u2019s important for stores to save and properly analyze sales data. We tell you how OrbitSoft organized the data storage system for PosiFlora, and how we help streamline and improve the flower business.\" \/>\n<meta name=\"robots\" content=\"index, follow, max-snippet:-1, max-image-preview:large, max-video-preview:-1\" \/>\n<link rel=\"canonical\" href=\"https:\/\/orbitsoft.com\/blog\/mysql-redis-vault-how-orbitsoft-saves-and-protects-data-in-the-posiflora-accounting-system\/\" \/>\n<meta name=\"twitter:card\" content=\"summary_large_image\" \/>\n<meta name=\"twitter:title\" content=\"MySQL, Redis, Vault: how OrbitSoft saves and protects data in the PosiFlora accounting system - OrbitSoft Blog\" \/>\n<meta name=\"twitter:description\" content=\"It\u2019s important for stores to save and properly analyze sales data. We tell you how OrbitSoft organized the data storage system for PosiFlora, and how we help streamline and improve the flower business.\" \/>\n<meta name=\"twitter:image\" content=\"https:\/\/orbitsoft.com\/blog\/wp-content\/uploads\/articlesql.jpg\" \/>\n<meta name=\"twitter:creator\" content=\"@orbitsoft\" \/>\n<meta name=\"twitter:site\" content=\"@orbitsoft\" \/>\n<meta name=\"twitter:label1\" content=\"Written by\" \/>\n\t<meta name=\"twitter:data1\" content=\"admin\" \/>\n\t<meta name=\"twitter:label2\" content=\"Est. reading time\" \/>\n\t<meta name=\"twitter:data2\" content=\"3 minutes\" \/>\n<!-- \/ Yoast SEO plugin. -->","yoast_head_json":{"title":"MySQL, Redis, Vault: how OrbitSoft saves and protects data in the PosiFlora accounting system - OrbitSoft Blog","description":"It\u2019s important for stores to save and properly analyze sales data. We tell you how OrbitSoft organized the data storage system for PosiFlora, and how we help streamline and improve the flower business.","robots":{"index":"index","follow":"follow","max-snippet":"max-snippet:-1","max-image-preview":"max-image-preview:large","max-video-preview":"max-video-preview:-1"},"canonical":"https:\/\/orbitsoft.com\/blog\/mysql-redis-vault-how-orbitsoft-saves-and-protects-data-in-the-posiflora-accounting-system\/","twitter_card":"summary_large_image","twitter_title":"MySQL, Redis, Vault: how OrbitSoft saves and protects data in the PosiFlora accounting system - OrbitSoft Blog","twitter_description":"It\u2019s important for stores to save and properly analyze sales data. We tell you how OrbitSoft organized the data storage system for PosiFlora, and how we help streamline and improve the flower business.","twitter_image":"https:\/\/orbitsoft.com\/blog\/wp-content\/uploads\/articlesql.jpg","twitter_creator":"@orbitsoft","twitter_site":"@orbitsoft","twitter_misc":{"Written by":"admin","Est. reading time":"3 minutes"},"schema":{"@context":"https:\/\/schema.org","@graph":[{"@type":"WebPage","@id":"https:\/\/orbitsoft.com\/blog\/mysql-redis-vault-how-orbitsoft-saves-and-protects-data-in-the-posiflora-accounting-system\/","url":"https:\/\/orbitsoft.com\/blog\/mysql-redis-vault-how-orbitsoft-saves-and-protects-data-in-the-posiflora-accounting-system\/","name":"MySQL, Redis, Vault: how OrbitSoft saves and protects data in the PosiFlora accounting system - OrbitSoft Blog","isPartOf":{"@id":"https:\/\/orbitsoft.com\/blog\/#website"},"datePublished":"2021-08-31T08:38:42+00:00","dateModified":"2023-06-08T23:49:08+00:00","author":{"@id":"https:\/\/orbitsoft.com\/blog\/#\/schema\/person\/e515b3fa91e283750477594c4f028b7b"},"description":"It\u2019s important for stores to save and properly analyze sales data. We tell you how OrbitSoft organized the data storage system for PosiFlora, and how we help streamline and improve the flower business.","breadcrumb":{"@id":"https:\/\/orbitsoft.com\/blog\/mysql-redis-vault-how-orbitsoft-saves-and-protects-data-in-the-posiflora-accounting-system\/#breadcrumb"},"inLanguage":"en-US","potentialAction":[{"@type":"ReadAction","target":["https:\/\/orbitsoft.com\/blog\/mysql-redis-vault-how-orbitsoft-saves-and-protects-data-in-the-posiflora-accounting-system\/"]}]},{"@type":"BreadcrumbList","@id":"https:\/\/orbitsoft.com\/blog\/mysql-redis-vault-how-orbitsoft-saves-and-protects-data-in-the-posiflora-accounting-system\/#breadcrumb","itemListElement":[{"@type":"ListItem","position":1,"name":"Home","item":"https:\/\/orbitsoft.com\/blog\/"},{"@type":"ListItem","position":2,"name":"MySQL, Redis, Vault: how OrbitSoft saves and protects data in the PosiFlora accounting system"}]},{"@type":"WebSite","@id":"https:\/\/orbitsoft.com\/blog\/#website","url":"https:\/\/orbitsoft.com\/blog\/","name":"OrbitSoft Blog","description":"Discover the latest in news and resources for OrbitSoft","potentialAction":[{"@type":"SearchAction","target":{"@type":"EntryPoint","urlTemplate":"https:\/\/orbitsoft.com\/blog\/?s={search_term_string}"},"query-input":"required name=search_term_string"}],"inLanguage":"en-US"},{"@type":"Person","@id":"https:\/\/orbitsoft.com\/blog\/#\/schema\/person\/e515b3fa91e283750477594c4f028b7b","name":"admin","image":{"@type":"ImageObject","inLanguage":"en-US","@id":"https:\/\/orbitsoft.com\/blog\/#\/schema\/person\/image\/","url":"https:\/\/secure.gravatar.com\/avatar\/b1b269c579caf059f82b6d114c63fc49?s=96&d=mm&r=g","contentUrl":"https:\/\/secure.gravatar.com\/avatar\/b1b269c579caf059f82b6d114c63fc49?s=96&d=mm&r=g","caption":"admin"},"url":"https:\/\/orbitsoft.com\/blog\/author\/admin\/"}]}},"_links":{"self":[{"href":"https:\/\/orbitsoft.com\/blog\/wp-json\/wp\/v2\/posts\/35844"}],"collection":[{"href":"https:\/\/orbitsoft.com\/blog\/wp-json\/wp\/v2\/posts"}],"about":[{"href":"https:\/\/orbitsoft.com\/blog\/wp-json\/wp\/v2\/types\/post"}],"author":[{"embeddable":true,"href":"https:\/\/orbitsoft.com\/blog\/wp-json\/wp\/v2\/users\/1"}],"replies":[{"embeddable":true,"href":"https:\/\/orbitsoft.com\/blog\/wp-json\/wp\/v2\/comments?post=35844"}],"version-history":[{"count":7,"href":"https:\/\/orbitsoft.com\/blog\/wp-json\/wp\/v2\/posts\/35844\/revisions"}],"predecessor-version":[{"id":36541,"href":"https:\/\/orbitsoft.com\/blog\/wp-json\/wp\/v2\/posts\/35844\/revisions\/36541"}],"wp:featuredmedia":[{"embeddable":true,"href":"https:\/\/orbitsoft.com\/blog\/wp-json\/wp\/v2\/media\/35856"}],"wp:attachment":[{"href":"https:\/\/orbitsoft.com\/blog\/wp-json\/wp\/v2\/media?parent=35844"}],"wp:term":[{"taxonomy":"category","embeddable":true,"href":"https:\/\/orbitsoft.com\/blog\/wp-json\/wp\/v2\/categories?post=35844"},{"taxonomy":"post_tag","embeddable":true,"href":"https:\/\/orbitsoft.com\/blog\/wp-json\/wp\/v2\/tags?post=35844"}],"curies":[{"name":"wp","href":"https:\/\/api.w.org\/{rel}","templated":true}]}}