swoole笔记
https://www.cnblogs.com/zhangyouwu/p/12664022.html
建立连接时回调函数
请求对象数据
object(Swoole\Http\Request)#41 (9) {
["fd"] => int(1)
["header"] => array(12) {
["host"] => string(18) "39.108.92.104:9501"
["connection"] => string(7) "Upgrade"
["pragma"] => string(8) "no-cache"
["cache-control"] => string(8) "no-cache"
["user-agent"] => string(135) "Mozilla/5.0 (iPhone; CPU iPhone OS 11_0 like Mac OS X) AppleWebKit/604.1.38 (KHTML, like Gecko) Version/11.0 Mobile/15A372 Safari/604.1"
["upgrade"] => string(9) "websocket"
["origin"] => string(7) "file://"
["sec-websocket-version"] => string(2) "13"
["accept-encoding"] => string(13) "gzip, deflate"
["accept-language"] => string(14) "zh-CN,zh;q=0.9"
["sec-websocket-key"] => string(24) "YnuVHegZghQ1FxbRKX6pQg=="
["sec-websocket-extensions"] => string(42) "permessage-deflate; client_max_window_bits"
}
["server"] => array(11) {
["request_method"] => string(3) "GET"
["request_uri"] => string(1) "/"
["path_info"] => string(1) "/"
["request_time"] => int(1601390127)
["request_time_float"] => float(1601390127.1642)
["server_port"] => int(9501)
["remote_port"] => int(27583)
["remote_addr"] => string(12) "27.44.88.211"
["master_time"] => int(1601390127)
["server_protocol"] => string(8) "HTTP/1.1"
["server_software"] => string(18) "swoole-http-server"
}
["request"] => NULL
["cookie"] => array(27) {
["pro_end"] => string(2) "-1"
["ltd_end"] => string(2) "-1"
["serverType"] => string(5) "nginx"
["order"] => string(7) "id desc"
["memSize"] => string(4) "1838"
["sites_path"] => string(12) "/www/wwwroot"
["rank"] => string(1) "a"
["uploadSize"] => string(10) "1073741824"
["distribution"] => string(6) "ubuntu"
["force"] => string(1) "0"
["load_type"] => string(4) "null"
["xterm_config"] => string(39) "{"cols":113,"rows":36,"detectZoom":100}"
["SetName"] => string(0) ""
["ChangePath"] => string(1) "7"
["load_page"] => string(1) "2"
["load_search"] => string(9) "undefined"
["backup_path"] => string(11) "/www/backup"
["pnull"] => string(9) "2not_load"
["vcodesum"] => string(2) "18"
["cutFileName"] => string(4) "null"
["BatchPaste"] => string(1) "2"
["BatchSelected"] => string(4) "null"
["SESSIONID"] => string(64) "6ef04ae0-1729-437f-9dbf-815a18e4554d.sghfUIPSZq0eeGcKMxnBqTmNSMk"
["request_token"] => string(48) "Xg7rhWd3nQP2sVBcmgh3JZYjh89emBOhTCDxOld2r99mkK3k"
["copyFileName"] => string(4) "null"
["layers"] => string(1) "4"
["Path"] => string(28) "/www/wwwroot/chat.51zuso.com"
}
["get"] => NULL
["files"] => NULL
["post"] => NULL
["tmpfiles"] => NULL
}