pubnub

PubNub or Pusher and storing data on my own server

﹥>﹥吖頭↗ 提交于 2019-12-19 03:19:20
问题 I have a mobile application where users can talk to each others via a chat (user to user only, not chatroom). Today, everything is synchronous. We are considering switching the solution to something more "real time", maybe using PubNub or Pusher. We are wondering about the best way to do it, given that our server will need to store every sent message. What we have in mind : Each mobile app would create a channel using user Id as the channel name. This channel would be used for mobile app /

Pubnub chat application with storage

可紊 提交于 2019-12-18 07:11:50
问题 I'm looking to develop a chat application with Pubnub where I want to make sure all the chat messages that are send is been stored in the database and also want to send messages in chat. I found out that I can use the Parse with pubnub to provide storage options, But I'm not sure how to setup those two in a way where the messages and images send in the chat are been stored in the database. Anyone have done this before with pubnub and parse? Are there any other easy options available to use

pubnub isTyping status Ionic2

吃可爱长大的小学妹 提交于 2019-12-14 03:48:17
问题 I've implemented a chat using Ionic2 with pubnub, the thing is how can I implement the isTyping to show it on my html ? I know I have to create a state on my user, but I don't know how to update it. My pubnub service have differents methods, and I thought I could add a PubNubEventType that it's called TYPING but I don't know how to update it from my component (where I have the chat implemented) This is my component... Any ideas? 回答1: PubNub - using setState for isTyping You just need to

get unread messages on particular channel pubnub php sdk

Deadly 提交于 2019-12-14 02:04:09
问题 Goal:- to get unread messages on particular channel. User login to the upitch website. Once he will go to the Message page we are maintaining the message_page_visited_count = 1 when user routs from message page to any other page we are updating message_page_visited_count = 0 and updating time stamp. now for updating timestamp we are using mysql function strtotime("now") something like this. $this->Userlink->updateAll( array('pubnub_time_stamp' => strtotime("now")), array('Userlink.id' =>

Issues with Pubnub + Wink Hub and sensors

爱⌒轻易说出口 提交于 2019-12-13 14:04:31
问题 I'm trying to get my Wink Hub working with Pubnub subscriptions in my iOS app, but all I ever get is a PNUnexpectedDisconnectCategory status in the didReceiveStatus callback. Here is the code: class AppDelegate: UIResponder, UIApplicationDelegate, PNObjectEventListener { var window: UIWindow? var client: PubNub override init() { let configuration = PNConfiguration(publishKey: "", subscribeKey: "fake-key") client = PubNub.clientWithConfiguration(configuration) super.init() client.addListener

Throttle PubNub publish message

点点圈 提交于 2019-12-13 02:28:01
问题 PubNub recommends "publish no faster than 5 msgs per second to any one channel." I was wondering if PubNub itself has some settings can throttle publish msgs? For example, I publish 100 msgs per second to one channel, PubNub server can drop first 95 msgs and only publish last 5 recent msgs per second. "windowing" parameter is something similar I found from PubNub, but it seems bundling msgs and compressed them instead of dropping them. "windowing" Specifies the time interval in milliseconds

User list for pubnub-chat objective c

余生长醉 提交于 2019-12-13 02:26:46
问题 I have application where pubnub chat feature is been used. I want to perform below feature 1)register / login user in pubnub programatically for chat 2)Get list of the all the users 3)Make friend and send 1st message to the user I am aware about how to create the channel. I had created channel by below code : PNConfiguration *configuration = [PNConfiguration configurationWithPublishKey:@"pub-c-XXXXXXXXXXXX-a2bf-XXXX-XXXX-XXXXXXXXXXXX"subscribeKey:@"sub-c-XXXXXXXXXXXX-02d0-XXXX-XXXX

Cant publish via PUBNUB. Origin is not allowed by Access-Control-Allow-Origin

无人久伴 提交于 2019-12-13 01:26:08
问题 Make it Using javascript API. On their site works fine, but locally cant send cross-domain request. Where is the problem? request is XMLHttpRequest cannot load http://pubsub.pubnub.com/publish/KEY//0/broadcast/0/%224444444444444%22. Origin localhost:3000 is not allowed by Access-Control-Allow-Origin. 回答1: Using PubNub Everywhere! Even localhost and file:/// Using PubNub on localhost is super easy! You can even use PubNub on file:/// as well. NOTE: always use a fixed versioned CDN in

Large number of threads under unicorn

前提是你 提交于 2019-12-13 01:01:01
问题 I am in the process of debugging some Posgtres connection leaks in our application. Few days back we suddenly crossed 100 connections when we should not be - coz we just have 8 unicorn workers and a sidekiq process (25 threads). I was looking at htop today and saw that a ton of threads were being spawned from my unicorn workers. Eg: Am I reading this correctly? This should not be happening right? If these are threads being spawned, any idea how to debug this? Thanks! Btw, my other problem -

Pubnub: Background Processes for an Auction App Development

我只是一个虾纸丫 提交于 2019-12-12 23:05:26
问题 Hello I am developing an auction app like tophatter.com. I want to implement an application that has background process in it. I want this process to run forever until I stop it http://eoction.com thatss our current site. The problem on our site when we refresh the page the auction also restart. We need something like a continuous process like tophatter.com if you refresh the page it will load the updated auction process. I found this great service called pubnub. I am thinking we need a