We are having a strange intermittent problem when dealing with utf-8 characters being rendered as �. Somedays we send messages using international characters (ie ü) and users receive the correct message and other days the ü becomes �. We are using Jetty running with (JAVA_OPTIONS+=("-Dfile.encoding=UTF-8")) as an endpoint to publish messages to a queue (rabbitmq) which is consumed by another jetty instance that interfaces with amazon sns to push these message via (gcm and apns) to android and ios users. We are using running all of this on aws instances. Does anyone have a clue where in our system this intermittent issue could be happening.
Related
I am having an API locally hosted in one of the servers (LAN). What I am looking to understand if it is feasible to enable push notification from the server in case of a record entry. Every time a post request is made to the local server, Is it possible to push a notification to a certain mobile device? Please note, I am not considering push notification from web services such as google, Azure, Firebase etc.
It is feasible.
As Sushi said, you can use WebSockets or other Sockets to keep connect between Apps and Server. When client connected to your server, server will record which app is connecting.
By the way, you can custom notification's url between server and app.Use some special characters to distinguish between your various parameters, such as &/[ ]. You are free to set the header and body style of the message. Also, when your message needs to be encrypted, some encryption methods can be used.
Here is a similar discussion about Building an Android notification server can be refer .
I have a client who sends about 5000 SMS messages each month. They are currently doing this from an iPhone, by actually typing the message in to the phone. (I think the messages are quite repetitive, and are often addressed to groups).
The reason that they are not using an online message gateway is purely the cost. We can use a gateway here in Australia (such as Amazon SMS) for about 7.5 cents for transactional (and 2.5 cents for promotional, though I don't know if this is reliable enough).
When the client uses their own iPhone, the SMS is included in their plan, and costs them nothing extra.
I am building a web-based application for the client and the question is 'Can I send SMS via a handset connected to the client's desktop PC'. I think the answer is no, but would like to be surprised. The application is responsive, so what about if they triggered the messages from a browser on the phone? Still no?
If you could use an Android phone instead an iPhone, you could create a small gateway app on the Android that can send text messages without the need for the user's intervention.
It could work like this:
The Android app would have a simple REST interface, a good start could be https://github.com/NanoHttpd/nanohttpd.
An endpoint in the Android app could send messages, see Sending SMS programmatically without opening message app
The software on the computer would use the rest endpoint on the Android phone to send the message.
This wouldn't work on the iPhone because it doesn't allow an app to send a text message without the user's intervention.
I noticed strange problem in my web app.
Web app is hosted on AWS, is made in SpringBoot framework and its main responsibility is consuming messages from MQ. Messages are consumed one by one - there is no concurrency.
I am using MQQueueConnectionFactory class to prepare my connection,
I properly set parameters like:
host
port
queue manager
channel
int property
client reconnect options
and all ssl required parameters.
All seems to work well all the time until something happen and messages from MQ are not consumed. I can see messages which are waiting for being consumed, but web app does not consume it. After web app is restarted all work fine. I think it can be problem with connection which seems to be broken after some time (several days). I set reconnect option to connection factory class and for now I do not know what to do else to fix it.
Have you ever met similar problem? Do you have any clues?
I am trying to set up a basic SNS subscription but it looks like AWS never sends the confirmation, either through the console or using the SDK.
Steps I have taken so far:
I have set up a Topic using the AWS console
I have added HTTP subscriptions to both an ngrok tunnel URL and also a public web server URL using both the AWS console and the ruby SDK
I have allowed everyone to subscribe to the Topic by editing the Topic policy in the AWS console
By tailing the logs on both my localhost and public web servers I can see that no request is ever sent to the endpoint.
I'm pretty stumped here because it seems like it should definitely be working, or at least sending something (anything) to my endpoints?
The code I'm using for the ruby sdk is as follows:
sns = AWS::SNS.new(access_key_id: ENV['AWS_ACCESS_KEY_ID'], secret_access_key: ENV['AWS_SECRET_ACCESS_KEY'])
# I only have one topic
topic = sns.topics.first
topic.subscribe(URI.parse('http://<NGROK_URL>.ngrok.com/notifications/notify'))
topic.subscriptions.first
# returns: => <AWS::SNS::Subscription arn:PendingConfirmation>
This turned out to be an issue related to the region I was working in. I changed to Oregon and all confirmations are sending immediately.
There must be some permissions setting somewhere that prevents you from sending any messages at all from certain regions, but it was failing silently.
For me, it appears that it may not be the region (though I was trying us-east-1 too), but how ngrok's network is set up. I used a different site-forwarding service (finch) and was completely successful. This AWS forum topic makes be think that the problem may be intermittent, too.
We're getting an error in WebSphere's SystemOut log approximately every hour on our Worklight Server.
It seems to be trying to validate push notification configuration. We currently have working notifications, using Apple push notifications only. Errors are:
com.notnoop.apns.internal.ApnsFeedbackConnection getInactiveDevices
Failed to retreive invalid devices ava.lang.RuntimeException:
javax.net.ssl.SSLHandshakeException
Our notifications are working, but, what is this hourly process? I don't see anything in the docs regarding a batch process that's run by Worklight Server.
Our setup: Worklight Server 6.0.0.20130909-1459, WAS 8.0.0.6, JDK 1.6.
Worklight uses notnoop open source library to push notification to APNS. This is a known harmless bug in notnoop.
https://github.com/notnoop/java-apns/issues/29
I believe this check is part of the way APNS's feedback service works.
From: Provider Communication with Apple Push Notification Service
Section: General Provider Requirements
Connect regularly with the feedback service and fetch the current list
of those devices that have repeatedly reported failed-delivery
attempts. Then stop sending notifications to the devices associated
with those applications. See “The Feedback Service” for more
information.
As for what it means, it looks to me like your exception quote is cut. Is that all of it?