Closed JakeDEvans closed 8 years ago
They are design to work out of the box, all that we tested do. Can you see any error on the logs?
I'm not sure if it's related, but there are a lot of lines with this in the log:
I20160331-16:15:48.996(-4) Exception from sub filteredUsers id NmzMFFXMPfSNXy4pq SyntaxError: Invalid regular expression: /all)/: Unmatched ')' at new RegExp (<anonymous>) at [object Object].<anonymous> (server/publications/filteredUsers.coffee:8:12) at [object Object].<anonymous> (server/lib/debug.js:44:15) at packages/matb33_collection-hooks/collection-hooks.js:275:1 at [object Object]._.extend.withValue (packages/meteor/dynamics_nodejs.js:56:1) at [object Object]._handler (packages/matb33_collection-hooks/collection-hooks.js:274:1) at maybeAuditArgumentChecks (livedata_server.js:1698:12) at [object Object]._.extend._runHandler (livedata_server.js:1023:17) at [object Object]._.extend._startSubscription (livedata_server.js:842:9) at [object Object]._.extend.protocol_handlers.sub (livedata_server.js:614:12)
I20160331-16:15:49.039(-4) Exception from sub filteredUsers id tfSjn2DNZuYQxkd2X SyntaxError: Invalid regular expression: /all)/: Unmatched ')' at new RegExp (<anonymous>) at [object Object].<anonymous> (server/publications/filteredUsers.coffee:8:12) at [object Object].<anonymous> (server/lib/debug.js:44:15) at packages/matb33_collection-hooks/collection-hooks.js:275:1 at [object Object]._.extend.withValue (packages/meteor/dynamics_nodejs.js:56:1) at [object Object]._handler (packages/matb33_collection-hooks/collection-hooks.js:274:1) at maybeAuditArgumentChecks (livedata_server.js:1698:12) at [object Object]._.extend._runHandler (livedata_server.js:1023:17) at [object Object]._.extend._startSubscription (livedata_server.js:842:9) at [object Object]._.extend.protocol_handlers.sub (livedata_server.js:614:12)
Can you change the log level to DEBUG on the admin panel? And can you check if the happen when the web hook is called? What integration are you trying to use so I can test here?
We used ansible to deploy, do you know where those logs are written to file?
Here you go:
I20160331-18:03:17.697(-4) rocketchat_integrations api.coffee:116 Integrations ➔ Incoming WebHook.debug @bodyParams { '{"link_names":"0","icon_emoji":":space_invader:","channel":"#webops-alerts","text":"*New message in Graylog stream <https://graylog.example.com/streams/streamid/messages?q': '*', rangetype: 'relative', relative: '3600|RocketChat Alerts>*:\<br>> this is a test ","parse":"none","username":"Graylog"}' }
The
*New message in Graylog stream <https://graylog.example.com/streams/streamid/messages?q': '*', rangetype: 'relative', relative: '3600|RocketChat Alerts>*:\<br>> this is a test
looks odd. Did you create this content?
yes and no, I generated the log entry but the plugin created the notification,
Plugins settings:
icon_url: <empty>
graylog2_url: https://graylog.example.com
notify_channel: false
link_names: false
add_attachment: false
webhook_url: https://rocketchat.example.com/hooks/LONGHASHSTRING
color: #00008B
short_mode: false
icon_emoji: :space_invader:
user_name: Graylog
channel: #webops-alerts
Any ideas?
It looks like the payload is invalid. Does your config works with Slack? Can you hardcode a safe message like "TEST" just to check if the problem is indeed the parsing of the text property of the payload?
@JakeDEvans did you manage to make it work or test with a simpler text? Please reopen if the problem persists.
@engelgabriel I think the parsing of the message payload is broken. The message itself is using valid Slack syntax (and is working with Slack and Mattermost): https://api.slack.com/docs/message-formatting#linking_to_urls
@joschi we noticed it's working without any changes to the graylog plugin.
Is there a script to take webhooks written for slack (like the one for graylog) and allow them to be used with rocketchat?
out of box doesn't send the message contents. (body missing, but title and icon show up correctly)
Your Rocket.Chat version: 0.24.0