{"id":103715,"date":"2022-04-05T15:36:50","date_gmt":"2022-04-05T13:36:50","guid":{"rendered":"https:\/\/prohoster.info\/blog\/novosti-interneta\/vypusk-ferretdb-0-1-realizaczii-mongodb-na-baze-subd-postgresql"},"modified":"2022-04-05T15:36:50","modified_gmt":"2022-04-05T13:36:50","slug":"vypusk-ferretdb-0-1-realizaczii-mongodb-na-baze-subd-postgresql","status":"publish","type":"post","link":"https:\/\/prohoster.info\/en\/blog\/news\/vypusk-ferretdb-0-1-realizaczii-mongodb-na-baze-subd-postgresql","title":{"rendered":"Release of FerretDB 0.1, a MongoDB implementation based on the PostgreSQL database.","gt_translate_keys":[{"key":"rendered","format":"text"}]},"content":{"rendered":"<p>The release of FerretDB 0.1 (formerly MangoDB) has been published, allowing the document-oriented database MongoDB to be replaced with PostgreSQL without changing application code. FerretDB is implemented as a proxy server that translates calls to MangoDB into SQL queries for PostgreSQL, enabling PostgreSQL to act as the actual storage. The code is written in Go and is distributed under the Apache 2.0 license.        <\/p>\n<p>The need for migration may arise due to MongoDB's transition to a non-open SSPL license, which is based on the AGPLv3 license but is not open because it contains a discriminatory requirement to supply not only the application code itself but also the source texts of all components involved in providing the cloud service under the SSPL license.     <\/p>\n<p>FerretDB targets users who do not utilize the advanced features of MongoDB in their applications but wish to use a fully open software stack. At this stage of development, FerretDB currently supports only a part of the capabilities of MongoDB that are most commonly used in standard applications. In the future, they plan to achieve full compatibility with MongoDB drivers and provide the ability to use FerretDB as a transparent replacement for MongoDB.      <\/p>\n<p>It should be noted that MongoDB occupies a niche between fast and scalable systems that operate on key\/value formatted data and relational databases, which are functional and convenient for query formation. MongoDB supports the storage of documents in a JSON-like format, has a sufficiently flexible query language, can create indexes for various stored attributes, efficiently manages large binary objects, supports journaling operations for modifying and adding data to the database, can operate according to the Map\/Reduce paradigm, and supports replication and the creation of fault-tolerant configurations.     <\/p>\n<p>In the release of FerretDB 0.1.0, the method for extracting data from PostgreSQL has been completely revamped. Previously, for each incoming MongoDB request, a single SQL query was generated for PostgreSQL, utilizing functions to handle JSON formats and performing result filtering on the PostgreSQL side. Due to differences in the semantics of PostgreSQL's json functions and MongoDB, there were discrepancies in behavior when comparing and sorting different types. To address this issue, an excessive data selection is now extracted from PostgreSQL, while result filtering is performed on the FerretDB side, allowing MongoDB behavior to be replicated in most situations.     <\/p>\n<p>The cost of increasing compatibility has resulted in a decrease in performance, which future releases plan to compensate for by selectively filtering queries on the FerretDB side only for those where behavioral discrepancies are observed. For example, the query \"db.collection.find({_id: 'some-id-value'})\" can be entirely processed in PostgreSQL. The primary goal of the project at this stage of development is achieving compatibility with MongoDB, while performance is currently taking a backseat. Functional changes in the new version include support for all bitwise operators, the comparison operator \"$eq\", as well as the operators \"$elemMatch\" and \"$bitsAllClear\".<br \/>\n<br \/>Source: <a content=\"nofollow\" rel=\"nofollow\" href=\"https:\/\/www.opennet.ru\/opennews\/art.shtml?num=56971\">opennet.ru<\/a> <\/p>","protected":false,"gt_translate_keys":[{"key":"rendered","format":"html"}]},"excerpt":{"rendered":"<p>\u041e\u043f\u0443\u0431\u043b\u0438\u043a\u043e\u0432\u0430\u043d \u0432\u044b\u043f\u0443\u0441\u043a \u043f\u0440\u043e\u0435\u043a\u0442\u0430 FerretDB 0.1 (\u0431\u044b\u0432\u0448\u0438\u0439 MangoDB), \u043f\u043e\u0437\u0432\u043e\u043b\u044f\u044e\u0449\u0435\u0433\u043e \u0437\u0430\u043c\u0435\u043d\u0438\u0442\u044c \u0434\u043e\u043a\u0443\u043c\u0435\u043d\u0442\u043e-\u043e\u0440\u0438\u0435\u043d\u0442\u0438\u0440\u043e\u0432\u0430\u043d\u043d\u0443\u044e \u0421\u0423\u0411\u0414 MongoDB \u043d\u0430 PostgreSQL \u0431\u0435\u0437 \u0432\u043d\u0435\u0441\u0435\u043d\u0438\u044f \u0438\u0437\u043c\u0435\u043d\u0435\u043d\u0438\u0439 \u0432 \u043a\u043e\u0434 \u043f\u0440\u0438\u043b\u043e\u0436\u0435\u043d\u0438\u0439. FerretDB \u0440\u0435\u0430\u043b\u0438\u0437\u043e\u0432\u0430\u043d \u043a\u0430\u043a \u043f\u0440\u043e\u043a\u0441\u0438-\u0441\u0435\u0440\u0432\u0435\u0440, \u0442\u0440\u0430\u043d\u0441\u043b\u0438\u0440\u0443\u044e\u0449\u0438\u0439 \u043e\u0431\u0440\u0430\u0449\u0435\u043d\u0438\u044f \u043a MangoDB \u0432 SQL-\u0437\u0430\u043f\u0440\u043e\u0441\u044b \u043a PostgreSQL, \u0447\u0442\u043e \u043f\u043e\u0437\u0432\u043e\u043b\u044f\u0435\u0442 \u0438\u0441\u043f\u043e\u043b\u044c\u0437\u043e\u0432\u0430\u0442\u044c PostgreSQL \u0432 \u043a\u0430\u0447\u0435\u0441\u0442\u0432\u0435 \u0444\u0430\u043a\u0442\u0438\u0447\u0435\u0441\u043a\u043e\u0433\u043e \u0445\u0440\u0430\u043d\u0438\u043b\u0438\u0449\u0430. \u041a\u043e\u0434 \u043d\u0430\u043f\u0438\u0441\u0430\u043d \u043d\u0430 \u044f\u0437\u044b\u043a\u0435 Go \u0438 \u0440\u0430\u0441\u043f\u0440\u043e\u0441\u0442\u0440\u0430\u043d\u044f\u0435\u0442\u0441\u044f \u043f\u043e\u0434 \u043b\u0438\u0446\u0435\u043d\u0437\u0438\u0435\u0439 Apache 2.0. \u041f\u043e\u0442\u0440\u0435\u0431\u043d\u043e\u0441\u0442\u044c \u043c\u0438\u0433\u0440\u0430\u0446\u0438\u0438 \u043c\u043e\u0436\u0435\u0442 \u0432\u043e\u0437\u043d\u0438\u043a\u043d\u0443\u0442\u044c [&hellip;]<\/p>\n","protected":false,"gt_translate_keys":[{"key":"rendered","format":"html"}]},"author":1,"featured_media":0,"comment_status":"open","ping_status":"open","sticky":false,"template":"","format":"standard","meta":{"footnotes":""},"categories":[702],"tags":[],"class_list":["post-103715","post","type-post","status-publish","format-standard","hentry","category-news"],"aioseo_notices":[],"aioseo_head":"\n\t\t<!-- All in One SEO 5.0.2 - aioseo.com -->\n\t<meta name=\"description\" content=\"\u041e\u043f\u0443\u0431\u043b\u0438\u043a\u043e\u0432\u0430\u043d \u0432\u044b\u043f\u0443\u0441\u043a \u043f\u0440\u043e\u0435\u043a\u0442\u0430 FerretDB 0.1 (\u0431\u044b\u0432\u0448\u0438\u0439 MangoDB), \u043f\u043e\u0437\u0432\u043e\u043b\u044f\u044e\u0449\u0435\u0433\u043e \u0437\u0430\u043c\u0435\u043d\u0438\u0442\u044c \u0434\u043e\u043a\u0443\u043c\u0435\u043d\u0442\u043e-\u043e\u0440\u0438\u0435\u043d\u0442\u0438\u0440\u043e\u0432\u0430\u043d\u043d\u0443\u044e \u0421\u0423\u0411\u0414 MongoDB \u043d\u0430 PostgreSQL \u0431\u0435\u0437 \u0432\u043d\u0435\u0441\u0435\u043d\u0438\u044f \u0438\u0437\u043c\u0435\u043d\u0435\u043d\u0438\u0439 \u0432 \u043a\u043e\u0434 \u043f\u0440\u0438\u043b\u043e\u0436\u0435\u043d\u0438\u0439.\" \/>\n\t<meta name=\"robots\" content=\"max-image-preview:large\" \/>\n\t<meta name=\"author\" content=\"Yuri Gagarin\"\/>\n\t<link rel=\"canonical\" href=\"https:\/\/prohoster.info\/en\/blog\/news\/vypusk-ferretdb-0-1-realizaczii-mongodb-na-baze-subd-postgresql\" \/>\n\t<meta name=\"generator\" content=\"All in One SEO (AIOSEO) 5.0.2\" \/>\n\t\t<meta property=\"og:locale\" content=\"en_US\" \/>\n\t\t<meta property=\"og:site_name\" content=\"ProHoster | \u041a\u0443\u043f\u0438\u0442\u044c \u043d\u0430\u0434\u0435\u0436\u043d\u044b\u0439 \u0445\u043e\u0441\u0442\u0438\u043d\u0433 \u0434\u043b\u044f \u0441\u0430\u0439\u0442\u043e\u0432 \u0441 \u0437\u0430\u0449\u0438\u0442\u043e\u0439 \u043e\u0442 DDoS, VPS VDS \u0441\u0435\u0440\u0432\u0435\u0440\u044b\" \/>\n\t\t<meta property=\"og:type\" content=\"article\" \/>\n\t\t<meta property=\"og:title\" content=\"\ud83e\udd47\u0412\u044b\u043f\u0443\u0441\u043a FerretDB 0.1, \u0440\u0435\u0430\u043b\u0438\u0437\u0430\u0446\u0438\u0438 MongoDB \u043d\u0430 \u0431\u0430\u0437\u0435 \u0421\u0423\u0411\u0414 PostgreSQL | ProHoster\" \/>\n\t\t<meta property=\"og:description\" content=\"\u041e\u043f\u0443\u0431\u043b\u0438\u043a\u043e\u0432\u0430\u043d \u0432\u044b\u043f\u0443\u0441\u043a \u043f\u0440\u043e\u0435\u043a\u0442\u0430 FerretDB 0.1 (\u0431\u044b\u0432\u0448\u0438\u0439 MangoDB), \u043f\u043e\u0437\u0432\u043e\u043b\u044f\u044e\u0449\u0435\u0433\u043e \u0437\u0430\u043c\u0435\u043d\u0438\u0442\u044c \u0434\u043e\u043a\u0443\u043c\u0435\u043d\u0442\u043e-\u043e\u0440\u0438\u0435\u043d\u0442\u0438\u0440\u043e\u0432\u0430\u043d\u043d\u0443\u044e \u0421\u0423\u0411\u0414 MongoDB \u043d\u0430 PostgreSQL \u0431\u0435\u0437 \u0432\u043d\u0435\u0441\u0435\u043d\u0438\u044f \u0438\u0437\u043c\u0435\u043d\u0435\u043d\u0438\u0439 \u0432 \u043a\u043e\u0434 \u043f\u0440\u0438\u043b\u043e\u0436\u0435\u043d\u0438\u0439.\" \/>\n\t\t<meta property=\"og:url\" content=\"https:\/\/prohoster.info\/en\/blog\/news\/vypusk-ferretdb-0-1-realizaczii-mongodb-na-baze-subd-postgresql\" \/>\n\t\t<meta property=\"og:image\" content=\"https:\/\/prohoster.info\/wp-content\/uploads\/2021\/11\/logo-350.jpg\" \/>\n\t\t<meta property=\"og:image:secure_url\" content=\"https:\/\/prohoster.info\/wp-content\/uploads\/2021\/11\/logo-350.jpg\" \/>\n\t\t<meta property=\"og:image:width\" content=\"350\" \/>\n\t\t<meta property=\"og:image:height\" content=\"350\" \/>\n\t\t<meta property=\"article:published_time\" content=\"2022-04-05T13:36:50+00:00\" \/>\n\t\t<meta property=\"article:modified_time\" content=\"2022-04-05T13:36:50+00:00\" \/>\n\t\t<meta property=\"article:publisher\" content=\"https:\/\/www.facebook.com\/prohoster\" \/>\n\t\t<meta property=\"article:author\" content=\"https:\/\/www.facebook.com\/prohoster\" \/>\n\t\t<!-- All in One SEO -->\n\n","aioseo_head_json":{"title":"\ud83e\udd47FerretDB 0.1 release, a MongoDB implementation based on PostgreSQL | ProHoster","description":"The release of FerretDB 0.1 (formerly MangoDB) has been published, allowing for the replacement of the document-oriented database MongoDB with PostgreSQL without making changes to application code.","canonical_url":"https:\/\/prohoster.info\/en\/blog\/news\/vypusk-ferretdb-0-1-realizaczii-mongodb-na-baze-subd-postgresql","robots":"max-image-preview:large","keywords":"","webmasterTools":{"miscellaneous":""},"schema":null,"og:locale":"en_US","og:site_name":"ProHoster | \u041a\u0443\u043f\u0438\u0442\u044c \u043d\u0430\u0434\u0435\u0436\u043d\u044b\u0439 \u0445\u043e\u0441\u0442\u0438\u043d\u0433 \u0434\u043b\u044f \u0441\u0430\u0439\u0442\u043e\u0432 \u0441 \u0437\u0430\u0449\u0438\u0442\u043e\u0439 \u043e\u0442 DDoS, VPS VDS \u0441\u0435\u0440\u0432\u0435\u0440\u044b","og:type":"article","og:title":"\ud83e\udd47\u0412\u044b\u043f\u0443\u0441\u043a FerretDB 0.1, \u0440\u0435\u0430\u043b\u0438\u0437\u0430\u0446\u0438\u0438 MongoDB \u043d\u0430 \u0431\u0430\u0437\u0435 \u0421\u0423\u0411\u0414 PostgreSQL | ProHoster","og:description":"\u041e\u043f\u0443\u0431\u043b\u0438\u043a\u043e\u0432\u0430\u043d \u0432\u044b\u043f\u0443\u0441\u043a \u043f\u0440\u043e\u0435\u043a\u0442\u0430 FerretDB 0.1 (\u0431\u044b\u0432\u0448\u0438\u0439 MangoDB), \u043f\u043e\u0437\u0432\u043e\u043b\u044f\u044e\u0449\u0435\u0433\u043e \u0437\u0430\u043c\u0435\u043d\u0438\u0442\u044c \u0434\u043e\u043a\u0443\u043c\u0435\u043d\u0442\u043e-\u043e\u0440\u0438\u0435\u043d\u0442\u0438\u0440\u043e\u0432\u0430\u043d\u043d\u0443\u044e \u0421\u0423\u0411\u0414 MongoDB \u043d\u0430 PostgreSQL \u0431\u0435\u0437 \u0432\u043d\u0435\u0441\u0435\u043d\u0438\u044f \u0438\u0437\u043c\u0435\u043d\u0435\u043d\u0438\u0439 \u0432 \u043a\u043e\u0434 \u043f\u0440\u0438\u043b\u043e\u0436\u0435\u043d\u0438\u0439.","og:url":"https:\/\/prohoster.info\/en\/blog\/news\/vypusk-ferretdb-0-1-realizaczii-mongodb-na-baze-subd-postgresql","og:image":"https:\/\/prohoster.info\/wp-content\/uploads\/2021\/11\/logo-350.jpg","og:image:secure_url":"https:\/\/prohoster.info\/wp-content\/uploads\/2021\/11\/logo-350.jpg","og:image:width":350,"og:image:height":350,"article:published_time":"2022-04-05T13:36:50+00:00","article:modified_time":"2022-04-05T13:36:50+00:00","article:publisher":"https:\/\/www.facebook.com\/prohoster","article:author":"https:\/\/www.facebook.com\/prohoster"},"aioseo_meta_data":{"post_id":"103715","title":null,"description":null,"keywords":null,"keyphrases":null,"primary_term":null,"canonical_url":null,"og_title":null,"og_description":null,"og_object_type":"default","og_image_type":"default","og_image_url":null,"og_image_width":null,"og_image_height":null,"og_image_custom_url":null,"og_image_custom_fields":null,"og_video":null,"og_custom_url":null,"og_article_section":null,"og_article_tags":null,"twitter_use_og":false,"twitter_card":"default","twitter_image_type":"default","twitter_image_url":null,"twitter_image_custom_url":null,"twitter_image_custom_fields":null,"twitter_title":null,"twitter_description":null,"schema":{"blockGraphs":[],"customGraphs":[],"default":{"data":{"Article":[],"Course":[],"Dataset":[],"FAQPage":[],"Movie":[],"Person":[],"Product":[],"ProductReview":[],"Car":[],"Recipe":[],"Service":[],"SoftwareApplication":[],"WebPage":[]},"graphName":"","isEnabled":true},"graphs":[]},"schema_type":"default","schema_type_options":null,"pillar_content":false,"robots_default":true,"robots_noindex":false,"robots_noarchive":false,"robots_nosnippet":false,"robots_nofollow":false,"robots_noimageindex":false,"robots_noodp":false,"robots_notranslate":false,"robots_max_snippet":null,"robots_max_videopreview":null,"robots_max_imagepreview":"large","priority":null,"frequency":null,"local_seo":null,"seo_analyzer_scan_date":null,"breadcrumb_settings":null,"limit_modified_date":false,"reviewed_by":null,"ai":null,"created":"2022-04-05 13:37:13","updated":"2022-10-02 21:35:28","focus_keyword":null,"additional_keywords":null,"truseo_locale":null},"gt_translate_keys":[{"key":"link","format":"url"}],"_links":{"self":[{"href":"https:\/\/prohoster.info\/en\/wp-json\/wp\/v2\/posts\/103715","targetHints":{"allow":["GET"]}}],"collection":[{"href":"https:\/\/prohoster.info\/en\/wp-json\/wp\/v2\/posts"}],"about":[{"href":"https:\/\/prohoster.info\/en\/wp-json\/wp\/v2\/types\/post"}],"author":[{"embeddable":true,"href":"https:\/\/prohoster.info\/en\/wp-json\/wp\/v2\/users\/1"}],"replies":[{"embeddable":true,"href":"https:\/\/prohoster.info\/en\/wp-json\/wp\/v2\/comments?post=103715"}],"version-history":[{"count":0,"href":"https:\/\/prohoster.info\/en\/wp-json\/wp\/v2\/posts\/103715\/revisions"}],"wp:attachment":[{"href":"https:\/\/prohoster.info\/en\/wp-json\/wp\/v2\/media?parent=103715"}],"wp:term":[{"taxonomy":"category","embeddable":true,"href":"https:\/\/prohoster.info\/en\/wp-json\/wp\/v2\/categories?post=103715"},{"taxonomy":"post_tag","embeddable":true,"href":"https:\/\/prohoster.info\/en\/wp-json\/wp\/v2\/tags?post=103715"}],"curies":[{"name":"wp","href":"https:\/\/api.w.org\/{rel}","templated":true}]}}