From 0c7ad688a048064d36f6d5b8779cef85865c16f3 Mon Sep 17 00:00:00 2001 From: ad3n Date: Tue, 25 May 2021 07:36:58 +0700 Subject: [PATCH] change from roudrunner to swoole --- .gitignore | 4 - .rr.dev.yaml | 31 - .rr.yaml | 22 - Dockerfile | 6 +- bin/.rr.yaml | 620 ------------- composer.json | 2 +- composer.lock | 864 +++++------------- config/bundles.php | 2 +- config/packages/baldinof_road_runner.yaml | 9 - config/packages/k911_swoole.yaml | 10 + docker-compose.yml | 2 +- docker/php/php.ini | 2 + docker/start.sh | 7 +- docker/supervisor/supervisor.prod.conf | 49 - .../{supervisor.dev.conf => supervisord.conf} | 4 +- symfony.lock | 40 +- 16 files changed, 256 insertions(+), 1418 deletions(-) delete mode 100755 .rr.dev.yaml delete mode 100755 .rr.yaml delete mode 100644 bin/.rr.yaml delete mode 100755 config/packages/baldinof_road_runner.yaml create mode 100755 config/packages/k911_swoole.yaml delete mode 100644 docker/supervisor/supervisor.prod.conf rename docker/supervisor/{supervisor.dev.conf => supervisord.conf} (92%) diff --git a/.gitignore b/.gitignore index b0bcf54c..90126179 100644 --- a/.gitignore +++ b/.gitignore @@ -23,7 +23,3 @@ Caddyfile /.php_cs /.php_cs.cache ###< friendsofphp/php-cs-fixer ### - -###> baldinof/roadrunner-bundle ### -/bin/rr -###< baldinof/roadrunner-bundle ### diff --git a/.rr.dev.yaml b/.rr.dev.yaml deleted file mode 100755 index 09f735fe..00000000 --- a/.rr.dev.yaml +++ /dev/null @@ -1,31 +0,0 @@ -server: - command: "php bin/console baldinof:roadrunner:worker" - -http: - address: 0.0.0.0:8080 - middleware: [ "static", "gzip" ] - uploads: - forbid: [ ".php", ".exe", ".bat" ] - static: - dir: "public" - forbid: [ ".php", ".htaccess" ] - -logs: - mode: development - channels: - http: - level: debug # Log all http requests, set to info to disable - server: - level: info # Everything written to worker stderr is logged - mode: raw - metrics: - level: debug - -reload: - enabled: true - interval: 1s - patterns: [".php", ".yaml"] - services: - http: - dirs: ["."] - recursive: true diff --git a/.rr.yaml b/.rr.yaml deleted file mode 100755 index 8772dd33..00000000 --- a/.rr.yaml +++ /dev/null @@ -1,22 +0,0 @@ -server: - command: "php bin/console baldinof:roadrunner:worker" - -http: - address: 0.0.0.0:8080 - middleware: [ "static", "gzip" ] - uploads: - forbid: [ ".php", ".exe", ".bat" ] - static: - dir: "public" - forbid: [ ".php", ".htaccess" ] - -logs: - mode: production - channels: - http: - level: debug # Log all http requests, set to info to disable - server: - level: info # Everything written to worker stderr is logged - mode: raw - metrics: - level: error diff --git a/Dockerfile b/Dockerfile index 64c27cff..d023ecbb 100644 --- a/Dockerfile +++ b/Dockerfile @@ -29,9 +29,9 @@ RUN apt autoremove -y && apt clean && apt autoclean RUN rm -rf /var/lib/apt/lists/* /tmp/* /var/tmp/* /usr/share/doc/* ~/.composer # Configuring +RUN echo "y\ny\ny\ny\ny\ny\n"| pecl install swoole ADD docker/php/php.ini /etc/php/8.0/cli/php.ini -ADD docker/supervisor/supervisor.dev.conf /etc/supervisord.dev.conf -ADD docker/supervisor/supervisor.prod.conf /etc/supervisord.prod.conf +ADD docker/supervisor/supervisord.conf /etc/supervisord.conf # Here we go ADD docker/start.sh /start.sh @@ -39,6 +39,6 @@ RUN chmod +x /start.sh WORKDIR /semart -EXPOSE 8080 +EXPOSE 9501 CMD ["/start.sh"] diff --git a/bin/.rr.yaml b/bin/.rr.yaml deleted file mode 100644 index a6eba226..00000000 --- a/bin/.rr.yaml +++ /dev/null @@ -1,620 +0,0 @@ -###################################################################################### -# THIS IS SAMPLE OF THE CONFIGURATION # -# IT'S NOT A DEFAULT CONFIGURATION, IT'S JUST A REFERENCE TO ALL OPTIONS AND PLUGINS # -# MORE DOCS CAN BE FOUND HERE: # -###################################################################################### - -# Production usage guide: https://roadrunner.dev/docs/beep-beep-production - -# Hint: RR will replace any config options using reference to environment variables, -# eg.: `option_key: ${ENVIRONMENT_VARIABLE_NAME}`. - -# Important: TCP port numbers for each plugin (rpc, http, etc) must be unique! - -# Remote Procedures Calling (docs: https://roadrunner.dev/docs/beep-beep-rpc) -# Is used for connecting to RoadRunner server from your PHP workers. -rpc: - # TCP address:port for listening. - # - # Default: "tcp://127.0.0.1:6001" - listen: tcp://127.0.0.1:6001 - -# Application server settings (docs: https://roadrunner.dev/docs/php-worker) -server: - # Worker starting command, with any required arguments. - # - # This option is required. - command: "php psr-worker.php" - - # User name (not UID) for the worker processes. An empty value means to use the RR process user. - # - # Default: "" - user: "" - - # Group name (not GID) for the worker processes. An empty value means to use the RR process user. - # - # Default: "" - group: "" - - # Environment variables for the worker processes. - # - # Default: - env: - - SOME_KEY: "SOME_VALUE" - - SOME_KEY2: "SOME_VALUE2" - - # Worker relay can be: "pipes", TCP (eg.: tcp://127.0.0.1:6001), or socket (eg.: unix:///var/run/rr.sock). - # - # Default: "pipes" - relay: pipes - - # Timeout for relay connection establishing (only for socket and TCP port relay). - # - # Default: 60s - relay_timeout: 60s - -# Logging settings (docs: https://roadrunner.dev/docs/beep-beep-logging) -logs: - # Logging mode can be "development", "production" or "raw". Do not forget to change this value for production environment. - # - # Development mode (which makes DPanicLevel logs panic), uses a console encoder, writes to standard error, and - # disables sampling. Stacktraces are automatically included on logs of WarnLevel and above. - # - # Default: "development" - mode: development - - # Logging level can be "panic", "error", "warn", "info", "debug". - # - # Default: "debug" - level: debug - - # Encoding format can be "console" or "json" (last is preferred for production usage). - # - # Default: "console" - encoding: console - - # Output can be file (eg.: "/var/log/rr_errors.log"), "stderr" or "stdout". - # - # Default: "stderr" - output: stderr - - # Errors only output can be file (eg.: "/var/log/rr_errors.log"), "stderr" or "stdout". - # - # Default: "stderr" - err_output: stderr - - # You can configure each plugin log messages individually (key is plugin name, and value is logging options in same - # format as above). - # - # Default: - channels: - http: - mode: development - level: panic - encoding: console - output: stdout - err_output: stderr - server: - mode: production - level: info - encoding: json - output: stdout - err_output: stdout - rpc: - mode: raw - level: debug - encoding: console - output: stderr - err_output: stdout - -# Workflow and activity mesh service. -# -# Drop this section for temporal feature disabling. -temporal: - # Address of temporal server. - # - # Default: "127.0.0.1:7233" - address: 127.0.0.1:7233 - - # Activities pool settings. - activities: - # How many worker processes will be started. Zero (or nothing) means the number of logical CPUs. - # - # Default: 0 - num_workers: 0 - - # Maximal count of worker executions. Zero (or nothing) means no limit. - # - # Default: 0 - max_jobs: 64 - - # Timeout for worker allocation. Zero means no limit. - # - # Default: 60s - allocate_timeout: 60s - - # Timeout for worker destroying before process killing. Zero means no limit. - # - # Default: 60s - destroy_timeout: 60s - - # Supervisor is used to control http workers (previous name was "limit", docs: - # https://roadrunner.dev/docs/php-limit). "Soft" limits will not interrupt current request processing. "Hard" - # limit on the contrary - interrupts the execution of the request. - supervisor: - # How often to check the state of the workers. - # - # Default: 1s - watch_tick: 1s - - # Maximum time worker is allowed to live (soft limit). Zero means no limit. - # - # Default: 0s - ttl: 0s - - # How long worker can spend in IDLE mode after first using (soft limit). Zero means no limit. - # - # Default: 0s - idle_ttl: 10s - - # Maximal worker memory usage in megabytes (soft limit). Zero means no limit. - # - # Default: 0 - max_worker_memory: 128 - - # Maximal job lifetime (hard limit). Zero means no limit. - # - # Default: 0s - exec_ttl: 60s - - # Internal temporal communication protocol, can be "proto" or "json". - # - # Default: "proto" - codec: proto - - # Debugging level (only for "json" codec). Set 0 for nothing, 1 for "normal", and 2 for colorized messages. - # - # Default: 1 - debug_level: 2 - -# KV plugin settings. Available drivers: boltdb, redis, memcached, memory. -# Any number of sections can be defined here. -kv: - # User defined name of the section - # - # Default: none - boltdb-south: - # Driver which should be used for the storage - # - # This option is required. - driver: boltdb - # Driver specific options. Dir - directory where to store db file. - # - # Default: "." - dir: "tests/rr-bolt" - # File name for the DB - # - # Default: "rr.db" - file: "rr.db" - # BoltDB bucket name - # - # Default: "rr" - bucket: "rr" - # Access permission for the DB file. - # - # Default: "0777" - permissions: 0666 - # TTL keys check interval in seconds. It's safe to use 1 second here, but can be a little costly to performance. - # - # Default: "60" seconds - interval: 40 - - # User defined name of the section - # - # Default: none - us-central-kv: - # Driver which should be used for the storage - # - # Default: none - driver: memcached - # Driver specific section. Address of the memcached node. - # - # Default: "localhost:11211" - addr: [ "localhost:11211" ] - - # User defined name of the section - # - # Default: none - fast-kv-fr: - # Driver which should be used for the storage. - # - # Default: none - driver: redis - # Redis specific section. If one address provided - single node client will be used. - # - # - # UniversalClient is an abstract client which - based on the provided options - - # can connect to either clusters, or sentinel-backed failover instances - # or simple single-instance servers. This can be useful for testing - # cluster-specific applications locally. - # if the number of addrs is 1 and master_name is empty, a single-node redis Client will be returned - # if the number of addrs is two or more, a ClusterClient will be returned - addrs: - - "localhost:6379" - # if a MasterName is passed a sentinel-backed FailoverClient will be returned - master_name: "" - username: "" - password: "" - db: 0 - sentinel_password: "" - route_by_latency: false - route_randomly: false - dial_timeout: 0 # accepted values [1s, 5m, 3h] - max_retries: 1 - min_retry_backoff: 0 # accepted values [1s, 5m, 3h] - max_retry_backoff: 0 # accepted values [1s, 5m, 3h] - pool_size: 0 - min_idle_conns: 0 - max_conn_age: 0 # accepted values [1s, 5m, 3h] - read_timeout: 0 # accepted values [1s, 5m, 3h] - write_timeout: 0 # accepted values [1s, 5m, 3h] - pool_timeout: 0 # accepted values [1s, 5m, 3h] - idle_timeout: 0 # accepted values [1s, 5m, 3h] - idle_check_freq: 0 # accepted values [1s, 5m, 3h] - read_only: false - - - # User defined name of the section - # - # Default: none - local-memory: - # In memory driver specific section - # - # Default: none - driver: memory - # TTL check interval in seconds - # - # Default: 60 seconds - interval: 1 - -# Service plugin settings -service: - # User defined service name - # - # Default: none, required - some_service_1: - # Command to execute. Can be any command here which can be executed. - # - # Default: none, required. - command: php tests/plugins/service/test_files/loop.php - # Number of copies (processes) to start per command. - # - # Default: 1 - process_num: 1 - # Allowed execute timeout. - # - # Default: 0 (infinity), can be 1s, 2m, 2h (seconds, minutes, hours) - exec_timeout: 0 - # Remain process after exit. In other words, restart process after exit with any exit code. - # - # Default: "false" - remain_after_exit: true - # Number of seconds to wait before process restart. - # - # Default: 30 - restart_sec: 1 - - # User defined service name - # - # Default: none, required - some_service_2: - # Command to execute. Can be any command here which can be executed. - # - # Default: none, required. - command: "binary" - # Number of copies (processes) to start per command. - # - # Default: 1 - process_num: 1 - # Allowed execute timeout. - # - # Default: 0 (infinity), can be 1s, 2m, 2h (seconds, minutes, hours) - exec_timeout: 0 - # Remain process after exit. In other words, restart process after exit with any exit code. - # - # Default: "false" - remain_after_exit: true - # Number of seconds to wait before process restart. - # - # Default: 30 - restart_sec: 1 - -# HTTP plugin settings. -http: - # Host and port to listen on (eg.: `127.0.0.1:8080`). - # - # This option is required. - address: 127.0.0.1:8080 - - # Maximal incoming request size in megabytes. Zero means no limit. - # - # Default: 0 - max_request_size: 256 - - # Middlewares for the http plugin, order is important. Allowed values is: "headers", "gzip". - # - # Default value: [] - middleware: [ "headers", "gzip" ] - - # Allow incoming requests only from the following subnets (https://en.wikipedia.org/wiki/Reserved_IP_addresses). - # - # Default: ["10.0.0.0/8", "127.0.0.0/8", "172.16.0.0/12", "192.168.0.0/16", "::1/128", "fc00::/7", "fe80::/10"] - trusted_subnets: [ - "10.0.0.0/8", - "127.0.0.0/8", - "172.16.0.0/12", - "192.168.0.0/16", - "::1/128", - "fc00::/7", - "fe80::/10", - ] - - # File uploading settings. - uploads: - # Directory for file uploads. Empty value means to use $TEMP based on your OS. - # - # Default: "" - dir: "/tmp" - - # Deny files with the following extensions to upload. - # - # Default: [".php", ".exe", ".bat"] - forbid: [ ".php", ".exe", ".bat", ".sh" ] - - # Settings for "headers" middleware (docs: https://roadrunner.dev/docs/http-headers). - headers: - # Allows to control CORS headers. Additional headers "Vary: Origin", "Vary: Access-Control-Request-Method", - # "Vary: Access-Control-Request-Headers" will be added to the server responses. Drop this section for this - # feature disabling. - cors: - # Controls "Access-Control-Allow-Origin" header value (docs: https://mzl.la/2OgD4Qf). - # - # Default: "" - allowed_origin: "*" - - # Controls "Access-Control-Allow-Headers" header value (docs: https://mzl.la/2OzDVvk). - # - # Default: "" - allowed_headers: "*" - - # Controls "Access-Control-Allow-Methods" header value (docs: https://mzl.la/3lbwyXf). - # - # Default: "" - allowed_methods: "GET,POST,PUT,DELETE" - - # Controls "Access-Control-Allow-Credentials" header value (docs: https://mzl.la/3ekJGaY). - # - # Default: false - allow_credentials: true - - # Controls "Access-Control-Expose-Headers" header value (docs: https://mzl.la/3qAqgkF). - # - # Default: "" - exposed_headers: "Cache-Control,Content-Language,Content-Type,Expires,Last-Modified,Pragma" - - # Controls "Access-Control-Max-Age" header value in seconds (docs: https://mzl.la/2PCSdvt). - # - # Default: 0 - max_age: 600 - - # Automatically add headers to every request passed to PHP. - # - # Default: - request: - input: "custom-header" - - # Automatically add headers to every response. - # - # Default: - response: - X-Powered-By: "RoadRunner" - - # Settings for "static" middleware (docs: https://roadrunner.dev/docs/http-static). - static: - dir: "." - forbid: [""] - allow: [".txt", ".php"] - request: - input: "custom-header" - response: - output: "output-header" - - # Workers pool settings. - pool: - # How many worker processes will be started. Zero (or nothing) means the number of logical CPUs. - # - # Default: 0 - num_workers: 0 - - # Maximal count of worker executions. Zero (or nothing) means no limit. - # - # Default: 0 - max_jobs: 64 - - # Timeout for worker allocation. Zero means no limit. - # - # Default: 60s - allocate_timeout: 60s - - # Timeout for worker destroying before process killing. Zero means no limit. - # - # Default: 60s - destroy_timeout: 60s - - # Supervisor is used to control http workers (previous name was "limit", docs: - # https://roadrunner.dev/docs/php-limit). "Soft" limits will not interrupt current request processing. "Hard" - # limit on the contrary - interrupts the execution of the request. - supervisor: - # How often to check the state of the workers. - # - # Default: 1s - watch_tick: 1s - - # Maximum time worker is allowed to live (soft limit). Zero means no limit. - # - # Default: 0s - ttl: 0s - - # How long worker can spend in IDLE mode after first using (soft limit). Zero means no limit. - # - # Default: 0s - idle_ttl: 10s - - # Maximal worker memory usage in megabytes (soft limit). Zero means no limit. - # - # Default: 0 - max_worker_memory: 128 - - # Maximal job lifetime (hard limit). Zero means no limit. - # - # Default: 0s - exec_ttl: 60s - - # SSL (Secure Sockets Layer) settings (docs: https://roadrunner.dev/docs/http-https). - ssl: - # Host and port to listen on (eg.: `127.0.0.1:443`). - # - # Default: ":443" - address: "127.0.0.1:443" - - # Automatic redirect from http:// to https:// schema. - # - # Default: false - redirect: true - - # Path to the cert file. This option is required for SSL working. - # - # This option is required. - cert: /ssl/server.crt - - # Path to the cert key file. - # - # This option is required. - key: /ssl/server.key - - # Path to the root certificate authority file. - # - # This option is optional. - root_ca: /ssl/root.crt - - # FastCGI frontend support. - fcgi: - # FastCGI connection DSN. Supported TCP and Unix sockets. An empty value disables this. - # - # Default: "" - address: tcp://0.0.0.0:7921 - - # HTTP/2 settings. - http2: - # HTTP/2 over non-encrypted TCP connection using H2C. - # - # Default: false - h2c: false - - # Maximal concurrent streams count. - # - # Default: 128 - max_concurrent_streams: 128 - -# Application metrics in Prometheus format (docs: https://roadrunner.dev/docs/beep-beep-metrics). Drop this section -# for this feature disabling. -metrics: - # Prometheus client address (path /metrics added automatically). - # - # Default: "127.0.0.1:2112" - address: "127.0.0.1:2112" - - # Application-specific metrics (published using an RPC connection to the server). - collect: - app_metric: - type: histogram - help: "Custom application metric" - labels: [ "type" ] - buckets: [ 0.1, 0.2, 0.3, 1.0 ] - # Objectives defines the quantile rank estimates with their respective absolute error (for summary only). - objectives: - - 1.4: 2.3 - - 2.0: 1.4 - -# Health check endpoint (docs: https://roadrunner.dev/docs/beep-beep-health). If response code is 200 - it means at -# least one worker ready to serve requests. 500 - there are no workers ready to service requests. -# Drop this section for this feature disabling. -status: - # Host and port to listen on (eg.: `127.0.0.1:2114`). Use the following URL: http://127.0.0.1:2114/health?plugin=http - # Multiple plugins must be separated using "&" - http://127.0.0.1:2114/health?plugin=http&plugin=rpc where "http" and - # "rpc" are active (connected) plugins. - # - # This option is required. - address: 127.0.0.1:2114 - - # Response status code if a requested plugin not ready to handle requests - # Valid for both /health and /ready endpoints - # - # Default: 503 - unavailable_status_code: 503 - -# Automatically detect PHP file changes and reload connected services (docs: -# https://roadrunner.dev/docs/beep-beep-reload). Drop this section for this feature disabling. -reload: - # Sync interval. - # - # Default: "1s" - interval: 1s - - # Global patterns to sync. - # - # Default: [".php"] - patterns: [ ".php" ] - - # List of included for sync services (this is a map, where key name is a plugin name). - # - # Default: - services: - http: - # Directories to sync. If recursive is set to true, recursive sync will be applied only to the directories in - # "dirs" section. Dot (.) means "current working directory". - # - # Default: [] - dirs: [ "." ] - - # Recursive search for file patterns to add. - # - # Default: false - recursive: true - - # Ignored folders. - # - # Default: [] - ignore: [ "vendor" ] - - # Service specific file pattens to sync. - # - # Default: [] - patterns: [ ".php", ".go", ".md" ] - -## RoadRunner internal container configuration (docs: https://github.com/spiral/endure). -endure: - # How long to wait for stopping. - # - # Default: 30s - grace_period: 30s - - # Print graph in the graphviz format to the stdout (paste here to visualize https://dreampuf.github.io) - # - # Default: false - print_graph: false - - # Logging level. Possible values: "debug", "info", "warn", "error", "panic", "fatal". - # - # Default: "error" - log_level: error diff --git a/composer.json b/composer.json index fbf4774f..0b158c33 100644 --- a/composer.json +++ b/composer.json @@ -11,13 +11,13 @@ "ext-pdo": "*", "ext-posix": "*", "ext-redis": "*", - "baldinof/roadrunner-bundle": "^2.0", "composer/composer": ">=2.0", "cron/cron": ">=1.4", "damienharper/auditor-bundle": ">=4.0", "doctrine/doctrine-bundle": "*", "doctrine/orm": "*", "friendsofsymfony/rest-bundle": ">=3.0", + "k911/swoole-bundle": "^0.10.0", "lexik/jwt-authentication-bundle": ">=2.11", "nelmio/api-doc-bundle": ">=4.0", "nelmio/cors-bundle": ">=2.0", diff --git a/composer.lock b/composer.lock index 62ecf32c..207cd835 100644 --- a/composer.lock +++ b/composer.lock @@ -4,94 +4,74 @@ "Read more about it at https://getcomposer.org/doc/01-basic-usage.md#installing-dependencies", "This file is @generated automatically" ], - "content-hash": "16985393ca9f2229253ff4c64249959d", + "content-hash": "473496c99cc424255bf44c38d78562f0", "packages": [ { - "name": "baldinof/roadrunner-bundle", - "version": "2.0.1", + "name": "beberlei/assert", + "version": "v3.3.1", "source": { "type": "git", - "url": "https://github.com/Baldinof/roadrunner-bundle.git", - "reference": "1f57a258e827ea9c1348fb0bbbcf9c17faf71f6f" + "url": "https://github.com/beberlei/assert.git", + "reference": "5e721d7e937ca3ba2cdec1e1adf195f9e5188372" }, "dist": { "type": "zip", - "url": "https://api.github.com/repos/Baldinof/roadrunner-bundle/zipball/1f57a258e827ea9c1348fb0bbbcf9c17faf71f6f", - "reference": "1f57a258e827ea9c1348fb0bbbcf9c17faf71f6f", + "url": "https://api.github.com/repos/beberlei/assert/zipball/5e721d7e937ca3ba2cdec1e1adf195f9e5188372", + "reference": "5e721d7e937ca3ba2cdec1e1adf195f9e5188372", "shasum": "" }, "require": { - "php": ">=7.4", - "psr/log": "^1.1", - "spiral/goridge": "^3.0", - "spiral/roadrunner": "^2.0.2", - "spiral/roadrunner-worker": ">=2.0.3", - "symfony/config": "^4.4 || ^5.0", - "symfony/dependency-injection": "^4.4 || ^5.0", - "symfony/http-kernel": "^4.4 || ^5.0", - "symfony/psr-http-message-bridge": "^1.1 || ^2.0", - "symfony/yaml": "^4.4 || ^5.0" - }, - "conflict": { - "doctrine/doctrine-bundle": "<2.1.1", - "sentry/sentry-symfony": "<4.0.0", - "spiral/roadrunner-metrics": "<2.0.1" + "ext-ctype": "*", + "ext-json": "*", + "ext-mbstring": "*", + "ext-simplexml": "*", + "php": "^7.0 || ^8.0" }, "require-dev": { - "blackfire/php-sdk": "^1.21", - "doctrine/doctrine-bundle": "^2.1.1", - "doctrine/mongodb-odm": "^2.2", - "doctrine/orm": "^2.7.3", - "friendsofphp/php-cs-fixer": "^2.16", - "mikey179/vfsstream": "^1.6.8", - "nyholm/psr7": "^1.2", - "pestphp/pest-plugin-expectations": "^1.0", - "phpspec/prophecy": "^1.11", - "phpspec/prophecy-phpunit": "^2.0", - "phpstan/phpstan": "0.12.80", - "phpunit/phpunit": "^9.1", - "sentry/sentry-symfony": "^4.0", - "spiral/roadrunner-metrics": "^2.0.1", - "symfony/framework-bundle": "^4.0||^5.0", - "symfony/proxy-manager-bridge": "^4.0 || ^5.0", - "symfony/var-dumper": "^4.0||^5.0" + "friendsofphp/php-cs-fixer": "*", + "phpstan/phpstan": "*", + "phpunit/phpunit": ">=6.0.0", + "yoast/phpunit-polyfills": "^0.1.0" }, "suggest": { - "nyholm/psr7": "For a super lightweight PSR-7/17 implementation", - "symfony/proxy-manager-bridge": "For doctrine re-connection implementation" + "ext-intl": "Needed to allow Assertion::count(), Assertion::isCountable(), Assertion::minCount(), and Assertion::maxCount() to operate on ResourceBundles" }, - "type": "symfony-bundle", + "type": "library", "autoload": { - "files": [ - "src/functions.php" - ], "psr-4": { - "Baldinof\\RoadRunnerBundle\\": "src", - "Tests\\Baldinof\\RoadRunnerBundle\\": "tests" - } + "Assert\\": "lib/Assert" + }, + "files": [ + "lib/Assert/functions.php" + ] }, "notification-url": "https://packagist.org/downloads/", "license": [ - "MIT" + "BSD-2-Clause" ], "authors": [ { - "name": "Florent Baldino", - "email": "baldinof@gmail.com" + "name": "Benjamin Eberlei", + "email": "kontakt@beberlei.de", + "role": "Lead Developer" + }, + { + "name": "Richard Quadling", + "email": "rquadling@gmail.com", + "role": "Collaborator" } ], - "description": "A RoadRunner worker as a Symfony Bundle", + "description": "Thin assertion library for input validation in business models.", + "keywords": [ + "assert", + "assertion", + "validation" + ], "support": { - "issues": "https://github.com/Baldinof/roadrunner-bundle/issues", - "source": "https://github.com/Baldinof/roadrunner-bundle/tree/2.0.1" + "issues": "https://github.com/beberlei/assert/issues", + "source": "https://github.com/beberlei/assert/tree/v3.3.1" }, - "funding": [ - { - "url": "https://github.com/Baldinof", - "type": "github" - } - ], - "time": "2021-04-16T21:00:04+00:00" + "time": "2021-04-18T20:11:03+00:00" }, { "name": "behat/transliterator", @@ -276,16 +256,16 @@ }, { "name": "composer/composer", - "version": "2.0.13", + "version": "2.0.14", "source": { "type": "git", "url": "https://github.com/composer/composer.git", - "reference": "986e8b86b7b570632ad0a905c3726c33dd4c0efb" + "reference": "92b2ccbef65292ba9f2004271ef47c7231e2eed5" }, "dist": { "type": "zip", - "url": "https://api.github.com/repos/composer/composer/zipball/986e8b86b7b570632ad0a905c3726c33dd4c0efb", - "reference": "986e8b86b7b570632ad0a905c3726c33dd4c0efb", + "url": "https://api.github.com/repos/composer/composer/zipball/92b2ccbef65292ba9f2004271ef47c7231e2eed5", + "reference": "92b2ccbef65292ba9f2004271ef47c7231e2eed5", "shasum": "" }, "require": { @@ -293,21 +273,21 @@ "composer/metadata-minifier": "^1.0", "composer/semver": "^3.0", "composer/spdx-licenses": "^1.2", - "composer/xdebug-handler": "^1.1", + "composer/xdebug-handler": "^2.0", "justinrainbow/json-schema": "^5.2.10", "php": "^5.3.2 || ^7.0 || ^8.0", "psr/log": "^1.0", "react/promise": "^1.2 || ^2.7", "seld/jsonlint": "^1.4", "seld/phar-utils": "^1.0", - "symfony/console": "^2.8.52 || ^3.4.35 || ^4.4 || ^5.0", - "symfony/filesystem": "^2.8.52 || ^3.4.35 || ^4.4 || ^5.0", - "symfony/finder": "^2.8.52 || ^3.4.35 || ^4.4 || ^5.0", - "symfony/process": "^2.8.52 || ^3.4.35 || ^4.4 || ^5.0" + "symfony/console": "^2.8.52 || ^3.4.35 || ^4.4 || ^5.0 || ^6.0", + "symfony/filesystem": "^2.8.52 || ^3.4.35 || ^4.4 || ^5.0 || ^6.0", + "symfony/finder": "^2.8.52 || ^3.4.35 || ^4.4 || ^5.0 || ^6.0", + "symfony/process": "^2.8.52 || ^3.4.35 || ^4.4 || ^5.0 || ^6.0" }, "require-dev": { "phpspec/prophecy": "^1.10", - "symfony/phpunit-bridge": "^4.2 || ^5.0" + "symfony/phpunit-bridge": "^4.2 || ^5.0 || ^6.0" }, "suggest": { "ext-openssl": "Enabling the openssl extension allows you to access https URLs for repositories and packages", @@ -354,7 +334,7 @@ "support": { "irc": "irc://irc.freenode.org/composer", "issues": "https://github.com/composer/composer/issues", - "source": "https://github.com/composer/composer/tree/2.0.13" + "source": "https://github.com/composer/composer/tree/2.0.14" }, "funding": [ { @@ -370,7 +350,7 @@ "type": "tidelift" } ], - "time": "2021-04-27T11:11:08+00:00" + "time": "2021-05-21T15:03:37+00:00" }, { "name": "composer/metadata-minifier", @@ -443,16 +423,16 @@ }, { "name": "composer/package-versions-deprecated", - "version": "1.11.99.1", + "version": "1.11.99.2", "source": { "type": "git", "url": "https://github.com/composer/package-versions-deprecated.git", - "reference": "7413f0b55a051e89485c5cb9f765fe24bb02a7b6" + "reference": "c6522afe5540d5fc46675043d3ed5a45a740b27c" }, "dist": { "type": "zip", - "url": "https://api.github.com/repos/composer/package-versions-deprecated/zipball/7413f0b55a051e89485c5cb9f765fe24bb02a7b6", - "reference": "7413f0b55a051e89485c5cb9f765fe24bb02a7b6", + "url": "https://api.github.com/repos/composer/package-versions-deprecated/zipball/c6522afe5540d5fc46675043d3ed5a45a740b27c", + "reference": "c6522afe5540d5fc46675043d3ed5a45a740b27c", "shasum": "" }, "require": { @@ -496,7 +476,7 @@ "description": "Composer plugin that provides efficient querying for installed package versions (no runtime IO)", "support": { "issues": "https://github.com/composer/package-versions-deprecated/issues", - "source": "https://github.com/composer/package-versions-deprecated/tree/1.11.99.1" + "source": "https://github.com/composer/package-versions-deprecated/tree/1.11.99.2" }, "funding": [ { @@ -512,20 +492,20 @@ "type": "tidelift" } ], - "time": "2020-11-11T10:22:58+00:00" + "time": "2021-05-24T07:46:03+00:00" }, { "name": "composer/semver", - "version": "3.2.4", + "version": "3.2.5", "source": { "type": "git", "url": "https://github.com/composer/semver.git", - "reference": "a02fdf930a3c1c3ed3a49b5f63859c0c20e10464" + "reference": "31f3ea725711245195f62e54ffa402d8ef2fdba9" }, "dist": { "type": "zip", - "url": "https://api.github.com/repos/composer/semver/zipball/a02fdf930a3c1c3ed3a49b5f63859c0c20e10464", - "reference": "a02fdf930a3c1c3ed3a49b5f63859c0c20e10464", + "url": "https://api.github.com/repos/composer/semver/zipball/31f3ea725711245195f62e54ffa402d8ef2fdba9", + "reference": "31f3ea725711245195f62e54ffa402d8ef2fdba9", "shasum": "" }, "require": { @@ -577,7 +557,7 @@ "support": { "irc": "irc://irc.freenode.org/composer", "issues": "https://github.com/composer/semver/issues", - "source": "https://github.com/composer/semver/tree/3.2.4" + "source": "https://github.com/composer/semver/tree/3.2.5" }, "funding": [ { @@ -593,7 +573,7 @@ "type": "tidelift" } ], - "time": "2020-11-13T08:59:24+00:00" + "time": "2021-05-24T12:41:47+00:00" }, { "name": "composer/spdx-licenses", @@ -676,16 +656,16 @@ }, { "name": "composer/xdebug-handler", - "version": "1.4.6", + "version": "2.0.1", "source": { "type": "git", "url": "https://github.com/composer/xdebug-handler.git", - "reference": "f27e06cd9675801df441b3656569b328e04aa37c" + "reference": "964adcdd3a28bf9ed5d9ac6450064e0d71ed7496" }, "dist": { "type": "zip", - "url": "https://api.github.com/repos/composer/xdebug-handler/zipball/f27e06cd9675801df441b3656569b328e04aa37c", - "reference": "f27e06cd9675801df441b3656569b328e04aa37c", + "url": "https://api.github.com/repos/composer/xdebug-handler/zipball/964adcdd3a28bf9ed5d9ac6450064e0d71ed7496", + "reference": "964adcdd3a28bf9ed5d9ac6450064e0d71ed7496", "shasum": "" }, "require": { @@ -720,7 +700,7 @@ "support": { "irc": "irc://irc.freenode.org/composer", "issues": "https://github.com/composer/xdebug-handler/issues", - "source": "https://github.com/composer/xdebug-handler/tree/1.4.6" + "source": "https://github.com/composer/xdebug-handler/tree/2.0.1" }, "funding": [ { @@ -736,7 +716,7 @@ "type": "tidelift" } ], - "time": "2021-03-25T17:01:18+00:00" + "time": "2021-05-05T19:37:51+00:00" }, { "name": "cron/cron", @@ -1873,43 +1853,47 @@ }, { "name": "doctrine/orm", - "version": "2.8.5", + "version": "2.9.1", "source": { "type": "git", "url": "https://github.com/doctrine/orm.git", - "reference": "a6577b89a2b028b79550ef58d9f272debdd75da4" + "reference": "f3e55fae9fdbdbc23897006bdbf016c20e11f6e9" }, "dist": { "type": "zip", - "url": "https://api.github.com/repos/doctrine/orm/zipball/a6577b89a2b028b79550ef58d9f272debdd75da4", - "reference": "a6577b89a2b028b79550ef58d9f272debdd75da4", + "url": "https://api.github.com/repos/doctrine/orm/zipball/f3e55fae9fdbdbc23897006bdbf016c20e11f6e9", + "reference": "f3e55fae9fdbdbc23897006bdbf016c20e11f6e9", "shasum": "" }, "require": { "composer/package-versions-deprecated": "^1.8", - "doctrine/annotations": "^1.11.1", - "doctrine/cache": "^1.9.1", + "doctrine/annotations": "^1.13", + "doctrine/cache": "^1.11|^2.0", "doctrine/collections": "^1.5", "doctrine/common": "^3.0.3", - "doctrine/dbal": "^2.10.0", + "doctrine/dbal": "^2.13.0", + "doctrine/deprecations": "^0.5.3", "doctrine/event-manager": "^1.1", "doctrine/inflector": "^1.4|^2.0", "doctrine/instantiator": "^1.3", "doctrine/lexer": "^1.0", "doctrine/persistence": "^2.2", "ext-pdo": "*", - "php": "^7.2|^8.0", + "php": "^7.1|^8.0", + "psr/cache": "^1 || ^2 || ^3", "symfony/console": "^3.0|^4.0|^5.0|^6.0" }, "require-dev": { "doctrine/coding-standard": "^9.0", "phpstan/phpstan": "^0.12.83", - "phpunit/phpunit": "^8.5|^9.4", + "phpunit/phpunit": "^7.5|^8.5|^9.4", "squizlabs/php_codesniffer": "3.6.0", + "symfony/cache": "^4.4|^5.2", "symfony/yaml": "^3.4|^4.0|^5.0|^6.0", "vimeo/psalm": "4.7.0" }, "suggest": { + "symfony/cache": "Provides cache support for Setup Tool with doctrine/cache 2.0", "symfony/yaml": "If you want to use YAML Metadata Mapping Driver" }, "bin": [ @@ -1955,9 +1939,9 @@ ], "support": { "issues": "https://github.com/doctrine/orm/issues", - "source": "https://github.com/doctrine/orm/tree/2.8.5" + "source": "https://github.com/doctrine/orm/tree/2.9.1" }, - "time": "2021-05-20T05:58:49+00:00" + "time": "2021-05-24T15:54:12+00:00" }, { "name": "doctrine/persistence", @@ -2440,6 +2424,114 @@ }, "time": "2020-05-27T16:41:55+00:00" }, + { + "name": "k911/swoole-bundle", + "version": "v0.10.0", + "source": { + "type": "git", + "url": "https://github.com/k911/swoole-bundle.git", + "reference": "cf99be907f8f759ef21efed265d34af73a3ed2ff" + }, + "dist": { + "type": "zip", + "url": "https://api.github.com/repos/k911/swoole-bundle/zipball/cf99be907f8f759ef21efed265d34af73a3ed2ff", + "reference": "cf99be907f8f759ef21efed265d34af73a3ed2ff", + "shasum": "" + }, + "require": { + "beberlei/assert": "^3.0", + "ext-json": "*", + "ext-swoole": "^4.5.10", + "php": "^7.4|^8.0", + "symfony/config": "^4.3.1|^5.0", + "symfony/console": "^4.3.1|^5.0", + "symfony/dependency-injection": "^4.3.1|^5.0", + "symfony/http-foundation": "^4.3.1|^5.0", + "symfony/http-kernel": "^4.3.1|^5.0", + "symfony/process": "^4.3.1|^5.0" + }, + "require-dev": { + "doctrine/annotations": "^1.6", + "doctrine/orm": "^2.6.3", + "friendsofphp/php-cs-fixer": "^2.19.0", + "jangregor/phpstan-prophecy": "^0.8.0", + "phpspec/prophecy-phpunit": "^2.0", + "phpstan/extension-installer": "^1.0.2", + "phpstan/phpstan": "^0.12.28", + "phpstan/phpstan-beberlei-assert": "^0.12.2", + "phpstan/phpstan-doctrine": "^0.12.9", + "phpstan/phpstan-phpunit": "^0.12.6", + "phpunit/php-code-coverage": "^9.1.0", + "phpunit/phpcov": "^8.1.0", + "phpunit/phpunit": "^9.1.3", + "swoole/ide-helper": "^4.5.10", + "symfony/debug-pack": "^1.0", + "symfony/error-handler": "^4.3.1|^5.0", + "symfony/framework-bundle": "^4.3.1|^5.0", + "symfony/messenger": "^4.3.1|^5.0", + "symfony/monolog-bridge": "^4.3.1|^5.0", + "symfony/monolog-bundle": "^3.3", + "symfony/profiler-pack": "^1.0", + "symfony/twig-bundle": "^4.3.1|^5.0", + "symfony/var-dumper": "^4.3.1|^5.0", + "symfony/yaml": "^4.3.1|^5.0", + "upscale/swoole-blackfire": "^3.0" + }, + "suggest": { + "doctrine/orm": "For using Entity Manager Handler", + "ext-inotify": "To enable HMR", + "pixelfederation/doctrine-resettable-em-bundle": "To be able to recover Doctrine Entity Managers from errors", + "symfony/error-handler": "To use Symfony Error Handler", + "symfony/messenger": "For using Symfony Messenger Swoole Task Transport.", + "upscale/swoole-blackfire": "To enable Blackfire profiling" + }, + "type": "library", + "extra": { + "branch-alias": { + "dev-develop": "v0.8.x-dev" + } + }, + "autoload": { + "files": [ + "src/functions_include.php" + ], + "psr-4": { + "K911\\Swoole\\": "src" + } + }, + "notification-url": "https://packagist.org/downloads/", + "license": [ + "MIT" + ], + "authors": [ + { + "name": "Konrad Obal", + "email": "konrad.obal@gmail.com", + "homepage": "https://github.com/k911" + } + ], + "description": "Swoole Symfony Bundle", + "homepage": "https://github.com/k911/swoole-bundle", + "keywords": [ + "async", + "bundle", + "http", + "php", + "server", + "swoole" + ], + "support": { + "issues": "https://github.com/k911/swoole-bundle/issues", + "source": "https://github.com/k911/swoole-bundle/tree/v0.10.0" + }, + "funding": [ + { + "url": "https://github.com/k911", + "type": "github" + } + ], + "time": "2021-05-05T11:48:12+00:00" + }, { "name": "lcobucci/clock", "version": "2.0.0", @@ -3309,114 +3401,6 @@ }, "time": "2019-01-08T18:20:26+00:00" }, - { - "name": "psr/http-factory", - "version": "1.0.1", - "source": { - "type": "git", - "url": "https://github.com/php-fig/http-factory.git", - "reference": "12ac7fcd07e5b077433f5f2bee95b3a771bf61be" - }, - "dist": { - "type": "zip", - "url": "https://api.github.com/repos/php-fig/http-factory/zipball/12ac7fcd07e5b077433f5f2bee95b3a771bf61be", - "reference": "12ac7fcd07e5b077433f5f2bee95b3a771bf61be", - "shasum": "" - }, - "require": { - "php": ">=7.0.0", - "psr/http-message": "^1.0" - }, - "type": "library", - "extra": { - "branch-alias": { - "dev-master": "1.0.x-dev" - } - }, - "autoload": { - "psr-4": { - "Psr\\Http\\Message\\": "src/" - } - }, - "notification-url": "https://packagist.org/downloads/", - "license": [ - "MIT" - ], - "authors": [ - { - "name": "PHP-FIG", - "homepage": "http://www.php-fig.org/" - } - ], - "description": "Common interfaces for PSR-7 HTTP message factories", - "keywords": [ - "factory", - "http", - "message", - "psr", - "psr-17", - "psr-7", - "request", - "response" - ], - "support": { - "source": "https://github.com/php-fig/http-factory/tree/master" - }, - "time": "2019-04-30T12:38:16+00:00" - }, - { - "name": "psr/http-message", - "version": "1.0.1", - "source": { - "type": "git", - "url": "https://github.com/php-fig/http-message.git", - "reference": "f6561bf28d520154e4b0ec72be95418abe6d9363" - }, - "dist": { - "type": "zip", - "url": "https://api.github.com/repos/php-fig/http-message/zipball/f6561bf28d520154e4b0ec72be95418abe6d9363", - "reference": "f6561bf28d520154e4b0ec72be95418abe6d9363", - "shasum": "" - }, - "require": { - "php": ">=5.3.0" - }, - "type": "library", - "extra": { - "branch-alias": { - "dev-master": "1.0.x-dev" - } - }, - "autoload": { - "psr-4": { - "Psr\\Http\\Message\\": "src/" - } - }, - "notification-url": "https://packagist.org/downloads/", - "license": [ - "MIT" - ], - "authors": [ - { - "name": "PHP-FIG", - "homepage": "http://www.php-fig.org/" - } - ], - "description": "Common interface for HTTP messages", - "homepage": "https://github.com/php-fig/http-message", - "keywords": [ - "http", - "http-message", - "psr", - "psr-7", - "request", - "response" - ], - "support": { - "source": "https://github.com/php-fig/http-message/tree/master" - }, - "time": "2016-08-06T14:39:51+00:00" - }, { "name": "psr/link", "version": "1.1.1", @@ -4063,284 +4047,6 @@ }, "time": "2021-01-12T19:20:24+00:00" }, - { - "name": "spiral/goridge", - "version": "v3.0.1", - "source": { - "type": "git", - "url": "https://github.com/spiral/goridge-php.git", - "reference": "3258892afd1d0a9cb889eb21ddd353dd06ba774d" - }, - "dist": { - "type": "zip", - "url": "https://api.github.com/repos/spiral/goridge-php/zipball/3258892afd1d0a9cb889eb21ddd353dd06ba774d", - "reference": "3258892afd1d0a9cb889eb21ddd353dd06ba774d", - "shasum": "" - }, - "require": { - "ext-json": "*", - "ext-sockets": "*", - "php": ">=7.4" - }, - "require-dev": { - "phpstan/phpstan": "~0.12.34", - "phpunit/phpunit": "~8.0", - "rybakit/msgpack": "^0.7.1", - "spiral/code-style": "^1.0" - }, - "type": "goridge", - "autoload": { - "psr-4": { - "Spiral\\Goridge\\": "src/" - } - }, - "notification-url": "https://packagist.org/downloads/", - "license": [ - "MIT" - ], - "authors": [ - { - "name": "Anton Titov / Wolfy-J", - "email": "wolfy.jd@gmail.com" - } - ], - "description": "High-performance PHP-to-Golang RPC bridge", - "support": { - "issues": "https://github.com/spiral/goridge-php/issues", - "source": "https://github.com/spiral/goridge-php/tree/v3.0.1" - }, - "time": "2021-03-11T14:28:29+00:00" - }, - { - "name": "spiral/roadrunner", - "version": "v2.2.1", - "source": { - "type": "git", - "url": "https://github.com/spiral/roadrunner.git", - "reference": "e1ff9daead5033b537296ffb071e551b95af91ab" - }, - "dist": { - "type": "zip", - "url": "https://api.github.com/repos/spiral/roadrunner/zipball/e1ff9daead5033b537296ffb071e551b95af91ab", - "reference": "e1ff9daead5033b537296ffb071e551b95af91ab", - "shasum": "" - }, - "require": { - "spiral/roadrunner-cli": "^2.0", - "spiral/roadrunner-http": "^2.0", - "spiral/roadrunner-worker": "^2.0" - }, - "type": "metapackage", - "notification-url": "https://packagist.org/downloads/", - "license": [ - "MIT" - ], - "authors": [ - { - "name": "Anton Titov / Wolfy-J", - "email": "wolfy.jd@gmail.com" - }, - { - "name": "RoadRunner Community", - "homepage": "https://github.com/spiral/roadrunner/graphs/contributors" - } - ], - "description": "RoadRunner: High-performance PHP application server, load-balancer and process manager written in Golang", - "support": { - "issues": "https://github.com/spiral/roadrunner/issues", - "source": "https://github.com/spiral/roadrunner/tree/v2.2.1" - }, - "time": "2021-05-13T17:15:00+00:00" - }, - { - "name": "spiral/roadrunner-cli", - "version": "v2.0.4", - "source": { - "type": "git", - "url": "https://github.com/spiral/roadrunner-cli.git", - "reference": "81dcec5c2d94481dedace488c27d433414726654" - }, - "dist": { - "type": "zip", - "url": "https://api.github.com/repos/spiral/roadrunner-cli/zipball/81dcec5c2d94481dedace488c27d433414726654", - "reference": "81dcec5c2d94481dedace488c27d433414726654", - "shasum": "" - }, - "require": { - "composer/semver": "^3.2", - "ext-json": "*", - "php": ">=7.4", - "spiral/roadrunner-worker": ">=2.0.2", - "symfony/console": "^4.4|^5.0", - "symfony/http-client": "^4.4|^5.0", - "symfony/polyfill-php80": "^1.22" - }, - "require-dev": { - "jetbrains/phpstorm-attributes": "^1.0", - "symfony/var-dumper": "^4.4|^5.0", - "vimeo/psalm": "^4.4" - }, - "bin": [ - "bin/rr" - ], - "type": "library", - "extra": { - "branch-alias": { - "dev-master": "2.1.x-dev" - } - }, - "autoload": { - "psr-4": { - "Spiral\\RoadRunner\\Console\\": "src" - } - }, - "notification-url": "https://packagist.org/downloads/", - "license": [ - "MIT" - ], - "authors": [ - { - "name": "Anton Titov (wolfy-j)", - "email": "wolfy-j@spiralscout.com" - }, - { - "name": "RoadRunner Community", - "homepage": "https://github.com/spiral/roadrunner/graphs/contributors" - } - ], - "description": "RoadRunner: Command Line Interface", - "support": { - "issues": "https://github.com/spiral/roadrunner-cli/issues", - "source": "https://github.com/spiral/roadrunner-cli/tree/v2.0.4" - }, - "time": "2021-05-12T15:49:01+00:00" - }, - { - "name": "spiral/roadrunner-http", - "version": "v2.0.0", - "source": { - "type": "git", - "url": "https://github.com/spiral/roadrunner-http.git", - "reference": "0eb0bc93f16ff8130fd0aaf31f6d87000bf2a605" - }, - "dist": { - "type": "zip", - "url": "https://api.github.com/repos/spiral/roadrunner-http/zipball/0eb0bc93f16ff8130fd0aaf31f6d87000bf2a605", - "reference": "0eb0bc93f16ff8130fd0aaf31f6d87000bf2a605", - "shasum": "" - }, - "require": { - "ext-json": "*", - "php": ">=7.4", - "psr/http-factory": "^1.0.1", - "psr/http-message": "^1.0.1", - "spiral/roadrunner-worker": "^2.0" - }, - "require-dev": { - "jetbrains/phpstorm-attributes": "^1.0", - "nyholm/psr7": "^1.3", - "phpstan/phpstan": "~0.12", - "phpunit/phpunit": "~8.0", - "symfony/var-dumper": "^5.1", - "vimeo/psalm": "^4.4" - }, - "suggest": { - "spiral/roadrunner-cli": "Provides RoadRunner installation and management CLI tools" - }, - "type": "library", - "extra": { - "branch-alias": { - "dev-master": "2.1.x-dev" - } - }, - "autoload": { - "psr-4": { - "Spiral\\RoadRunner\\Http\\": "src" - } - }, - "notification-url": "https://packagist.org/downloads/", - "license": [ - "MIT" - ], - "authors": [ - { - "name": "Anton Titov / Wolfy-J", - "email": "wolfy.jd@gmail.com" - }, - { - "name": "RoadRunner Community", - "homepage": "https://github.com/spiral/roadrunner/graphs/contributors" - } - ], - "description": "RoadRunner: HTTP and PSR-7 worker", - "support": { - "issues": "https://github.com/spiral/roadrunner-http/issues", - "source": "https://github.com/spiral/roadrunner-http/tree/v2.0.0" - }, - "time": "2021-02-18T11:09:37+00:00" - }, - { - "name": "spiral/roadrunner-worker", - "version": "v2.0.3", - "source": { - "type": "git", - "url": "https://github.com/spiral/roadrunner-worker.git", - "reference": "1a10a7641ff045fff2570b5ec1a265713e5a1bd5" - }, - "dist": { - "type": "zip", - "url": "https://api.github.com/repos/spiral/roadrunner-worker/zipball/1a10a7641ff045fff2570b5ec1a265713e5a1bd5", - "reference": "1a10a7641ff045fff2570b5ec1a265713e5a1bd5", - "shasum": "" - }, - "require": { - "composer-runtime-api": "^2.0", - "ext-json": "*", - "ext-sockets": "*", - "php": ">=7.4", - "psr/log": "^1.0", - "spiral/goridge": "^3.0" - }, - "require-dev": { - "jetbrains/phpstorm-attributes": "^1.0", - "symfony/var-dumper": "^5.1", - "vimeo/psalm": "^4.4" - }, - "suggest": { - "spiral/roadrunner-cli": "Provides RoadRunner installation and management CLI tools" - }, - "type": "library", - "extra": { - "branch-alias": { - "dev-master": "2.1.x-dev" - } - }, - "autoload": { - "psr-4": { - "Spiral\\RoadRunner\\": "src" - } - }, - "notification-url": "https://packagist.org/downloads/", - "license": [ - "MIT" - ], - "authors": [ - { - "name": "Anton Titov (wolfy-j)", - "email": "wolfy-j@spiralscout.com" - }, - { - "name": "RoadRunner Community", - "homepage": "https://github.com/spiral/roadrunner/graphs/contributors" - } - ], - "description": "RoadRunner: PHP worker", - "support": { - "issues": "https://github.com/spiral/roadrunner-worker/issues", - "source": "https://github.com/spiral/roadrunner-worker/tree/v2.0.3" - }, - "time": "2021-02-19T13:15:37+00:00" - }, { "name": "stof/doctrine-extensions-bundle", "version": "v1.6.0", @@ -7791,94 +7497,6 @@ ], "time": "2021-05-07T14:04:56+00:00" }, - { - "name": "symfony/psr-http-message-bridge", - "version": "v2.1.0", - "source": { - "type": "git", - "url": "https://github.com/symfony/psr-http-message-bridge.git", - "reference": "81db2d4ae86e9f0049828d9343a72b9523884e5d" - }, - "dist": { - "type": "zip", - "url": "https://api.github.com/repos/symfony/psr-http-message-bridge/zipball/81db2d4ae86e9f0049828d9343a72b9523884e5d", - "reference": "81db2d4ae86e9f0049828d9343a72b9523884e5d", - "shasum": "" - }, - "require": { - "php": ">=7.1", - "psr/http-message": "^1.0", - "symfony/http-foundation": "^4.4 || ^5.0" - }, - "require-dev": { - "nyholm/psr7": "^1.1", - "psr/log": "^1.1", - "symfony/browser-kit": "^4.4 || ^5.0", - "symfony/config": "^4.4 || ^5.0", - "symfony/event-dispatcher": "^4.4 || ^5.0", - "symfony/framework-bundle": "^4.4 || ^5.0", - "symfony/http-kernel": "^4.4 || ^5.0", - "symfony/phpunit-bridge": "^4.4.19 || ^5.2" - }, - "suggest": { - "nyholm/psr7": "For a super lightweight PSR-7/17 implementation" - }, - "type": "symfony-bridge", - "extra": { - "branch-alias": { - "dev-main": "2.1-dev" - } - }, - "autoload": { - "psr-4": { - "Symfony\\Bridge\\PsrHttpMessage\\": "" - }, - "exclude-from-classmap": [ - "/Tests/" - ] - }, - "notification-url": "https://packagist.org/downloads/", - "license": [ - "MIT" - ], - "authors": [ - { - "name": "Fabien Potencier", - "email": "fabien@symfony.com" - }, - { - "name": "Symfony Community", - "homepage": "http://symfony.com/contributors" - } - ], - "description": "PSR HTTP message bridge", - "homepage": "http://symfony.com", - "keywords": [ - "http", - "http-message", - "psr-17", - "psr-7" - ], - "support": { - "issues": "https://github.com/symfony/psr-http-message-bridge/issues", - "source": "https://github.com/symfony/psr-http-message-bridge/tree/v2.1.0" - }, - "funding": [ - { - "url": "https://symfony.com/sponsor", - "type": "custom" - }, - { - "url": "https://github.com/fabpot", - "type": "github" - }, - { - "url": "https://tidelift.com/funding/github/packagist/symfony/symfony", - "type": "tidelift" - } - ], - "time": "2021-02-17T10:35:25+00:00" - }, { "name": "symfony/redis-messenger", "version": "v5.2.7", @@ -10259,85 +9877,64 @@ }, { "name": "friendsofphp/php-cs-fixer", - "version": "v2.19.0", + "version": "v3.0.0", "source": { "type": "git", "url": "https://github.com/FriendsOfPHP/PHP-CS-Fixer.git", - "reference": "d5b8a9d852b292c2f8a035200fa6844b1f82300b" + "reference": "c15377bdfa8d1ecf186f1deadec39c89984e1167" }, "dist": { "type": "zip", - "url": "https://api.github.com/repos/FriendsOfPHP/PHP-CS-Fixer/zipball/d5b8a9d852b292c2f8a035200fa6844b1f82300b", - "reference": "d5b8a9d852b292c2f8a035200fa6844b1f82300b", + "url": "https://api.github.com/repos/FriendsOfPHP/PHP-CS-Fixer/zipball/c15377bdfa8d1ecf186f1deadec39c89984e1167", + "reference": "c15377bdfa8d1ecf186f1deadec39c89984e1167", "shasum": "" }, "require": { - "composer/semver": "^1.4 || ^2.0 || ^3.0", - "composer/xdebug-handler": "^1.2 || ^2.0", - "doctrine/annotations": "^1.2", + "composer/semver": "^3.2", + "composer/xdebug-handler": "^2.0", + "doctrine/annotations": "^1.12", "ext-json": "*", "ext-tokenizer": "*", - "php": "^5.6 || ^7.0 || ^8.0", - "php-cs-fixer/diff": "^1.3", - "symfony/console": "^3.4.43 || ^4.1.6 || ^5.0", - "symfony/event-dispatcher": "^3.0 || ^4.0 || ^5.0", - "symfony/filesystem": "^3.0 || ^4.0 || ^5.0", - "symfony/finder": "^3.0 || ^4.0 || ^5.0", - "symfony/options-resolver": "^3.0 || ^4.0 || ^5.0", - "symfony/polyfill-php70": "^1.0", - "symfony/polyfill-php72": "^1.4", - "symfony/process": "^3.0 || ^4.0 || ^5.0", - "symfony/stopwatch": "^3.0 || ^4.0 || ^5.0" + "php": "^7.1.3 || ^8.0", + "php-cs-fixer/diff": "^2.0", + "symfony/console": "^4.4.20 || ^5.1.3", + "symfony/event-dispatcher": "^4.4.20 || ^5.0", + "symfony/filesystem": "^4.4.20 || ^5.0", + "symfony/finder": "^4.4.20 || ^5.0", + "symfony/options-resolver": "^4.4.20 || ^5.0", + "symfony/polyfill-php72": "^1.22", + "symfony/process": "^4.4.20 || ^5.0", + "symfony/stopwatch": "^4.4.20 || ^5.0" }, "require-dev": { - "justinrainbow/json-schema": "^5.0", + "justinrainbow/json-schema": "^5.2", "keradus/cli-executor": "^1.4", - "mikey179/vfsstream": "^1.6", - "php-coveralls/php-coveralls": "^2.4.2", - "php-cs-fixer/accessible-object": "^1.0", + "mikey179/vfsstream": "^1.6.8", + "php-coveralls/php-coveralls": "^2.4.3", + "php-cs-fixer/accessible-object": "^1.1", "php-cs-fixer/phpunit-constraint-isidenticalstring": "^1.2", "php-cs-fixer/phpunit-constraint-xmlmatchesxsd": "^1.2.1", + "phpspec/prophecy": "^1.10.3", "phpspec/prophecy-phpunit": "^1.1 || ^2.0", - "phpunit/phpunit": "^5.7.27 || ^6.5.14 || ^7.5.20 || ^8.5.13 || ^9.5", + "phpunit/phpunit": "^7.5.20 || ^8.5.14 || ^9.5", "phpunitgoodpractices/polyfill": "^1.5", "phpunitgoodpractices/traits": "^1.9.1", - "sanmai/phpunit-legacy-adapter": "^6.4 || ^8.2.1", - "symfony/phpunit-bridge": "^5.2.1", - "symfony/yaml": "^3.0 || ^4.0 || ^5.0" + "symfony/phpunit-bridge": "^5.2.4", + "symfony/yaml": "^4.4.20 || ^5.0" }, "suggest": { "ext-dom": "For handling output formats in XML", "ext-mbstring": "For handling non-UTF8 characters.", - "php-cs-fixer/phpunit-constraint-isidenticalstring": "For IsIdenticalString constraint.", - "php-cs-fixer/phpunit-constraint-xmlmatchesxsd": "For XmlMatchesXsd constraint.", "symfony/polyfill-mbstring": "When enabling `ext-mbstring` is not possible." }, "bin": [ "php-cs-fixer" ], "type": "application", - "extra": { - "branch-alias": { - "dev-master": "2.19-dev" - } - }, "autoload": { "psr-4": { "PhpCsFixer\\": "src/" - }, - "classmap": [ - "tests/Test/AbstractFixerTestCase.php", - "tests/Test/AbstractIntegrationCaseFactory.php", - "tests/Test/AbstractIntegrationTestCase.php", - "tests/Test/Assert/AssertTokensTrait.php", - "tests/Test/IntegrationCase.php", - "tests/Test/IntegrationCaseFactory.php", - "tests/Test/IntegrationCaseFactoryInterface.php", - "tests/Test/InternalIntegrationCaseFactory.php", - "tests/Test/IsIdenticalConstraint.php", - "tests/Test/TokensWithObservedTransformers.php", - "tests/TestCase.php" - ] + } }, "notification-url": "https://packagist.org/downloads/", "license": [ @@ -10356,7 +9953,7 @@ "description": "A tool to automatically fix PHP code style", "support": { "issues": "https://github.com/FriendsOfPHP/PHP-CS-Fixer/issues", - "source": "https://github.com/FriendsOfPHP/PHP-CS-Fixer/tree/v2.19.0" + "source": "https://github.com/FriendsOfPHP/PHP-CS-Fixer/tree/v3.0.0" }, "funding": [ { @@ -10364,7 +9961,7 @@ "type": "github" } ], - "time": "2021-05-03T21:43:24+00:00" + "time": "2021-05-03T21:51:58+00:00" }, { "name": "nikic/php-parser", @@ -10424,16 +10021,16 @@ }, { "name": "php-cs-fixer/diff", - "version": "v1.3.1", + "version": "v2.0.2", "source": { "type": "git", "url": "https://github.com/PHP-CS-Fixer/diff.git", - "reference": "dbd31aeb251639ac0b9e7e29405c1441907f5759" + "reference": "29dc0d507e838c4580d018bd8b5cb412474f7ec3" }, "dist": { "type": "zip", - "url": "https://api.github.com/repos/PHP-CS-Fixer/diff/zipball/dbd31aeb251639ac0b9e7e29405c1441907f5759", - "reference": "dbd31aeb251639ac0b9e7e29405c1441907f5759", + "url": "https://api.github.com/repos/PHP-CS-Fixer/diff/zipball/29dc0d507e838c4580d018bd8b5cb412474f7ec3", + "reference": "29dc0d507e838c4580d018bd8b5cb412474f7ec3", "shasum": "" }, "require": { @@ -10461,21 +10058,18 @@ { "name": "Kore Nordmann", "email": "mail@kore-nordmann.de" - }, - { - "name": "SpacePossum" } ], - "description": "sebastian/diff v2 backport support for PHP5.6", + "description": "sebastian/diff v3 backport support for PHP 5.6+", "homepage": "https://github.com/PHP-CS-Fixer", "keywords": [ "diff" ], "support": { "issues": "https://github.com/PHP-CS-Fixer/diff/issues", - "source": "https://github.com/PHP-CS-Fixer/diff/tree/v1.3.1" + "source": "https://github.com/PHP-CS-Fixer/diff/tree/v2.0.2" }, - "time": "2020-10-14T08:39:05+00:00" + "time": "2020-10-14T08:32:19+00:00" }, { "name": "symfony/debug-bundle", diff --git a/config/bundles.php b/config/bundles.php index 89fd397f..788a9db1 100755 --- a/config/bundles.php +++ b/config/bundles.php @@ -19,6 +19,6 @@ Vich\UploaderBundle\VichUploaderBundle::class => ['all' => true], Sensio\Bundle\FrameworkExtraBundle\SensioFrameworkExtraBundle::class => ['all' => true], DH\AuditorBundle\DHAuditorBundle::class => ['all' => true], - Baldinof\RoadRunnerBundle\BaldinofRoadRunnerBundle::class => ['all' => true], + K911\Swoole\Bridge\Symfony\Bundle\SwooleBundle::class => ['all' => true], Symfony\Bundle\DebugBundle\DebugBundle::class => ['dev' => true, 'test' => true], ]; diff --git a/config/packages/baldinof_road_runner.yaml b/config/packages/baldinof_road_runner.yaml deleted file mode 100755 index aa9b7642..00000000 --- a/config/packages/baldinof_road_runner.yaml +++ /dev/null @@ -1,9 +0,0 @@ -baldinof_road_runner: - # The kernel is preserved between requests. Change this to `true` - # if you want to reboot it, and use a fresh container on each request. - kernel_reboot: - strategy: false - - # Integrations are automatically detected, depending on installed bundle & current configuration - # See https://github.com/baldinof/roadrunner-bundle#integrations - default_integrations: true diff --git a/config/packages/k911_swoole.yaml b/config/packages/k911_swoole.yaml new file mode 100755 index 00000000..6d8f1d0f --- /dev/null +++ b/config/packages/k911_swoole.yaml @@ -0,0 +1,10 @@ +swoole: + http_server: + port: 9501 + host: 0.0.0.0 + running_mode: process + socket_type: tcp + ssl_enabled: false + static: advanced + services: + session_cookie_event_listener: true diff --git a/docker-compose.yml b/docker-compose.yml index e3ffcc1d..3b18aaa8 100644 --- a/docker-compose.yml +++ b/docker-compose.yml @@ -9,7 +9,7 @@ services: volumes: - .:/semart ports: - - 80:8080 + - 80:9501 links: - session - db diff --git a/docker/php/php.ini b/docker/php/php.ini index df8e7633..d9c70fbb 100644 --- a/docker/php/php.ini +++ b/docker/php/php.ini @@ -917,6 +917,8 @@ default_socket_timeout = 60 ;extension=php_pgsql.dll ;extension=php_shmop.dll +extension=swoole.so + ; The MIBS data available in the PHP distribution must be installed. ; See http://www.php.net/manual/en/snmp.installation.php ;extension=php_snmp.dll diff --git a/docker/start.sh b/docker/start.sh index 3130217d..41685fc3 100644 --- a/docker/start.sh +++ b/docker/start.sh @@ -20,10 +20,7 @@ chmod 777 -R var/ chmod 777 -R storage/ chmod 755 -R config/ chmod 755 -R vendor/ +chmod 755 -R public/ -if [[ "prod" == "${APP_ENV}" ]]; then - /usr/bin/supervisord -n -c /etc/supervisord.prod.conf -else - /usr/bin/supervisord -n -c /etc/supervisord.dev.conf -fi +/usr/bin/supervisord -n -c /etc/supervisord.conf diff --git a/docker/supervisor/supervisor.prod.conf b/docker/supervisor/supervisor.prod.conf deleted file mode 100644 index bb9271e1..00000000 --- a/docker/supervisor/supervisor.prod.conf +++ /dev/null @@ -1,49 +0,0 @@ -; supervisor config file - -[unix_http_server] -file=/var/run/supervisor.sock ; (the path to the socket file) -chmod=0700 ; sockef file mode (default 0700) - -[supervisord] -logfile=/var/log/supervisor/supervisord.log ; (main log file;default $CWD/supervisord.log) -pidfile=/var/run/supervisord.pid ; (supervisord pidfile;default supervisord.pid) -childlogdir=/var/log/supervisor ; ('AUTO' child log dir, default $TEMP) -nodaemon=true - -; the below section must remain in the config file for RPC -; (supervisorctl/web interface) to work, additional interfaces may be -; added by defining them in separate rpcinterface: sections -[rpcinterface:supervisor] -supervisor.rpcinterface_factory = supervisor.rpcinterface:make_main_rpcinterface - -[supervisorctl] -serverurl=unix:///var/run/supervisor.sock ; use a unix:// URL for a unix socket - -; The [include] section can just contain the "files" setting. This -; setting can list multiple files (separated by whitespace or -; newlines). It can also contain wildcards. The filenames are -; interpreted as relative to this file. Included files *cannot* -; include files themselves. - -[program:cronjob] -command =/usr/bin/php /semart/bin/console semart:cron:start --blocking -autostart=true -autorestart=true -priority=5 -stdout_logfile=/var/log/supervisor/cronjob.out.log -stdout_logfile_maxbytes=0 -stderr_logfile=/var/log/supervisor/cronjob.error.log -stderr_logfile_maxbytes=0 - -[program:server] -command =/semart/bin/rr serve -c /semart/.rr.yaml -autostart=true -autorestart=true -priority=5 -stdout_logfile=/var/log/supervisor/server.out.log -stdout_logfile_maxbytes=0 -stderr_logfile=/var/log/supervisor/server.error.log -stderr_logfile_maxbytes=0 - -[include] -files = /etc/supervisor/conf.d/*.conf diff --git a/docker/supervisor/supervisor.dev.conf b/docker/supervisor/supervisord.conf similarity index 92% rename from docker/supervisor/supervisor.dev.conf rename to docker/supervisor/supervisord.conf index 11a8d3fe..97e0f6d9 100644 --- a/docker/supervisor/supervisor.dev.conf +++ b/docker/supervisor/supervisord.conf @@ -26,7 +26,7 @@ serverurl=unix:///var/run/supervisor.sock ; use a unix:// URL for a unix socket ; include files themselves. [program:cronjob] -command =/usr/bin/php /semart/bin/console semart:cron:start --blocking +command=/usr/bin/php /semart/bin/console semart:cron:start --blocking autostart=true autorestart=true priority=5 @@ -36,7 +36,7 @@ stderr_logfile=/var/log/supervisor/cronjob.error.log stderr_logfile_maxbytes=0 [program:server] -command =/semart/bin/rr serve -c /semart/.rr.dev.yaml +command=/usr/bin/php /semart/bin/console swoole:server:run autostart=true autorestart=true priority=5 diff --git a/symfony.lock b/symfony.lock index 0c44d94d..731232ba 100644 --- a/symfony.lock +++ b/symfony.lock @@ -1,15 +1,6 @@ { - "baldinof/roadrunner-bundle": { - "version": "1.2", - "recipe": { - "repo": "github.com/symfony/recipes-contrib", - "branch": "master", - "version": "1.2", - "ref": "47c159c44eb9e6902828da4acbb4199757dd378f" - }, - "files": [ - "config/packages/baldinof_road_runner.yaml" - ] + "beberlei/assert": { + "version": "v3.3.1" }, "behat/transliterator": { "version": "v1.3.0" @@ -162,6 +153,9 @@ "justinrainbow/json-schema": { "version": "5.2.9" }, + "k911/swoole-bundle": { + "version": "v0.10.0" + }, "lcobucci/clock": { "version": "2.0.0" }, @@ -241,12 +235,6 @@ "psr/event-dispatcher": { "version": "1.0.0" }, - "psr/http-factory": { - "version": "1.0.1" - }, - "psr/http-message": { - "version": "1.0.1" - }, "psr/link": { "version": "1.0.0" }, @@ -304,21 +292,6 @@ "config/packages/snc_redis.yaml" ] }, - "spiral/goridge": { - "version": "v2.4.5" - }, - "spiral/roadrunner": { - "version": "v1.9.2" - }, - "spiral/roadrunner-cli": { - "version": "v2.0.4" - }, - "spiral/roadrunner-http": { - "version": "v2.0.0" - }, - "spiral/roadrunner-worker": { - "version": "v2.0.3" - }, "stof/doctrine-extensions-bundle": { "version": "1.2", "recipe": { @@ -537,9 +510,6 @@ "symfony/property-info": { "version": "v5.0.8" }, - "symfony/psr-http-message-bridge": { - "version": "v2.1.0" - }, "symfony/redis-messenger": { "version": "v5.1.0" },