timeout file_get_contents

The default timeout is defined by default_socket_timeout ini-setting, which is 60 seconds. You can also change it on the fly:

ini_set('default_socket_timeout', 900); // 900 Seconds = 15 Minutes
Another way, to set a timeout, would be to use stream_context_create to set the timeout as HTTP context options of the HTTP stream wrapper in use:
 
$ctx = stream_context_create(array('http'=>
    array(
        'timeout' => 1200,  //1200 Seconds is 20 Minutes
    )
));
 
echo file_get_contents('http://example.com/', false, $ctx);

RabbitMQ answer by Consumer

$msg->delivery_info['channel']->basic_ack($msg->delivery_info['delivery_tag']);
$msg->delivery_info['channel']->basic_nack($msg->delivery_info['delivery_tag'], false, true);
$msg->delivery_info['channel']->basic_cancel($msg->delivery_info['consumer_tag']);

RabbitMQ

RabbitMQ

url:
localhost:55672

commands:

1. List
rabbitmqctl list_queues.

2. In order to debug this kind of mistake you can use rabbitmqctl to print the messages_unacknowledged field:
rabbitmqctl list_queues name messages_ready messages_unacknowledged

3. list of Exchanges
rabbitmqctl list_exchanges

4. List of Bindings

rabbitmqctl list_bindings.

Strony

Subskrybuj Notatnik RSS