English 中文(简体)
php 服务器服务器到服务器推进通讯
原标题:php server to server push communication

i 迄今已有两个服务器( A, B) B 正在拉动 A 信息 。 现在我正在寻找 possibilites 将信息从 A 推进到 B 。

推力可能超过“火,忘记” 因为B仍然会不时拉动。

我所能想到的最简单的解决办法是,除了HTTP从A到B发布信息之外,还会提供网络服务。 是否有任何其他有效的(php)解决办法?

How about a socket connection? is this a valid approach for php? Or switching from HTTP to UDP (less overhead?)

你知道什么基准吗?

您的时间和帮助的 Thx 时间和帮助

最佳回答

假设纯PHP:

HTTP PostSTing 是最简单的解决方案 在我脑海中。

与插座连接, 除非你有一个套接字在 B 上无限期监听( 我甚至不会考虑这一点), 您需要 A 到 POST B 来设置套接字 。

我认为插座连接可能有些好处 如果你再传输大量的数据, 但如果不是,我会坚持POST。

问题回答

暂无回答




相关问题
Brute-force/DoS prevention in PHP [closed]

I am trying to write a script to prevent brute-force login attempts in a website I m building. The logic goes something like this: User sends login information. Check if username and password is ...

please can anyone check this while loop and if condition

<?php $con=mysql_connect("localhost","mts","mts"); if(!con) { die( unable to connect . mysql_error()); } mysql_select_db("mts",$con); /* date_default_timezone_set ("Asia/Calcutta"); $date = ...

定值美元

如何确认来自正确来源的数字。

Generating a drop down list of timezones with PHP

Most sites need some way to show the dates on the site in the users preferred timezone. Below are two lists that I found and then one method using the built in PHP DateTime class in PHP 5. I need ...

Text as watermarking in PHP

I want to create text as a watermark for an image. the water mark should have the following properties front: Impact color: white opacity: 31% Font style: regular, bold Bevel and Emboss size: 30 ...

How does php cast boolean variables?

How does php cast boolean variables? I was trying to save a boolean value to an array: $result["Users"]["is_login"] = true; but when I use debug the is_login value is blank. and when I do ...

热门标签