S
S
Sanya Hihi Haha2020-05-27 19:36:48
Python
Sanya Hihi Haha, 2020-05-27 19:36:48

Is it possible to organize this?

Ku everyone.

There is some code

import requests
from bs4 import BeautifulSoup
import re

main_page = requests.get('https://habr.com/ru/post/207988/')


He apparently makes a simple request for the url.

Actually the essence of the question, can I organize such a system?
1) the user in VK sends the link to the bot
2) the bot receives the link
3) passes it to the function that starts executing requests on the site (there in the function it parses the necessary links, navigates through them, etc.)

As I myself think this can be organized, but the question is in another, how many such links from users can vds handle (suppose the server has such a configuration
2 GB RAM
2 core
40 GB NVMe
32 TB Traffic * )

Will process the mobile version of the site, which loads quickly even on 3G
Will I be able to parallelize 100-120 such requests? or just run a separate script for each request

To explain why and what for:
There is a paid bot for a mobile wap-game
It is written in python-requests, which means it only works on PC, and maybe the target audience is still mobile phones - I would like to to do it through the VK bot, because it’s hell for me to implement a mobile application ...

What are the citizens’ thoughts?

Answer the question

In order to leave comments, you need to log in

2 answer(s)
D
Dr. Bacon, 2020-05-27
@ValarMayar

You can organize, but judging by your questions, it’s not a fact that you will master it.

how many such links from users can vds master
is determined by load testing, but the specified configuration will "parallelize 100-120 such requests" without problems, provided that the code is more or less direct and if the server does not stupidly ban you for such a number of requests.

N
Nikolay, 2020-05-27
@SODINNER

Everything is possible in programming.

Didn't find what you were looking for?

Ask your question

Ask a Question

731 491 924 answers to any question