Message Expiry for pulsar messages - apache-pulsar

How to get the expiry date for particular message in pulsar by using Pulsar admin API ( or ) is there any way to findout whether particular message is expired or not ?

https://pulsar.apache.org/docs/en/cookbooks-retention-expiry/
https://pulsar.apache.org/docs/en/admin-api-overview/
That can help, otherwise join the slack. There is very fast response to most questions.
Slack
There is a Pulsar slack channel that is used for informal discussions for devs and users.
The Slack instance is at https://apache-pulsar.slack.com/
You can self-register at https://apache-pulsar.herokuapp.com/

Related

Push Notifications for multiple users in multiple events

I am building an app in which users can register themselves in events.
I'd like to send push notifications to the users registered in a particular event when, for example, the organizer makes a modification to the event.
Stack :
Server : NodeJS, Graphql (Apollo), Firebase for authentication.
Client : React-Native, Graphql (Apollo), Firebase for authentication.
For now I send in-app alerts using subscriptions, but I'd like to use push notifications so the users have the notification event if the app isn't launched.
I have read the docs of Firebase Cloud Messaging, and it uses topics to send notifications to users.
I could create a topic for each particular event, and have each user subscribe to each "event-topic" that corresponds to each event they are in, but this sounds like a misuse of FCM topics. To my understanding topics are made for a more general behavior, in the docs they only use topics like "weather", "highscores" ...
I'm not sure which approach I should use. Is the "one topic per event" wrong ? What are your thoughts about it ?
Topics actually sound like a great mapping for your use-case, as you could subscribe the users to the FCM topic (similar to how you already subscribe to to database ) to receive updates about the event.
The only thing to be aware of is that topics are public: any user can subscribe to any topic they know off. So in your case if you use the event ID as the topic, then anyone can subscribe to any event they know (or can guess) the ID of.
If that is a concern, you should not use topics and instead manage your own tokens and fan out from event ID to the FCM tokens of the folks who receive updates.

Slack Incoming Web Hooks - Send message ONLY once

I push a lot (10Ks) of messages to Slack channel webhooks each month. It's not uncommon for the Slack API to return network errors, like ECONNRESET, meaning I don't know if the message was sent or not.
You can resend (POST) to the Slack chat.postMessage endpoint, but that might deliver the message twice.
Is there a way to idempotently send a Slack message once to a channel using Slack webhooks?
Slack Webhooks provide a very limited set of functionality.
Idempotency is not one of them.
https://api.slack.com/messaging/webhooks

Mentions in slack ephemeral message do not trigger mobile notifications

I am working on a slack bot.
This bot posts ephemerals messages to let the users know it's time to do some actions.
The ephemeral message contains a mention of the user (<#user_id>) so that the user should be notified.
The notification is triggered on computer but not on mobile.
Is this a bug ?
No its not. Ephemeral message delivery is not guaranteed — the user must be currently active in Slack and a member of the specified channel. By nature, ephemeral messages do not persist across reloads, desktop and mobile apps, or sessions.You can find more info here

How to create an azure chat bot which can send chat messages without any user input

I have tried developing azure bots before. Currently I am trying to find out whether there is any way we could set up a bot that can constantly monitor something and send messages to particular users without user initiating a chat.
For instance, a bot monitors a system and find something wrong and sends a chat message to the user ( Bot initiates the chat in this case ). I did some research but couldn't find any way to achieve this yet.
Thanks in advance,
DM
This concept is called Proactive Messaging in the Bot Framework. There are some example in C# here: https://github.com/Microsoft/BotBuilder-Samples/tree/master/CSharp/core-proactiveMessages and node.js here: https://github.com/Microsoft/BotBuilder-Samples/tree/master/Node/core-proactiveMessages
Something to note is that different channels have different restrictions on when a proactive message can be sent to a user. For instance, on Facebook you have a 24 hour window from the time the user messaged the bot. After 24 hours, if the user has not messaged the bot, then proactive messages will not be allowed through.
More information can be found in this doc: https://learn.microsoft.com/en-us/bot-framework/dotnet/bot-builder-dotnet-proactive-messages
Edit:
You can also create a Functions Bot in Azure using the Proactive template and it will create a bot that has BasicProactiveEchoDialog.csx that demonstrates how to en-queue a CloudQueueMessage into a CloudStorageAccount. The template will also create an Azure Function that is triggered by additions to the queue. When the function is triggered, it will send the queued message to the user on the channel.

How to receive bot's messages in telegram?

I wrote some bot that sends messages to some channel using nodejs. This bot is an admin in that channel and it can see messages from users using /getupdates api. However it can't see own messages. Is there any way to do that?

Resources