F
F
Fedor Ananin2015-09-30 00:03:03
PHP
Fedor Ananin, 2015-09-30 00:03:03

Should I migrate to MongoDB for blogging (PHP)?

Good day!
There is a task to write a platform for blogging. Ideally, you need such things: a queue of publications, different types of publications (announcement, article, news, interview, video from YouTube, insert a post from VK, insert a tweet), the ability for different authors to write one joint article, moderation before publication, the ability for an ordinary user to offer article, grabber of materials from social networks and other sites.
That is, a lot of heterogeneous content is planned.
For example, an interview must have an author and characters, there can be several authors...
I started designing... I realized that MySQL would have a lot of tables and a lot of difficulties in designing. Especially if a new post type is added in the future.
Once the Toaster community already advised me to use MongoDB, for other purposes, but still. At first glance, it will be easier for me to do all this in mongo.
For example, an array of authors:
authors{
"1" => "Vasya Pupkin",
"2" => "Peter Popkin"
}
This will simplify the task of finding materials for a specific author, it will be easier to organize the output of authors in a template. The advantages are obvious.
It will be easier to work with the output of materials in general. There are two problems:
1) great experience in PHP + MySQL coding, but I know MongoDB only from two articles from Habr;
2) I use Vesta Control Panel on the server... it does not support MongoDB...
What I want to know from the community:
1) is it worth learning MongoDB and coding a project for this type of database? Will the investment of time pay off?
2) the first time you need to keep several sites on one VPS, many use MySQL. Is there a free and convenient solution like Vesta Control Panel, but with MongoDB support, or is it possible to put Monga on top of Vesta and enjoy life?
Thank you.
UPD1. I forgot about the need to make comments with likes / dislikes and nesting.

Answer the question

In order to leave comments, you need to log in

3 answer(s)
S
Sergey, 2015-09-30
Protko @Fesor

monga is a document-oriented database. Think well. If you do not plan to enter links between records, then feel free to take monga. Otherwise it's not worth it.

A
Alexander Aksentiev, 2015-09-30
@Sanasol

To get started, read what a relational database and key value are. And why can't mongo be used like this

O
OnYourLips, 2015-09-30
@OnYourLips

You have a data structure with relationships between objects.
Relational DBMSs such as PostgreSQL are ideal for this structure.

Didn't find what you were looking for?

Ask your question

Ask a Question

731 491 924 answers to any question