V
V
Vyacheslav Grachunov2017-03-05 21:28:11
VPN
Vyacheslav Grachunov, 2017-03-05 21:28:11

How to scatter requests over different network interfaces?

Actually, I thought about it, and decided what I needed. Described more accurately. But I still don't understand how to implement it.
Given:
1) Parsers parse sites
2) Some of them are on phantom.js , respectively, specify the interface to each request through which it is not possible to go
3) Accordingly, a proxy is needed to let such parsers through this proxy, and the proxy randomly scatters requests on different tun-interfaces
4) tun-interfaces are constant in quantity, but their ips change regularly (200+ ips in total, 15 work simultaneously)
5) How to implement and on what?

Answer the question

In order to leave comments, you need to log in

3 answer(s)
V
Vladimir Dubrovin, 2017-03-05
@Qwentor

In 3proxy
internal 127.0.0.1
auth iponly
allow *
parent 66 extip $/path/to-file/with/IP1 0
parent 66 extip $/path/to-file/with/IP2 0
parent 67 extip $/path/to-file /with/IP3 0
...
parent 67 extip $/path/to-file/with/IP15 0
proxy -i127.0.0.1 -p3128
uses the address from the corresponding file as the external IP address with a probability of 6.6 / 6.7%. (the sum of the weights must equal 1000).

E
eRKa, 2017-11-30
@kttotto

Do not fence the garden out of nothing or otherwise overhead. Everything is fine with you, only you need to take into account the possibility of an exception in a couple of places. This is when casting as can return null and when reading the key, it may not be.

var item = lstTasks.SelectedItem as DataRowView;
if(item == null)
    return throw new NullReferenceExeption(nameof(item));
var resultId = item.TryGetValue("id", out int id);
var resultName = item.TryGetValue("name", out string name);
if(resultId && resultName)
    DeleteTask(id.ToString(), name);

L
lam0x86, 2017-11-29
@lam0x86

Why not give the grid a collection of Tasks as an ItemsSource?

Didn't find what you were looking for?

Ask your question

Ask a Question

731 491 924 answers to any question