Giter Club home page Giter Club logo

vapor-ui's Introduction

This package is deprecated and will not receive Laravel ^11.0 support, as its functionality is largely replaced by Vapor's own dashboard.

Laravel Vapor UI

Build Status Total Downloads Latest Stable Version License

Laravel Vapor is an auto-scaling, serverless deployment platform for Laravel, powered by AWS Lambda. Manage your Laravel infrastructure on Vapor and fall in love with the scalability and simplicity of serverless.

Vapor abstracts the complexity of managing Laravel applications on AWS Lambda, as well as interfacing those applications with SQS queues, databases, Redis clusters, networks, CloudFront CDN, and more.

This package provides a beautiful dashboard accessible via your Vapor application that allows you to view / search your application's logs and failed queue jobs.

image

Official Documentation

Documentation for Vapor UI can be found in the Laravel Vapor documentation.

Contributing

Thank you for considering contributing to Vapor UI! You can read the contribution guide here.

Code of Conduct

In order to ensure that the Laravel community is welcoming to all, please review and abide by the Code of Conduct.

Security Vulnerabilities

Please review our security policy on how to report security vulnerabilities.

License

Laravel Vapor UI is open-sourced software licensed under the MIT license.

vapor-ui's People

Contributors

alberthaff avatar arnhoe avatar atymic avatar dammy001 avatar driesvints avatar duncanmcclean avatar felipeoalbert avatar giannicic avatar jasonfah avatar joedixon avatar mo7zayed avatar nunomaduro avatar taylorotwell avatar timacdonald avatar

Stargazers

 avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar

Watchers

 avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar

vapor-ui's Issues

PhpSpreadsheet: error trying to download a Xlsx file on Vapor

  • Vapor UI Version: 1.5.3
  • Vapor Core Version: 2.23.0
  • Laravel Version: 8.83.23
  • PHP Version: 7.4.30

Description:

Vapor returns "Internal server error" when I try to download a Xlsx from PhpSpreadsheet. It works locally with Xlsx. It works on Vapor with Csv but not with Xlsx.

AWS Log:
Fatal error: Uncaught Exception: Error encoding runtime JSON response: Malformed UTF-8 characters, possibly incorrectly encoded in /var/task/vendor/laravel/vapor-core/src/Runtime/NotifiesLambda.php:49

Stack trace:
.0 /var/task/vendor/laravel/vapor-core/src/Runtime/NotifiesLambda.php(19): Laravel\Vapor\Runtime\LambdaRuntime->lambdaRequest('http://127.0.0....', Array)
.1 /var/task/vendor/laravel/vapor-core/src/Runtime/LambdaRuntime.php(53): Laravel\Vapor\Runtime\LambdaRuntime->notifyLambdaOfResponse('9701efbf-d000-4...', Array)
.2 /var/task/fpmRuntime.php(88): Laravel\Vapor\Runtime\LambdaRuntime->nextInvocation(Object(Closure))
.3 /var/task/runtime.php(36): require('/var/task/fpmRu...')
.4 /opt/bootstrap.php(6): require('/var/task/runti...')

Steps To Reproduce:

  1. Add package phpoffice/phpspreadsheet
  2. Code:
$spreadsheet = new \PhpOffice\PhpSpreadsheet\Spreadsheet();
$spreadsheet->setActiveSheetIndex(0)->setCellValue('A1', 'Hello');
$writer = new \PhpOffice\PhpSpreadsheet\Writer\Xlsx($spreadsheet);
header('Content-Type: application/vnd.openxmlformats-officedocument.spreadsheetml.sheet');
header('Content-Disposition: attachment; filename="filename.xlsx"');
$writer->save('php://output');
  1. Vapor returns "Internal server error"

Expected behavior

Download the file

Default timestamp for logs is wrong

  • Vapor UI Version: 0.0.6
  • Laravel Version: 8.2.0
  • PHP Version: 7.4.10
  • Database Driver & Version: Mysql 8

Description:

When i load /vapor-ui url, it loads with selected time 5 hours from now, so its in the future and of course doesnt display anything. (The 5 hours difference correspond to my timezone that is UTC-5).
To make things worst, when i click on Job->Metrics and the back to Logs->HTTP, its now 10 hours in the future. if i repeat that click series, it continues incrementing 5 hours to the logs screen...

My timezone is correctly configured in my application, and has been working fine for many years. Laravel Nova also respects my timezone. I have to manually change the start datetime, but its also a little difficult because it changes back again when it finish loading items...

Steps To Reproduce:

  • Load HTTP Logs Screen
  • Click on Job->Metrics
  • Click on Logs->HTTP
  • Click on Job->Metrics
  • Click on Logs->HTTP
  • ...

Feature request: Be able to add other queues to be monitored

Hi there.

Currently it's not possible to monitor queued jobs on other queues than the default in the vapor-ui dashboard.

What I propose is a way to add a list of custom queues on the vapor-ui config file. So this way we can keep track of all the jobs per queue. To be honest I'm not sure about the current implementation and if it's easy to implement. But it could help a lot I think.

Retrying failed jobs with retryUntil

Currently, when retrying failed jobs, it would be nice to be able to retry those that have failed due to a retryUntil parameter elapsing.

Present thought would be that when retrying a job with an expired retryUntil we could reset that value by an hour from the current time.

If this solution makes sense would you be open to accepting a PR for it?

Symfony yaml parser not found

  • Vapor UI Version: 1.1.0
  • Laravel Version: 8.44.0
  • PHP Version: 8.0.0
  • Database Driver & Version: mysql 5.7

Description:

Upgrade to 1.1.0 broke vapor-ui

"message": "Class \"Symfony\\Component\\Yaml\\Parser\" not found",
    "context": {
        "userId": 12,
        "exception": {
            "class": "Error",
            "message": "Class \"Symfony\\Component\\Yaml\\Parser\" not found",
            "code": 0,
            "file": "/var/task/vendor/laravel/vapor-ui/src/Support/Cloud.php:56"
        },
        "aws_request_id": "331324ac-e1a6-4579-9dcc-6d039b3bd2c9"
    },
    "level": 400,
    "level_name": "ERROR",
    "channel": "staging",
    "datetime": "2021-06-01T19:52:13.503123+00:00",
    "extra": {}

Steps To Reproduce:

upgrade to 1.1.0

Unable to open

  • Vapor UI Version: #.#.#
  • Laravel Version: #.#.#
  • PHP Version: #.#.#
  • Database Driver & Version:

Description:

截屏2022-08-30 00 36 27

Steps To Reproduce:

Laravel Vapor UI without session

Hi there, I have an api which I don't have sessions. We used token based auth.
Is it possible to have vapor-ui with out session?

if it is used only for auth guard maybe we can have an ip restriction instead of user.

When I try to open vapor-ui dashboard I got this error.

{
  "message": "Target class [session] does not exist. (View: /var/task/vendor/laravel/vapor-ui/resources/views/layout.blade.php)",
  "context": {
    "view": {
      "view": "/var/task/vendor/laravel/framework/src/Illuminate/Container/Container.php",
      "data": []
    },
    "exception": {
      "class": "Facade\\Ignition\\Exceptions\\ViewException",
      "message": "Target class [session] does not exist. (View: /var/task/vendor/laravel/vapor-ui/resources/views/layout.blade.php)",
      "code": 0,
      "file": "/var/task/vendor/laravel/framework/src/Illuminate/Container/Container.php:838",
      "previous": {
        "class": "Illuminate\\Contracts\\Container\\BindingResolutionException",
        "message": "Target class [session] does not exist.",
        "code": 0,
        "file": "/var/task/vendor/laravel/framework/src/Illuminate/Container/Container.php:838",
        "previous": {
          "class": "ReflectionException",
          "message": "Class \"session\" does not exist",
          "code": -1,
          "file": "/var/task/vendor/laravel/framework/src/Illuminate/Container/Container.php:836"
        }
      }
    }
  }
}

kind regards.

Error when trying to view metrics

  • Vapor UI Version: 0.0.8
  • Laravel Version: 7.28.3
  • PHP Version: 7.4
  • Database Driver & Version: MySQL 8

Description:

When viewing the Vapor metrics page, an exception is thrown and no data is presented. We just see a Server Error notice. This is the same on both our staging and productions environments, both within Vapor.

InvalidArgumentExceptionGET /vapor-ui/api/jobs/metrics
Unable to handle the provided timestamp type: object

InvalidArgumentException Unable to handle the provided timestamp type: object 
    /tmp/vendor/aws/aws-sdk-php/src/Api/TimestampShape.php:32 Aws\Api\TimestampShape::format
    /tmp/vendor/aws/aws-sdk-php/src/Api/Serializer/QueryParamBuilder.php:150 Aws\Api\Serializer\QueryParamBuilder::format_timestamp
    /tmp/vendor/aws/aws-sdk-php/src/Api/Serializer/QueryParamBuilder.php:55 Aws\Api\Serializer\QueryParamBuilder::format
    /tmp/vendor/aws/aws-sdk-php/src/Api/Serializer/QueryParamBuilder.php:75 Aws\Api\Serializer\QueryParamBuilder::format_structure
    /tmp/vendor/aws/aws-sdk-php/src/Api/Serializer/QueryParamBuilder.php:46 Aws\Api\Serializer\QueryParamBuilder::__invoke
    [internal] call_user_func
    /tmp/vendor/aws/aws-sdk-php/src/Api/Serializer/QuerySerializer.php:51 Aws\Api\Serializer\QuerySerializer::__invoke
    /tmp/vendor/aws/aws-sdk-php/src/Middleware.php:96 Aws\Middleware::Aws\{closure}
    /tmp/vendor/aws/aws-sdk-php/src/Middleware.php:80 Aws\Middleware::Aws\{closure}
    /tmp/vendor/aws/aws-sdk-php/src/IdempotencyTokenMiddleware.php:77 Aws\IdempotencyTokenMiddleware::__invoke
    /tmp/vendor/aws/aws-sdk-php/src/AwsClientTrait.php:64 Aws\AwsClient::executeAsync
    /tmp/vendor/aws/aws-sdk-php/src/AwsClientTrait.php:58 Aws\AwsClient::execute
    /tmp/vendor/aws/aws-sdk-php/src/AwsClientTrait.php:86 Aws\AwsClient::__call
    /tmp/vendor/laravel/vapor-ui/src/Repositories/JobsMetricsRepository.php:243 Laravel\VaporUi\Repositories\JobsMetricsRepository::logs
    /tmp/vendor/laravel/vapor-ui/src/Repositories/JobsMetricsRepository.php:162 Laravel\VaporUi\Repositories\JobsMetricsRepository::processedTimeseries
    /tmp/vendor/laravel/vapor-ui/src/Http/Controllers/JobMetricController.php:42 Laravel\VaporUi\Http\Controllers\JobMetricController::index
    /tmp/vendor/laravel/framework/src/Illuminate/Routing/ControllerDispatcher.php:48 Illuminate\Routing\ControllerDispatcher::dispatch
    /tmp/vendor/laravel/framework/src/Illuminate/Routing/Route.php:239 Illuminate\Routing\Route::runController
    /tmp/vendor/laravel/framework/src/Illuminate/Routing/Route.php:196 Illuminate\Routing\Route::run
    /tmp/vendor/laravel/framework/src/Illuminate/Routing/Router.php:685 Illuminate\Routing\Router::Illuminate\Routing\{closure}
    /tmp/vendor/laravel/framework/src/Illuminate/Pipeline/Pipeline.php:128 Illuminate\Pipeline\Pipeline::Illuminate\Pipeline\{closure}
    /tmp/vendor/laravel/vapor-ui/src/Http/Middleware/EnsureUpToDateAssets.php:34 Laravel\VaporUi\Http\Middleware\EnsureUpToDateAssets::handle
    /tmp/vendor/laravel/framework/src/Illuminate/Pipeline/Pipeline.php:167 Illuminate\Pipeline\Pipeline::Illuminate\Pipeline\{closure}
    /tmp/vendor/laravel/vapor-ui/src/Http/Middleware/EnsureEnvironmentVariables.php:44 Laravel\VaporUi\Http\Middleware\EnsureEnvironmentVariables::handle
    /tmp/vendor/laravel/framework/src/Illuminate/Pipeline/Pipeline.php:167 Illuminate\Pipeline\Pipeline::Illuminate\Pipeline\{closure}
    /tmp/vendor/laravel/vapor-ui/src/Http/Middleware/EnsureUserIsAuthorized.php:26 Laravel\VaporUi\Http\Middleware\EnsureUserIsAuthorized::handle
    /tmp/vendor/laravel/framework/src/Illuminate/Pipeline/Pipeline.php:167 Illuminate\Pipeline\Pipeline::Illuminate\Pipeline\{closure}
    /tmp/vendor/laravel/passport/src/Http/Middleware/CreateFreshApiToken.php:50 Laravel\Passport\Http\Middleware\CreateFreshApiToken::handle
    /tmp/vendor/laravel/framework/src/Illuminate/Pipeline/Pipeline.php:167 Illuminate\Pipeline\Pipeline::Illuminate\Pipeline\{closure}
    /tmp/vendor/laravel/framework/src/Illuminate/Routing/Middleware/SubstituteBindings.php:41 Illuminate\Routing\Middleware\SubstituteBindings::handle
    /tmp/vendor/laravel/framework/src/Illuminate/Pipeline/Pipeline.php:167 Illuminate\Pipeline\Pipeline::Illuminate\Pipeline\{closure}
    /tmp/vendor/laravel/framework/src/Illuminate/Foundation/Http/Middleware/VerifyCsrfToken.php:77 Illuminate\Foundation\Http\Middleware\VerifyCsrfToken::handle
    /tmp/vendor/laravel/framework/src/Illuminate/Pipeline/Pipeline.php:167 Illuminate\Pipeline\Pipeline::Illuminate\Pipeline\{closure}
    /tmp/vendor/laravel/framework/src/Illuminate/View/Middleware/ShareErrorsFromSession.php:49 Illuminate\View\Middleware\ShareErrorsFromSession::handle
    /tmp/vendor/laravel/framework/src/Illuminate/Pipeline/Pipeline.php:167 Illuminate\Pipeline\Pipeline::Illuminate\Pipeline\{closure}
    /tmp/vendor/laravel/framework/src/Illuminate/Session/Middleware/StartSession.php:116 Illuminate\Session\Middleware\StartSession::handleStatefulRequest
    /tmp/vendor/laravel/framework/src/Illuminate/Session/Middleware/StartSession.php:62 Illuminate\Session\Middleware\StartSession::handle
    /tmp/vendor/laravel/framework/src/Illuminate/Pipeline/Pipeline.php:167 Illuminate\Pipeline\Pipeline::Illuminate\Pipeline\{closure}
    /tmp/vendor/laravel/framework/src/Illuminate/Cookie/Middleware/AddQueuedCookiesToResponse.php:37 Illuminate\Cookie\Middleware\AddQueuedCookiesToResponse::handle
    /tmp/vendor/laravel/framework/src/Illuminate/Pipeline/Pipeline.php:167 Illuminate\Pipeline\Pipeline::Illuminate\Pipeline\{closure}
    /tmp/vendor/laravel/framework/src/Illuminate/Cookie/Middleware/EncryptCookies.php:67 Illuminate\Cookie\Middleware\EncryptCookies::handle
    /tmp/vendor/laravel/framework/src/Illuminate/Pipeline/Pipeline.php:167 Illuminate\Pipeline\Pipeline::Illuminate\Pipeline\{closure}
    /tmp/vendor/laravel/framework/src/Illuminate/Pipeline/Pipeline.php:103 Illuminate\Pipeline\Pipeline::then
    /tmp/vendor/laravel/framework/src/Illuminate/Routing/Router.php:687 Illuminate\Routing\Router::runRouteWithinStack
    /tmp/vendor/laravel/framework/src/Illuminate/Routing/Router.php:662 Illuminate\Routing\Router::runRoute
    /tmp/vendor/laravel/framework/src/Illuminate/Routing/Router.php:628 Illuminate\Routing\Router::dispatchToRoute
    /tmp/vendor/laravel/framework/src/Illuminate/Routing/Router.php:617 Illuminate\Routing\Router::dispatch
    /tmp/vendor/laravel/framework/src/Illuminate/Foundation/Http/Kernel.php:165 Illuminate\Foundation\Http\Kernel::Illuminate\Foundation\Http\{closure}
    /tmp/vendor/laravel/framework/src/Illuminate/Pipeline/Pipeline.php:128 Illuminate\Pipeline\Pipeline::Illuminate\Pipeline\{closure}
    app/Http/Middleware/SetPreferredLanguage.php:22 App\Http\Middleware\SetPreferredLanguage::handle
    /tmp/vendor/laravel/framework/src/Illuminate/Pipeline/Pipeline.php:167 Illuminate\Pipeline\Pipeline::Illuminate\Pipeline\{closure}
    /tmp/vendor/laravel/framework/src/Illuminate/Foundation/Http/Middleware/TransformsRequest.php:21 Illuminate\Foundation\Http\Middleware\TransformsRequest::handle
    /tmp/vendor/laravel/framework/src/Illuminate/Pipeline/Pipeline.php:167 Illuminate\Pipeline\Pipeline::Illuminate\Pipeline\{closure}
    /tmp/vendor/laravel/framework/src/Illuminate/Foundation/Http/Middleware/TransformsRequest.php:21 Illuminate\Foundation\Http\Middleware\TransformsRequest::handle
    /tmp/vendor/laravel/framework/src/Illuminate/Pipeline/Pipeline.php:167 Illuminate\Pipeline\Pipeline::Illuminate\Pipeline\{closure}
    /tmp/vendor/laravel/framework/src/Illuminate/Foundation/Http/Middleware/ValidatePostSize.php:27 Illuminate\Foundation\Http\Middleware\ValidatePostSize::handle
    /tmp/vendor/laravel/framework/src/Illuminate/Pipeline/Pipeline.php:167 Illuminate\Pipeline\Pipeline::Illuminate\Pipeline\{closure}
    /tmp/vendor/laravel/framework/src/Illuminate/Foundation/Http/Middleware/CheckForMaintenanceMode.php:63 Illuminate\Foundation\Http\Middleware\CheckForMaintenanceMode::handle
    /tmp/vendor/laravel/framework/src/Illuminate/Pipeline/Pipeline.php:167 Illuminate\Pipeline\Pipeline::Illuminate\Pipeline\{closure}
    /tmp/vendor/fruitcake/laravel-cors/src/HandleCors.php:37 Fruitcake\Cors\HandleCors::handle
    /tmp/vendor/laravel/framework/src/Illuminate/Pipeline/Pipeline.php:167 Illuminate\Pipeline\Pipeline::Illuminate\Pipeline\{closure}
    /tmp/vendor/fideloper/proxy/src/TrustProxies.php:57 Fideloper\Proxy\TrustProxies::handle
    /tmp/vendor/laravel/framework/src/Illuminate/Pipeline/Pipeline.php:167 Illuminate\Pipeline\Pipeline::Illuminate\Pipeline\{closure}
    /tmp/vendor/laravel/framework/src/Illuminate/Pipeline/Pipeline.php:103 Illuminate\Pipeline\Pipeline::then
    /tmp/vendor/laravel/framework/src/Illuminate/Foundation/Http/Kernel.php:140 Illuminate\Foundation\Http\Kernel::sendRequestThroughRouter
    /tmp/vendor/laravel/framework/src/Illuminate/Foundation/Http/Kernel.php:109 Illuminate\Foundation\Http\Kernel::handle
    /tmp/vendor/laravel/vapor-core/src/Runtime/HttpKernel.php:62 Laravel\Vapor\Runtime\HttpKernel::Laravel\Vapor\Runtime\{closure}
    /tmp/vendor/laravel/framework/src/Illuminate/Pipeline/Pipeline.php:128 Illuminate\Pipeline\Pipeline::Illuminate\Pipeline\{closure}
    /tmp/vendor/laravel/vapor-core/src/Runtime/Http/Middleware/EnsureBinaryEncoding.php:19 Laravel\Vapor\Runtime\Http\Middleware\EnsureBinaryEncoding::handle
    /tmp/vendor/laravel/framework/src/Illuminate/Pipeline/Pipeline.php:167 Illuminate\Pipeline\Pipeline::Illuminate\Pipeline\{closure}
    /tmp/vendor/laravel/vapor-core/src/Runtime/Http/Middleware/EnsureVanityUrlIsNotIndexed.php:16 Laravel\Vapor\Runtime\Http\Middleware\EnsureVanityUrlIsNotIndexed::handle
    /tmp/vendor/laravel/framework/src/Illuminate/Pipeline/Pipeline.php:167 Illuminate\Pipeline\Pipeline::Illuminate\Pipeline\{closure}
    /tmp/vendor/laravel/vapor-core/src/Runtime/Http/Middleware/RedirectStaticAssets.php:30 Laravel\Vapor\Runtime\Http\Middleware\RedirectStaticAssets::handle
    /tmp/vendor/laravel/framework/src/Illuminate/Pipeline/Pipeline.php:167 Illuminate\Pipeline\Pipeline::Illuminate\Pipeline\{closure}
    /tmp/vendor/laravel/vapor-core/src/Runtime/Http/Middleware/EnsureOnNakedDomain.php:39 Laravel\Vapor\Runtime\Http\Middleware\EnsureOnNakedDomain::handle
    /tmp/vendor/laravel/framework/src/Illuminate/Pipeline/Pipeline.php:167 Illuminate\Pipeline\Pipeline::Illuminate\Pipeline\{closure}
    /tmp/vendor/laravel/framework/src/Illuminate/Pipeline/Pipeline.php:103 Illuminate\Pipeline\Pipeline::then
    /tmp/vendor/laravel/vapor-core/src/Runtime/HttpKernel.php:63 Laravel\Vapor\Runtime\HttpKernel::handle
    httpHandler.php:55 [main]

Logs are no longer being displayed after placing the lambdas into a custom VPC

  • Vapor UI Version: 1.0.0
  • Laravel Version: 8.19.0
  • PHP Version: 7.4
  • Database Driver & Version: RDS MySQL 8.0

Description:

As we needed a fixed outgoing IP address for our lambda containers (firewall whitelisting) we placed them into a custom VPC. We followed the official vapor documentation (https://docs.vapor.build/1.0/projects/environments.html#gateway-versions). Everything works like a charm. But if I want to view the logs in vapor-ui (HTTP, CLI and Queue) they are empty and cannot be retrieved. Always getting the message below

Bildschirmfoto 2020-12-17 um 16 19 58

Steps To Reproduce:

  1. Place your vapor lambdas into a VPC according official vapor documentation
  2. Open /vapor-ui in your browser
  3. Try to check the logs

Can't open Logs/Show in new tab

  • Vapor UI Version: 1.0.3
  • Laravel Version: 8.45.1
  • PHP Version: 7.4
  • Database Driver & Version: MySQL 8.0

Description:

We've just been doing some testing and logged lots of stuff in a short period of time. However, when trying to view the logs, I wanted to open all the log items for a certain time in new tabs. However, as the view link (the eye) is a <button> and not a <a> tag, I can't do that.

https://github.com/laravel/vapor-ui/blob/master/resources/js/screens/logs/index.vue#L88

Steps To Reproduce:

  1. Go to Vapor UI logs (doesn't matter the type)
  2. Cmd + Click the eye button - nothing happens

Unable to detect [vapor-ui.project]. Please deploy your project, and visit this URI on a Vapor powered environment.

  • Vapor UI Version: 1.5.2
  • Laravel Version: 9.19.0
  • PHP Version: 8.1.3
  • Database Driver & Version:

Description:

After publishing the vapor-ui config file, when testing locally, all routes produce the error;
Unable to detect [vapor-ui.project]. Please deploy your project, and visit this URI on a Vapor powered environment.

Commenting out the middleware in the config file removes the error, but loads vapor-ui on any route

The problem appears to be lack of env value for the path;

   'path' => env('VAPOR_UI_PATH'),

Should default to 'vapor-ui' if no env value available

Steps To Reproduce:

  • Install vapor-ui
  • publish config using the artisan publish command
  • visit a route not associated with vapor-ui

No Support for Composer 2.0

  • Vapor UI Version: 1.11
  • PHP Version: 7.4.12

Description:

hirak/prestissimo Fails as a dependency and is not needed in composer 2.0. See hirak/prestissimo support for 2.0 and you will see the suggestion is to remove it as a dependency in composer 2.0 because there is no need for it.

Steps To Reproduce:

Just try to install it.

The Vapor UI assets are not published - on production

  • Vapor UI Version: 0.0.11
  • Laravel Version: 7.28.4

Hey Guys,
i am receiving the following issue when trying to access vapor ui. I imagine that it has something to do with the public folder files being deleted and uploaded to cloudflare.

The Vapor UI assets are not published. Please run: `php artisan vapor-ui:install.

Any suggestions to resolve this ?

No results for HTTP or Queue logs

  • Vapor UI Version: 0.0.6
  • Laravel Version: 8.1.0
  • PHP Version: 7.4
  • Database Driver & Version: MySQL 8.0

The below is the same on test/stage and production.

If I go to the Queue or HTTP logs I never get any results.
The HTTP page polls for a while and then says no results found.
The Queue page just seems to endlessly poll for new results but never gets any.

Is there a setting in AWS I need to enable to get output for these sections?

I get logs for CLI with the schedule:run output.

image

I also have results on the great new Metrics page.
image

vapor.yml

environments:
  production:
    timeout: 900
    gateway-version: 2
    runtime: php-7.4
    cache: xxxxx
    cli-concurrency: 10
    cli-memory: 256
    cli-timeout: 900
    concurrency: 30
    database: xxxxx
    domain: xxxxx
    memory: 256
    storage: xxxxx
    queue-concurrency: 10
    queue-memory: 256
    warm: 5

Don't load all failed jobs

Currently the "jobs" page will load all failed jobs from the database, in order to calculate the statistics.

We had quite a bit of failed jobs in our database (~500.000) which obviously took too long to load. This resulted in the request timing out and the statistics not loading.

Code:

$this->failedJobsCollection = collect($this->failedJobs->all());

I'm not sure what the proper solution to this issue would be. Ideally, we would run one query that gives us all the statistics we need (that we now calculate using the collections).

Thoughts? Willing to contribute on a fix but not sure about what's desired here.

Gitlab intergration

Laravel Vapor already has support for linking GitHub commits to deployments, would it be possible to have the same option for GitLab repositories? Thanks!

Two entries for single Log::debug causing json_decode syntax error

  • Vapor UI Version: 1.0.3
  • Laravel Version: 8.38.0
  • PHP Version: 8.0.0
  • Database Driver & Version: MySQL 8

Description:

Manually doing a Log::debug() with custom array data causes the event message to be split into two entries.

Log::debug('rateprovidertest.myshopify.com', ['payload' => $payloadArray]);

This above line should only display rateprovidertest.myshopify.com in the table and the payload should go in context object. But this JSON is not decoded at all. json_last_error_message() gives a Syntax Error too.
image

Steps To Reproduce:

Log::debug() something like example json data in your project hosted on Laravel Vapor and then try to see this log in Vapor UI.

Thoughts:

I am not sure if this is a problem on Laravel Vapor side or AWS side. Why one Log::debug() is split into two events?

Not getting any logs despite seeing them in Vapor dashboard

  • Vapor UI Version: 1.0
  • Laravel Version: 7.28
  • PHP Version: 7.4
  • Database Driver & Version: MySQL

Description:

After installing and configuring Vapor UI, I can see the metrics and failed jobs fine, but cannot see any logs for http, cli or queue no matter what or how far back I search I always get "No entries were found for the given search criteria. ". I also do not get an option to "keep searching" as mentioned in other issues. If I login to the Vapor website I can see recent logs no problem.

Steps To Reproduce:

  1. Fresh install of Vapor UI using: composer require laravel/vapor-ui
  2. Publish assets using: php artisan vapor-ui:install
  3. Add VAPOR_ENVIRONMENT & VAPOR_PROJECT to .env for staging environment
  4. Try to access logs on http://localhost/vapor-ui

Facing issues with vapor-ui customization

  • Vapor UI Version: v1.5.1
  • Laravel Version: 8.80.0
  • PHP Version: ^8.0

We are integrating vapor-ui in our system. so I need to do some customization in the layout and route.

Layout Customization:

I used vapor-UI authentication based on the nova session so I need to add a link into vapor-ui navigation for directly navigating to nova admin and another link add for the logout nova user without going to nova admin.

So I exported the vapor-ui layout in my resources vendor folder from the vapor-ui package and added nova admin and logout links to navigation. but now it's properly and does not convert any router link to the anchor tag. and also not getting any vapor-ui vuejs component result you can see in the attached images.

image

Screenshot at Feb 01 20-35-28

Route Customization:

Also, I made some changes in the vapor-ui route. I have moved the web.php file from the "vendor/laravel/vapor-ui/routes/web.php" to the "public/vendor/vapor-ui/routes/web.php" and removed "name('vapor-ui')" from the below code.

    ->group(function () {
        Route::get('/api/logs/{group}', [LogController::class, 'index']);
        Route::get('/api/logs/{group}/{id}', [LogController::class, 'show']);

        Route::get('/api/jobs/metrics', [JobMetricController::class, 'index']);

        Route::get('/api/jobs/{group}', [JobController::class, 'index']);
        Route::get('/api/jobs/{group}/{id}', [JobController::class, 'show']);

        Route::post('/api/jobs/failed/retry/{id}', [JobController::class, 'retry']);
        Route::post('/api/jobs/failed/forget/{id}', [JobController::class, 'forget']);

        Route::get('/{view?}', HomeController::class)->where('view', '(.*)')->name('vapor-ui');
    }); 

Because I have changed vapor-ui config and I have changed the path with the "/" but it does not reflect it always reflects with default "vapor-ui" and all the navigation links created with "vapor-ui" so I need to Replace "vapor-ui" with "/" so that I have made this changes.

But after the made this change vapor-ui getting the error you can see in the attached Image.

Screenshot at Feb 03 11-46-18

Feature request: insights into overprovisioned memory

It would be amazing if this package could give users some insights into their actual lambda memory usage versus the configured memory limit. This could help users find a more optimised memory setting.

Running the following query in CloudWatch Insights on a lambda http log:

filter @type = "REPORT"
| stats max(@memorySize / 1024 / 1024) as provisonedMemoryMB,
  min(@maxMemoryUsed / 1024 / 1024) as smallestMemoryRequestMB,
  avg(@maxMemoryUsed / 1024 / 1024) as avgMemoryUsedMB,
  max(@maxMemoryUsed / 1024 / 1024) as maxMemoryUsedMB,
  provisonedMemoryMB - maxMemoryUsedMB as overProvisionedMB

results in:

provisonedMemoryMB smallestMemoryRequestMB avgMemoryUsedMB maxMemoryUsedMB overProvisionedMB
732.4219 232.6965 309.3292 311.8515 420.5704

Issue viewing dashboard

Hi,

I have the following error.

Screenshot 2020-09-03 at 15 08 48

I followed the docs, installed and I'm using Laravel 7.26.0
Any help/advice greatly appreciated :)

Job metrics for environments with multiple queues

Hi,

I've just got the vapor-ui setup in my application over the weekend, but noticed that the metrics for jobs are only reporting from the default queue for the Vapor environment. It'd be great to be able to see the metrics and failed jobs for each once our migration to Vapor is complete, as our existing production environment runs on multiple queues using Redis with Horizon.

Is this something that would be feasible to add to the vapor-ui? And if so, is it already on the vapor-ui team's roadmap, or would this be something that only comes in if developed via an external pull request?

Thanks!

Queue Stats by Job

Currently you can't see stats by jobs, only as a whole.

It would be great to be able to either filter down by job, or to see metrics down to job level.

This would probably require some changes to vapor core to log the job info at the start of the job execution.

Happy to PR any required work.

Long commands are always truncated

  • Vapor UI Version: ??
  • Laravel Version: 8.x
  • PHP Version: 7.x
  • Database Driver & Version: MySQL

Description:

After executing commands via the Vapor GUI, the full command line is not visible, it is simpy truncated at 40 characters or so, even though there is plenty of space on a full HD screen.

To see the full command I have to move the mouse pointer over the truncated command, but it is not possible to copy the command to the clipboard.

Steps To Reproduce:

  • Run command via GUI like inspire "It is quality rather than quantity that matters. - Lucius Annaeus Seneca"
  • have a look on the list of "Recent Commands"
  • have a look on latest "Command Details"

Laravel 11.x support

It seems that vapor-ui cannot be used with Laravel 11

- laravel/vapor-ui[dev-master, v1.7.0, ..., 1.x-dev] require laravel/framework ^8.0|^9.0|^10.0 -> 
found laravel/framework[v8.0.0, ..., 8.x-dev, v9.0.0-beta.1, ..., 9.x-dev, v10.0.0, ..., 10.x-dev] 
but it conflicts with your root composer.json require (^11.0).

Please fix.

Server Error When Viewing Jobs Details

  • Vapor UI Version: 1.5.2
  • Laravel Version: 9.8.1
  • PHP Version: 8.0.13
  • Database Driver & Version: mySQL

Description:

When trying to view either the Metrics or Failed section for Jobs on Vapor UI, I receive the attached message. This occurs regardless of what queue I select, and what timeframe I select. This error occurs on my production environment only; the staging environment for the exact same application works as expected.

Capture

I have checked the application logs per the suggestion and there are no errors related to why this error might be occurring. I also know based on the fact that I am seeing the results of my jobs (e.g., emails being sent, tasks being completed, etc.) that they are indeed running and executing properly.

I can't find any information in the documentation or on the various Laravel help pages about why this might be occurring, or how to fix it. Can the team provide any insight into what generates this error so that I can more effectively debug?

Steps To Reproduce:

View the Metrics or Failed page for Jobs.

Cloudflare integration

Hello!

Is there any chance we can get a Cloudflare integration so if we are using Cloudflare for our DNS it can be managed like Vapour manages DNS without Cloudflare? Just like using Cloudflare for all my domains and DNS

Cheers!

Dynamic number of warm lambdas

I have large projects running with almost entirely US users. I have very high traffic during business hours, but after 6pm on weekdays, and on weekends, I have almost no traffic.

It would be valuable if I was able to say:
m-f 6am-6pm: 300 warm functions
m-f 6-10 pm 100 warm functions
m-f 10pm - 6am 50 warm functions
s-s all day 50 warm functions

I would think that this would be useful to a number of clients.

Is this a bug?

  • Vapor UI Version: 1.7.2
  • Laravel Version: 10.4.1
  • PHP Version: 8.2
  • Database Driver & Version: mysql serverless v2

Description:

When I followed the documentation, I got an error.

Steps To Reproduce:

I just ran the command below.

image

Feature request: log slow requests

For most people, the AWS Console with all it's tools is quite a bit of a black box.

Since you pay for each 100ms your lambda function runs, it is beneficial to fix slow request. However, finding these request is currently quite hard.

If you enable request logs on your API Gateway, you can query them using CloudWatch Insigts. We do so and use it to show our top-10 slowest request paths:

# Avg duration Method Path
1 5000 ms GET /some/slow-path
2 4900 ms POST /another/one
3 4800 ms POST /another/one/again

For reference:

Insights query

fields @timestamp as time, integrationLatency as latency, httpMethod as method, path as url
| filter (integrationLatency>4500)
| sort latency desc
| limit 20

API Gateway log format

{
    "requestId": "$context.requestId",
    "httpMethod": "$context.httpMethod",
    "status": "$context.status",
    "path": "$context.path",
    "responseLatency": "$context.responseLatency",
    "integrationLatency": "$context.integrationLatency"
}

No Http logs are available

  • Vapor UI Version: 1.0.0
  • Laravel Version: 7.20.0
  • PHP Version: 7.4
  • Database Driver & Version: Mysql

Description:

Since we updated laravel-ui to 1.0.0 we are no longer capable of listing the Http logs in vapor-ui. We can see logs on Queue and Console screens, but Http screen is simply empty. We can see old logs (previous to the update). We can see our logs in AWS cloudwatch.

Steps To Reproduce:

  1. Update to 1.0.0
  2. Log in http request
  3. Look for new logs in Htttp vapor ui

Queue name is displayed as array

  • Vapor UI Version: 1.4
  • Laravel Version: 9
  • PHP Version: 9.48.0
  • Database Driver & Version: mysql 8

Description:

I saw the vapor update related to controlling the queue concurrency, I have updated my vapor.yml config to be like

    queues:
      - queue-1-production: 25
      - queue-2-production: 25
      - queue-3-production: 25

But the result I got is
image

it also results the following error in http logs
image

Steps To Reproduce:

  • a new laravel app
  • install required vapor packages (ui, core)
  • configure queues to be like the example above in vapor.yml file
  • deploy and go to vapor-ui dashboard

Cannot view metrics tab, error executing GetQueueAttributes

  • Vapor UI Version: v0.0.8
  • Laravel Version: v8.5.0
  • PHP Version: 7.4
  • Database Driver & Version:

Description:

When I try to open metrics tab, it spits out :
{"message":"Error executing "GetQueueAttributes" on "https://sqs.eu-west-1.amazonaws.com/XXX\"; AWS HTTP error: Client error: POST https://sqs.eu-west-1.amazonaws.com/XXXX resulted in a 403 Forbidden response:\n<ErrorResponse xmlns="http://queue.amazonaws.com/doc/2012-11-05/\">SenderS (truncated...)\n SignatureDoesNotMatch (client): The request signature we calculated does not match the signature you provided. Check your AWS Secret Access Key and signing method. Consult the service documentation for details.\n\nThe Canonical String for this request should have been\n'POST\n/XXXXX\n\nhost:sqs.eu-west-1.amazonaws.com\nx-amz-date:20200921T075900Z\nx-amz-security-token:IQoJb3JpZ2luX2VjEFgaCWV1LXdlc3QtMSJIMEYCIQCdymE8oayGlae35XsvQIafdcDvqk4dJoIg0Q4yYb7YNAIhAOvrJ6heCNzjKi8igeoe9iDUs7PXnkpG/5EWK2UIkYsAKtgBCHEQAhoMMDg4NDE5ODIyMDMzIgxHZxeXEWxE/w+PbicqtQE2ssJOmTeR1aqFC6i1N1mpJ9

I have connected vapor with admin access aws keys, so it should have access to it. Although not sure why has mismatch here.
It happens only on the metrics tab, logs and everything else works.

Steps To Reproduce:

After deploying my code to vapor

Recommend Projects

  • React photo React

    A declarative, efficient, and flexible JavaScript library for building user interfaces.

  • Vue.js photo Vue.js

    🖖 Vue.js is a progressive, incrementally-adoptable JavaScript framework for building UI on the web.

  • Typescript photo Typescript

    TypeScript is a superset of JavaScript that compiles to clean JavaScript output.

  • TensorFlow photo TensorFlow

    An Open Source Machine Learning Framework for Everyone

  • Django photo Django

    The Web framework for perfectionists with deadlines.

  • D3 photo D3

    Bring data to life with SVG, Canvas and HTML. 📊📈🎉

Recommend Topics

  • javascript

    JavaScript (JS) is a lightweight interpreted programming language with first-class functions.

  • web

    Some thing interesting about web. New door for the world.

  • server

    A server is a program made to process requests and deliver data to clients.

  • Machine learning

    Machine learning is a way of modeling and interpreting data that allows a piece of software to respond intelligently.

  • Game

    Some thing interesting about game, make everyone happy.

Recommend Org

  • Facebook photo Facebook

    We are working to build community through open source technology. NB: members must have two-factor auth.

  • Microsoft photo Microsoft

    Open source projects and samples from Microsoft.

  • Google photo Google

    Google ❤️ Open Source for everyone.

  • D3 photo D3

    Data-Driven Documents codes.