Symfony Exception

ConnectException

HTTP 500 Internal Server Error

cURL error 28: Connection timed out after 5001 milliseconds (see https://curl.haxx.se/libcurl/c/libcurl-errors.html) for http://jsntia.org.cn/index.php?a=index

Exception

GuzzleHttp\Exception\ ConnectException

  1.             $message .= \sprintf(' for %s'$uriString);
  2.         }
  3.         // Create a connection exception if it was a specific error code.
  4.         $error = isset($connectionErrors[$easy->errno])
  5.             ? new ConnectException($message$easy->requestnull$ctx)
  6.             : new RequestException($message$easy->request$easy->responsenull$ctx);
  7.         return P\Create::rejectionFor($error);
  8.     }
  1.         // Retry when nothing is present or when curl failed to rewind.
  2.         if (empty($easy->options['_err_message']) && (!$easy->errno || $easy->errno == 65)) {
  3.             return self::retryFailedRewind($handler$easy$ctx);
  4.         }
  5.         return self::createRejection($easy$ctx);
  6.     }
  7.     private static function createRejection(EasyHandle $easy, array $ctx): PromiseInterface
  8.     {
  9.         static $connectionErrors = [
  1.         if (isset($easy->options['on_stats'])) {
  2.             self::invokeStats($easy);
  3.         }
  4.         if (!$easy->response || $easy->errno) {
  5.             return self::finishError($handler$easy$factory);
  6.         }
  7.         // Return the response if it is present and there is no error.
  8.         $factory->release($easy);
  1.         $easy $this->factory->create($request$options);
  2.         \curl_exec($easy->handle);
  3.         $easy->errno = \curl_errno($easy->handle);
  4.         return CurlFactory::finish($this$easy$this->factory);
  5.     }
  6. }
  1.      * @return callable(\Psr\Http\Message\RequestInterface, array): \GuzzleHttp\Promise\PromiseInterface Returns the composed handler.
  2.      */
  3.     public static function wrapSync(callable $default, callable $sync): callable
  4.     {
  5.         return static function (RequestInterface $request, array $options) use ($default$sync): PromiseInterface {
  6.             return empty($options[RequestOptions::SYNCHRONOUS]) ? $default($request$options) : $sync($request$options);
  7.         };
  8.     }
  9.     /**
  10.      * Sends streaming requests to a streaming compatible handler while sending
in /www/wwwroot/tdk/vendor/guzzlehttp/guzzle/src/Handler/Proxy.php :: GuzzleHttp\Handler\{closure} (line 48)
  1.      * @return callable(\Psr\Http\Message\RequestInterface, array): \GuzzleHttp\Promise\PromiseInterface Returns the composed handler.
  2.      */
  3.     public static function wrapStreaming(callable $default, callable $streaming): callable
  4.     {
  5.         return static function (RequestInterface $request, array $options) use ($default$streaming): PromiseInterface {
  6.             return empty($options['stream']) ? $default($request$options) : $streaming($request$options);
  7.         };
  8.     }
  9. }
  1.     {
  2.         $fn $this->nextHandler;
  3.         // Don't do anything if the request has no body.
  4.         if ($request->getBody()->getSize() === 0) {
  5.             return $fn($request$options);
  6.         }
  7.         $modify = [];
  8.         // Add a default content-type if possible.
  1.     public static function cookies(): callable
  2.     {
  3.         return static function (callable $handler): callable {
  4.             return static function ($request, array $options) use ($handler) {
  5.                 if (empty($options['cookies'])) {
  6.                     return $handler($request$options);
  7.                 } elseif (!($options['cookies'] instanceof CookieJarInterface)) {
  8.                     throw new \InvalidArgumentException('cookies must be an instance of GuzzleHttp\Cookie\CookieJarInterface');
  9.                 }
  10.                 $cookieJar $options['cookies'];
  11.                 $request $cookieJar->withCookieHeader($request);
  1.         if (empty($options['allow_redirects']['max'])) {
  2.             return $fn($request$options);
  3.         }
  4.         return $fn($request$options)
  5.             ->then(function (ResponseInterface $response) use ($request$options) {
  6.                 return $this->checkRedirect($request$options$response);
  7.             });
  8.     }
  1.         return static function (callable $handler) use ($bodySummarizer): callable {
  2.             return static function ($request, array $options) use ($handler$bodySummarizer) {
  3.                 if (empty($options['http_errors'])) {
  4.                     return $handler($request$options);
  5.                 }
  6.                 return $handler($request$options)->then(
  7.                     static function (ResponseInterface $response) use ($request$bodySummarizer) {
  8.                         $code $response->getStatusCode();
  9.                         if ($code 400) {
  10.                             return $response;
  11.                         }
  1.      */
  2.     public function __invoke(RequestInterface $request, array $options)
  3.     {
  4.         $handler $this->resolve();
  5.         return $handler($request$options);
  6.     }
  7.     /**
  8.      * Dumps a string representation of the stack.
  9.      *
  1.         $request $this->applyOptions($request$options);
  2.         /** @var HandlerStack $handler */
  3.         $handler $options['handler'];
  4.         try {
  5.             return P\Create::promiseFor($handler($request$options));
  6.         } catch (\Exception $e) {
  7.             return P\Create::rejectionFor($e);
  8.         }
  9.     }
  1.         }
  2.         $request = new Psr7\Request($method$uri$headers$body$version);
  3.         // Remove the option so that they are not doubly-applied.
  4.         unset($options['headers'], $options['body'], $options['version']);
  5.         return $this->transfer($request$options);
  6.     }
  7.     /**
  8.      * Create and send an HTTP request.
  9.      *
  1.      * @throws GuzzleException
  2.      */
  3.     public function request(string $method$uri '', array $options = []): ResponseInterface
  4.     {
  5.         $options[RequestOptions::SYNCHRONOUS] = true;
  6.         return $this->requestAsync($method$uri$options)->wait();
  7.     }
  8.     /**
  9.      * Get a client configuration option.
  10.      *
  1.         // 获取原站模板
  2.         try{
  3.         $client = new Client(['timeout' => 5.0]);
  4.         $res $client->request('GET'"http://".$proxy_domain, [
  5.             'headers' => [
  6.                 'User-Agent' => 'Mozilla/5.0 (Windows NT 10.0; Win64; x64) AppleWebKit/537.36 (KHTML, like Gecko) Chrome/98.0.4758.102 Safari/537.36',
  7.             ]
  8.         ]);
  9.         }catch (\GuzzleHttp\Exception\ClientException $e) {
  10.                 return "error";
PathShowController::calc_view_data() in /www/wwwroot/tdk/app/Http/Controllers/PathShowController.php (line 118)
  1.        // return response(var_dump($get_path_domain),200);
  2.         # 缓存系统
  3.         if($this->path_setting['cache'] == 1){
  4.             $cache_view Cache::get($request->fullUrl().check_spider(), function () use ($request$proxy_domain){
  5.  
  6.                 $calc_view_data self::calc_view_data($proxy_domain);
  7.                 if($calc_view_data!="error"){
  8.                     Cache::put($request->fullUrl().check_spider(), $calc_view_data);
  9.                     return $calc_view_data;
  10.                     
  11.                 }else{
in /www/wwwroot/tdk/vendor/illuminate/collections/helpers.php -> App\Http\Controllers\{closure} (line 184)
  1.      * @param  mixed  $value
  2.      * @return mixed
  3.      */
  4.     function value($value, ...$args)
  5.     {
  6.         return $value instanceof Closure $value(...$args) : $value;
  7.     }
  8. }
  1.         // the default value for this cache value. This default could be a callback
  2.         // so we will execute the value function which will resolve it if needed.
  3.         if (is_null($value)) {
  4.             $this->event(new CacheMissed($key));
  5.             $value value($default);
  6.         } else {
  7.             $this->event(new CacheHit($key$value));
  8.         }
  9.         return $value;
  1.      * @param  array  $parameters
  2.      * @return mixed
  3.      */
  4.     public function __call($method$parameters)
  5.     {
  6.         return $this->store()->$method(...$parameters);
  7.     }
  8. }
  1.         if (! $instance) {
  2.             throw new RuntimeException('A facade root has not been set.');
  3.         }
  4.         return $instance->$method(...$args);
  5.     }
  6. }
  1.                 }else{
  2.                     $page404 =  is_null($this->path_setting['page404'])?"nginx.blade.php":$this->path_setting['page404'];
  3.                     $file Str::of($page404)->rtrim('.blade.php');
  4.                     return view('path.error.'.$file);
  5.                 }
  6.             });
  7.         }else{
  8.             $cache_view self::calc_view_data($proxy_domain."/".$request->path());
  9.         }
  10.         return response($cache_view);
  1.         if (static::isCallableWithAtSign($callback) || $defaultMethod) {
  2.             return static::callClass($container$callback$parameters$defaultMethod);
  3.         }
  4.         return static::callBoundMethod($container$callback, function () use ($container$callback$parameters) {
  5.             return $callback(...array_values(static::getMethodDependencies($container$callback$parameters)));
  6.         });
  7.     }
  8.     /**
  9.      * Call a string reference to a class using Class@method syntax.
in /www/wwwroot/tdk/vendor/illuminate/container/Util.php :: Illuminate\Container\{closure} (line 40)
  1.      * @param  mixed  $value
  2.      * @return mixed
  3.      */
  4.     public static function unwrapIfClosure($value)
  5.     {
  6.         return $value instanceof Closure $value() : $value;
  7.     }
  8.     /**
  9.      * Get the class name of the given parameter's type, if possible.
  10.      *
  1.         if ($container->hasMethodBinding($method)) {
  2.             return $container->callMethodBinding($method$callback[0]);
  3.         }
  4.         return Util::unwrapIfClosure($default);
  5.     }
  6.     /**
  7.      * Normalize the given callback into a Class@method string.
  8.      *
  1.             return static::callClass($container$callback$parameters$defaultMethod);
  2.         }
  3.         return static::callBoundMethod($container$callback, function () use ($container$callback$parameters) {
  4.             return $callback(...array_values(static::getMethodDependencies($container$callback$parameters)));
  5.         });
  6.     }
  7.     /**
  8.      * Call a string reference to a class using Class@method syntax.
  9.      *
  1.      *
  2.      * @throws \InvalidArgumentException
  3.      */
  4.     public function call($callback, array $parameters = [], $defaultMethod null)
  5.     {
  6.         return BoundMethod::call($this$callback$parameters$defaultMethod);
  7.     }
  8.     /**
  9.      * Get a closure to resolve the given type from the container.
  10.      *
  1.      */
  2.     protected function callControllerCallable(callable $callable, array $parameters = [])
  3.     {
  4.         try {
  5.             return $this->prepareResponse(
  6.                 $this->call($callable$parameters)
  7.             );
  8.         } catch (HttpResponseException $e) {
  9.             return $e->getResponse();
  10.         }
  11.     }
  1.             return $this->callLumenControllerWithMiddleware(
  2.                 $instance$method$routeInfo$middleware
  3.             );
  4.         } else {
  5.             return $this->callControllerCallable(
  6.                 [$instance$method], $routeInfo[2]
  7.             );
  8.         }
  9.     }
  10.     /**
  1.         if (! method_exists($instance $this->make($controller), $method)) {
  2.             throw new NotFoundHttpException;
  3.         }
  4.         if ($instance instanceof LumenController) {
  5.             return $this->callLumenController($instance$method$routeInfo);
  6.         } else {
  7.             return $this->callControllerCallable(
  8.                 [$instance$method], $routeInfo[2]
  9.             );
  10.         }
  1.     protected function callActionOnArrayBasedRoute($routeInfo)
  2.     {
  3.         $action $routeInfo[1];
  4.         if (isset($action['uses'])) {
  5.             return $this->prepareResponse($this->callControllerAction($routeInfo));
  6.         }
  7.         foreach ($action as $value) {
  8.             if ($value instanceof Closure) {
  9.                 $callable $value->bindTo(new RoutingClosure);
  1.         // Pipe through route middleware...
  2.         if (isset($action['middleware'])) {
  3.             $middleware $this->gatherMiddlewareClassNames($action['middleware']);
  4.             return $this->prepareResponse($this->sendThroughPipeline($middleware, function () {
  5.                 return $this->callActionOnArrayBasedRoute($this['request']->route());
  6.             }));
  7.         }
  8.         return $this->prepareResponse(
  9.             $this->callActionOnArrayBasedRoute($routeInfo)
  1.      */
  2.     protected function prepareDestination(BaseClosure $destination)
  3.     {
  4.         return function ($passable) use ($destination) {
  5.             try {
  6.                 return $destination($passable);
  7.             } catch (Throwable $e) {
  8.                 return $this->handleException($passable$e);
  9.             }
  10.         };
  11.     }
Pipeline->Laravel\Lumen\Routing\{closure}() in /www/wwwroot/tdk/app/Http/Middleware/LoggingMiddleware.php (line 43)
  1.                 Log::info($request_ip."\t".$path_domains['proxy_domain'].$url."\t".$agent);
  2.             }
  3.         }
  4.         return $next($request);
  5.     }
  6. }
  1.                         // since the object we're given was already a fully instantiated object.
  2.                         $parameters = [$passable$stack];
  3.                     }
  4.                     $carry method_exists($pipe$this->method)
  5.                                     ? $pipe->{$this->method}(...$parameters)
  6.                                     : $pipe(...$parameters);
  7.                     return $this->handleCarry($carry);
  8.                 } catch (Throwable $e) {
  9.                     return $this->handleException($passable$e);
  1.         return function ($stack$pipe) {
  2.             return function ($passable) use ($stack$pipe) {
  3.                 try {
  4.                     $slice parent::carry();
  5.                     return ($slice($stack$pipe))($passable);
  6.                 } catch (Throwable $e) {
  7.                     return $this->handleException($passable$e);
  8.                 }
  9.             };
  10.         };
in /www/wwwroot/tdk/vendor/illuminate/pipeline/Pipeline.php -> Laravel\Lumen\Routing\{closure} (line 103)
  1.     {
  2.         $pipeline array_reduce(
  3.             array_reverse($this->pipes()), $this->carry(), $this->prepareDestination($destination)
  4.         );
  5.         return $pipeline($this->passable);
  6.     }
  7.     /**
  8.      * Run the pipeline and return the result.
  9.      *
  1.     {
  2.         if (count($middleware) > && ! $this->shouldSkipMiddleware()) {
  3.             return (new Pipeline($this))
  4.                 ->send($this->make('request'))
  5.                 ->through($middleware)
  6.                 ->then($then);
  7.         }
  8.         return $then($this->make('request'));
  9.     }
  1.         if (isset($action['middleware'])) {
  2.             $middleware $this->gatherMiddlewareClassNames($action['middleware']);
  3.             return $this->prepareResponse($this->sendThroughPipeline($middleware, function () {
  4.                 return $this->callActionOnArrayBasedRoute($this['request']->route());
  5.             }));
  6.         }
  7.         return $this->prepareResponse(
  8.             $this->callActionOnArrayBasedRoute($routeInfo)
  9.         );
  1.             case Dispatcher::NOT_FOUND:
  2.                 throw new NotFoundHttpException;
  3.             case Dispatcher::METHOD_NOT_ALLOWED:
  4.                 throw new MethodNotAllowedHttpException($routeInfo[1]);
  5.             case Dispatcher::FOUND:
  6.                 return $this->handleFoundRoute($routeInfo);
  7.         }
  8.     }
  9.     /**
  10.      * Handle a route found by the dispatcher.
  1.                 if (isset($this->router->getRoutes()[$method.$pathInfo])) {
  2.                     return $this->handleFoundRoute([true$this->router->getRoutes()[$method.$pathInfo]['action'], []]);
  3.                 }
  4.                 return $this->handleDispatcherResponse(
  5.                     $this->createDispatcher()->dispatch($method$pathInfo)
  6.                 );
  7.             });
  8.         } catch (Throwable $e) {
  9.             return $this->prepareResponse($this->sendExceptionToHandler($e));
  10.         }
  1.                 ->send($this->make('request'))
  2.                 ->through($middleware)
  3.                 ->then($then);
  4.         }
  5.         return $then($this->make('request'));
  6.     }
  7.     /**
  8.      * Prepare the response for sending.
  9.      *
  1.                 }
  2.                 return $this->handleDispatcherResponse(
  3.                     $this->createDispatcher()->dispatch($method$pathInfo)
  4.                 );
  5.             });
  6.         } catch (Throwable $e) {
  7.             return $this->prepareResponse($this->sendExceptionToHandler($e));
  8.         }
  9.     }
  1.      * @param  \Symfony\Component\HttpFoundation\Request|null  $request
  2.      * @return void
  3.      */
  4.     public function run($request null)
  5.     {
  6.         $response $this->dispatch($request);
  7.         if ($response instanceof SymfonyResponse) {
  8.             $response->send();
  9.         } else {
  10.             echo (string) $response;
Application->run() in /www/wwwroot/tdk/public/index.php (line 28)
  1. | the client's browser allowing them to enjoy the creative
  2. | and wonderful application we have prepared for them.
  3. |
  4. */
  5. $app->run();

Stack Trace

ConnectException
GuzzleHttp\Exception\ConnectException:
cURL error 28: Connection timed out after 5001 milliseconds (see https://curl.haxx.se/libcurl/c/libcurl-errors.html) for http://jsntia.org.cn/index.php?a=index

  at /www/wwwroot/tdk/vendor/guzzlehttp/guzzle/src/Handler/CurlFactory.php:210
  at GuzzleHttp\Handler\CurlFactory::createRejection()
     (/www/wwwroot/tdk/vendor/guzzlehttp/guzzle/src/Handler/CurlFactory.php:158)
  at GuzzleHttp\Handler\CurlFactory::finishError()
     (/www/wwwroot/tdk/vendor/guzzlehttp/guzzle/src/Handler/CurlFactory.php:110)
  at GuzzleHttp\Handler\CurlFactory::finish()
     (/www/wwwroot/tdk/vendor/guzzlehttp/guzzle/src/Handler/CurlHandler.php:47)
  at GuzzleHttp\Handler\CurlHandler->__invoke()
     (/www/wwwroot/tdk/vendor/guzzlehttp/guzzle/src/Handler/Proxy.php:28)
  at GuzzleHttp\Handler\Proxy::GuzzleHttp\Handler\{closure}()
     (/www/wwwroot/tdk/vendor/guzzlehttp/guzzle/src/Handler/Proxy.php:48)
  at GuzzleHttp\Handler\Proxy::GuzzleHttp\Handler\{closure}()
     (/www/wwwroot/tdk/vendor/guzzlehttp/guzzle/src/PrepareBodyMiddleware.php:35)
  at GuzzleHttp\PrepareBodyMiddleware->__invoke()
     (/www/wwwroot/tdk/vendor/guzzlehttp/guzzle/src/Middleware.php:31)
  at GuzzleHttp\Middleware::GuzzleHttp\{closure}()
     (/www/wwwroot/tdk/vendor/guzzlehttp/guzzle/src/RedirectMiddleware.php:71)
  at GuzzleHttp\RedirectMiddleware->__invoke()
     (/www/wwwroot/tdk/vendor/guzzlehttp/guzzle/src/Middleware.php:63)
  at GuzzleHttp\Middleware::GuzzleHttp\{closure}()
     (/www/wwwroot/tdk/vendor/guzzlehttp/guzzle/src/HandlerStack.php:75)
  at GuzzleHttp\HandlerStack->__invoke()
     (/www/wwwroot/tdk/vendor/guzzlehttp/guzzle/src/Client.php:331)
  at GuzzleHttp\Client->transfer()
     (/www/wwwroot/tdk/vendor/guzzlehttp/guzzle/src/Client.php:168)
  at GuzzleHttp\Client->requestAsync()
     (/www/wwwroot/tdk/vendor/guzzlehttp/guzzle/src/Client.php:187)
  at GuzzleHttp\Client->request()
     (/www/wwwroot/tdk/app/Http/Controllers/PathShowController.php:60)
  at App\Http\Controllers\PathShowController::calc_view_data()
     (/www/wwwroot/tdk/app/Http/Controllers/PathShowController.php:118)
  at App\Http\Controllers\PathShowController->App\Http\Controllers\{closure}()
     (/www/wwwroot/tdk/vendor/illuminate/collections/helpers.php:184)
  at value()
     (/www/wwwroot/tdk/vendor/illuminate/cache/Repository.php:105)
  at Illuminate\Cache\Repository->get()
     (/www/wwwroot/tdk/vendor/illuminate/cache/CacheManager.php:418)
  at Illuminate\Cache\CacheManager->__call()
     (/www/wwwroot/tdk/vendor/illuminate/support/Facades/Facade.php:261)
  at Illuminate\Support\Facades\Facade::__callStatic()
     (/www/wwwroot/tdk/app/Http/Controllers/PathShowController.php:128)
  at App\Http\Controllers\PathShowController->index()
     (/www/wwwroot/tdk/vendor/illuminate/container/BoundMethod.php:36)
  at Illuminate\Container\BoundMethod::Illuminate\Container\{closure}()
     (/www/wwwroot/tdk/vendor/illuminate/container/Util.php:40)
  at Illuminate\Container\Util::unwrapIfClosure()
     (/www/wwwroot/tdk/vendor/illuminate/container/BoundMethod.php:93)
  at Illuminate\Container\BoundMethod::callBoundMethod()
     (/www/wwwroot/tdk/vendor/illuminate/container/BoundMethod.php:37)
  at Illuminate\Container\BoundMethod::call()
     (/www/wwwroot/tdk/vendor/illuminate/container/Container.php:653)
  at Illuminate\Container\Container->call()
     (/www/wwwroot/tdk/vendor/laravel/lumen-framework/src/Concerns/RoutesRequests.php:389)
  at Laravel\Lumen\Application->callControllerCallable()
     (/www/wwwroot/tdk/vendor/laravel/lumen-framework/src/Concerns/RoutesRequests.php:355)
  at Laravel\Lumen\Application->callLumenController()
     (/www/wwwroot/tdk/vendor/laravel/lumen-framework/src/Concerns/RoutesRequests.php:329)
  at Laravel\Lumen\Application->callControllerAction()
     (/www/wwwroot/tdk/vendor/laravel/lumen-framework/src/Concerns/RoutesRequests.php:282)
  at Laravel\Lumen\Application->callActionOnArrayBasedRoute()
     (/www/wwwroot/tdk/vendor/laravel/lumen-framework/src/Concerns/RoutesRequests.php:262)
  at Laravel\Lumen\Application->Laravel\Lumen\Concerns\{closure}()
     (/www/wwwroot/tdk/vendor/laravel/lumen-framework/src/Routing/Pipeline.php:48)
  at Laravel\Lumen\Routing\Pipeline->Laravel\Lumen\Routing\{closure}()
     (/www/wwwroot/tdk/app/Http/Middleware/LoggingMiddleware.php:43)
  at App\Http\Middleware\LoggingMiddleware->handle()
     (/www/wwwroot/tdk/vendor/illuminate/pipeline/Pipeline.php:167)
  at Illuminate\Pipeline\Pipeline->Illuminate\Pipeline\{closure}()
     (/www/wwwroot/tdk/vendor/laravel/lumen-framework/src/Routing/Pipeline.php:30)
  at Laravel\Lumen\Routing\Pipeline->Laravel\Lumen\Routing\{closure}()
     (/www/wwwroot/tdk/vendor/illuminate/pipeline/Pipeline.php:103)
  at Illuminate\Pipeline\Pipeline->then()
     (/www/wwwroot/tdk/vendor/laravel/lumen-framework/src/Concerns/RoutesRequests.php:426)
  at Laravel\Lumen\Application->sendThroughPipeline()
     (/www/wwwroot/tdk/vendor/laravel/lumen-framework/src/Concerns/RoutesRequests.php:263)
  at Laravel\Lumen\Application->handleFoundRoute()
     (/www/wwwroot/tdk/vendor/laravel/lumen-framework/src/Concerns/RoutesRequests.php:237)
  at Laravel\Lumen\Application->handleDispatcherResponse()
     (/www/wwwroot/tdk/vendor/laravel/lumen-framework/src/Concerns/RoutesRequests.php:173)
  at Laravel\Lumen\Application->Laravel\Lumen\Concerns\{closure}()
     (/www/wwwroot/tdk/vendor/laravel/lumen-framework/src/Concerns/RoutesRequests.php:429)
  at Laravel\Lumen\Application->sendThroughPipeline()
     (/www/wwwroot/tdk/vendor/laravel/lumen-framework/src/Concerns/RoutesRequests.php:175)
  at Laravel\Lumen\Application->dispatch()
     (/www/wwwroot/tdk/vendor/laravel/lumen-framework/src/Concerns/RoutesRequests.php:112)
  at Laravel\Lumen\Application->run()
     (/www/wwwroot/tdk/public/index.php:28)