Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

Broadcast check failing #144

Open
salhdev opened this issue Jan 15, 2019 · 1 comment
Open

Broadcast check failing #144

salhdev opened this issue Jan 15, 2019 · 1 comment

Comments

@salhdev
Copy link

salhdev commented Jan 15, 2019

Hello,
I have tested this package with a fresh new installation of laravel 5.7 to make sure there was no interference from any other package. I also used the "dev-master" version to see if the problem had been resolved.
The javascript gets a 404 not found when it sends the pong message, I listed all routes and could not find the callback route !
I have no idea why the callback route is not being registered :(
This is what the js script outputs :

Started Server ...
Message pragmarx-health-broadcasting-channel Received ...
ponging...
pong To Url : http://homestead.test/health/broadcasting/callback/6d3y1UH8Xv3L5Lyi7UnW6JQkRRwyB6Pv
error: null
statusCode: 404

and this is the route:list :
vagrant@homestead:~/code/laravel-5-boilerplate$ php artisan route:list | grep health

| | GET|HEAD | health/assets/css/app.css | pragmarx.health.assets.css | PragmaRX\Health\Http\Controllers\Health@assetAppCss | web |
| | GET|HEAD | health/assets/js/app.js | pragmarx.health.assets.js | PragmaRX\Health\Http\Controllers\Health@assetAppJs | web |
| | GET|HEAD | health/check | pragmarx.health.check | PragmaRX\Health\Http\Controllers\Health@check | web |
| | GET|HEAD | health/config | pragmarx.health.config | PragmaRX\Health\Http\Controllers\Health@config | web |
| | GET|HEAD | health/panel | pragmarx.health.panel | PragmaRX\Health\Http\Controllers\Health@panel | web |
| | GET|HEAD | health/resources | pragmarx.health.resources.all | PragmaRX\Health\Http\Controllers\Health@allResources | web |
| | GET|HEAD | health/resources/{slug} | pragmarx.health.resources.get | PragmaRX\Health\Http\Controllers\Health@getResource | web |
| | GET|HEAD | health/string | pragmarx.health.string | PragmaRX\Health\Http\Controllers\Health@string

Thanks for looking into it !
Salh

@OlexandrPopov
Copy link

I was able to setup the callback endpoint by adding the following route config:

[
    'uri' => "{$route_prefix}/broadcasting/callback/{secret}",
    'name' => 'pragmarx.health.broadcasting.callback',
    'action' => "PragmaRX\Health\Http\Controllers\Broadcasting@callback",
    'middleware' => [
        'web',
        'admin',
    ],
],

However, the Broadcasting test doesn't seem to be working at all.

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
None yet
Projects
None yet
Development

No branches or pull requests

2 participants