gdpelican / babble

Discourse Shoutbox plugin
MIT License
107 stars 63 forks source link

Bug: Messages are only retrived on page load, not realtime #286

Closed Szeraax closed 4 years ago

Szeraax commented 5 years ago

discourse/logs shows this error: Job exception: uninitialized constant Jobs::BabblePostAlert

Happens on a brand new installation or my existing one.

I have a little different setup, so there could be a few possible causes outside of what you might normally expect.

  1. Using bitnami docker images, not the discourse default install.
  2. Using nginx reverse proxy for hosting multiple servers. Websocket support is enabled I've now tested without nginx and no https. Issue persists (clean install of discourse, of course).

How I installed the plugin with the 4 bitnami containers running (after getting onto the discourse terminal):

PATH="/opt/bitnami/ruby/bin:/opt/bitnami/postgresql/bin:/opt/bitnami/git/bin:/opt/bitnami/brotli/bin:$PATH"
cd /opt/bitnami/discourse
RAILS_ENV=production bundle exec  rake plugin:install repo=https://www.github.com/gdpelican/babble
RAILS_ENV=production bundle exec rake assets:precompile
#Reboot all containers to be safe
Name Value
hostname 2448b12cf29a
process_id 36
application_version 046b6300d14fc915fa81c1706e6146844badeaa4
context Job raised exception
jobstr {"class":"Jobs::BabblePostAlert","args":[{"post_id":15,"current_site_id":"default"}],"retry":true,"queue":"default","jid":"4640e95475e2c80b67231376","created_at":1569306207.736253,"enqueued_at":1569306207.7363365}
current_hostname
  jobclassJobs::BabblePostAlert args[[object Object]] retrytrue queuedefault jid4640e95475e2c80b67231376 created_at1569306207.736253 enqueued_at1569306207.7363365 job classJobs::BabblePostAlert args[[object Object]] retrytrue queuedefault jid4640e95475e2c80b67231376 created_at1569306207.736253 enqueued_at1569306207.7363365 class Jobs::BabblePostAlert args [[object Object]] retry true queue default jid 4640e95475e2c80b67231376 created_at 1569306207.736253 enqueued_at 1569306207.7363365
job classJobs::BabblePostAlert args[[object Object]] retrytrue queuedefault jid4640e95475e2c80b67231376 created_at1569306207.736253 enqueued_at1569306207.7363365 class Jobs::BabblePostAlert args [[object Object]] retry true queue default jid 4640e95475e2c80b67231376 created_at 1569306207.736253 enqueued_at 1569306207.7363365
class Jobs::BabblePostAlert
args [[object Object]]
retry true
queue default
jid 4640e95475e2c80b67231376
created_at 1569306207.736253
enqueued_at 1569306207.7363365

Happy to answer followup questions.

Szeraax commented 5 years ago

Ok, I've also tested on a plain HTTP instance of the bitnami discourse using the above method (also removed the nginx) and I still have this message in the logs and posts don't show as being posted until you refresh the whole page. :(

maydo commented 4 years ago

same here, i have standard discourse installation

you need always reload page

Szeraax commented 4 years ago

Never got this working with bitnami. Instead settled with using the stock discourse installation in a VM. Though it used double nested VM, it runs fine.