[GSoC 2016] AeroGear WebPush and UnifiedPush Server integration
by Idel Pivnitskiy
Hello community!
I'm happy to work with you during the last year! Thank you for the great
project! I use it for the pleasured Open Source development when I have
free time and I use UPS with my own projects at work.
I'm highly motivated to continue my work on WebPush protocol and move it to
UPS!
Expected results for GSoC 2016 project:
- Add WebPush support for Google Chrome, Mozilla Firefox and Safari
browsers into UPS.
- Integrate AeroGear WebPush server with UnifiedPush Server.
- Good test coverage for the new code.
- Documentation for all new developments and changes.
- Demo application for showing the work of WebPush protocol in action
with UPS!
Possible additional tasks which could be done:
- Java client for AppServer (similar as a current client for User
Agents).
- Rewrite java clients with native Java 9 HTTP/2 API.
- Port webpush-codec directly to Netty. It will simplify WebPush Server
code base and attract other developers to improve the core of the protocol.
Glad to see your feedback!
Best regards,
Idel Pivnitskiy
--
Twitter: @idelpivnitskiy <https://twitter.com/idelpivnitskiy>
GitHub: @idelpivnitskiy <https://github.com/idelpivnitskiy>
8 years, 9 months
UPS 1.2.0+ on WF10/JDK8 - should we continue supporting WF8/JDK7?
by Lukáš Fryč
Hi guys,
we are working on delivering some improvements in UPS messaging subsystem
in 1.2.0,
and part of that is also adoption of WF10 (with ActiveMQ Artemis
underneath).
The problem is that WF10 is JDK8 only, so if we use it for tests, we are
limiting ourselves to JDK8-only build. We could run it on WF8 with JDK7,
off course.
Question is, do we want to support WF8 with UPS 1.2.0+, or should we switch
to WF10 only?
Cheers,
~ Lukas
8 years, 9 months
UPS 1.2.0+ on WF10/JDK8 - should we continue supporting WF8/JDK7?
by Lukáš Fryč
Hi guys,
we are working on delivering some improvements in UPS messaging subsystem
in 1.2.0,
and part of that is also adoption of WF10 (with ActiveMQ Artemis
underneath).
The problem is that WF10 is JDK8 only, so if we use it for tests, we are
limiting ourselves to JDK8-only build. We could run it on WF8 with JDK7,
off course.
Question is, do we want to support WF8 with UPS 1.2.0+, or should we switch
to WF10 only?
Cheers,
~ Lukas
8 years, 9 months
AeroGear WebPush Java Client
by Idel Pivnitskiy
Hi all!
I've just implemented a lightweight java client for receiving push messages
from AeroGear WebPush Server [1]. It is easy to use and fully async!
A few words about decision to use Jetty as a HTTP/2 client:
Currently there are only 3 Java libraries, which implement client side of
HTTP/2 protocol [2]: Netty, Jetty and OkHttp. I tried all of them:
- First of all I tried to use OkHttp. This is a lightweight http client
for Android and other Java apps. But currently this library supports HTTP/2
protocol only via old HTTP/1.1 API. It works well for simple
request-response, but its client API does not allow to use HTTP/2 features,
like Server Push Frames. I looked at GRPC [3], because Googlers use OkHttp
for HTTP/2 transport. But they don't use public API, they use only inner
classes to handle frames and built their own logic atop this classes. It
would be too complicated for our purposes.
- Secondary, I tried to refactor our WebPush console to a client
library. But this way is complicated too. netty-codec-http2 does not
provide a client API, it is only codec, low level protocol implementation.
- Now I use jetty-http2-client. It is easy to configure and use, fast
and async. Jetty provides a user friendly API to handle HTTP/2 streams and
get PUSH_PROMISE frames.
For more information, look at my commit history.
In the future, if there will be more lightweight alternatives than Jetty
(for example, new version of OkHttp or Java 9 API), I will rewrite the
transport layer of my library.
Here is an example, how to use my library [4].
[1] https://github.com/idelpivnitskiy/aerogear-webpush-java-client
[2] https://github.com/http2/http2-spec/wiki/Implementations
[3] https://github.com/grpc/grpc-java/tree/master/okhttp
[4]
https://github.com/idelpivnitskiy/aerogear-webpush-java-client/blob/maste...
Best regards,
Idel Pivnitskiy
--
E-mail: Idel.Pivnitskiy(a)gmail.com
Twitter: @idelpivnitskiy <https://twitter.com/idelpivnitskiy>
GitHub: @idelpivnitskiy <https://github.com/idelpivnitskiy>
8 years, 9 months
GCM Topics in UPS
by Summers Pittman
So I've got a few ideas for how to implement this, but I hope some people
more experienced with the platform can give some feedback before.
Quick Background:
In UPS right now we have a concept of categories. A single UPS message can
be broadcast to a bunch of devices which are subscribed to this category.
Google now supports this for GCM on Chrome, iOS, and Android so UPS can
send a single message to GCM and GCM will broadcast that to up to a million
devices.
End Quick Background
So first, how do we switch between sending a message to each device in a
category to sending a topic message to GCM?
In TokenLoader.java#L113 we are using the clientInstallationService to
build a string of deviceTokens based on the variant and message criteria.
Is there any reason we can't create a "topicToken" which will be recognized
later by GCMPushNotificationSender? Another benefit to making this change
here is that if we have over a million subscribers to the category we can
just default to the default messaging.
There is also an open issue of whether or not we will update the clients to
filter based on what category a message was sent to. To do this we will
have to include the category information in the message when we send it to
devices going forward. In GCM a topic message includes this information.
This means that if we have over a million subscriptions in the topic we
will need to fall back to using the category information anyway.
Continuing on from the thread of falling back, it is possible for a topic
message to fail to send because there are too many subscribers. How would
UPS handle regenerating the messages as deviceToken instead of topicToken
messages?
Of course if someone has a better idea than "topicTokens" I'm all ears.
8 years, 9 months
Google Summer of Code 2016
by Devanshu Singh
Hello AeroGear Developers,
I am a student based in India with keen interest in Java and related
technologies.I also have been working on mobile platforms lately.Browsing
the GSoC ideas list on JBoss website, I find “Push Notification demo case
for Unified Push Server” particularly engaging.I have previous experience
in working with Java EE and Mobile platforms like Wildfly Swarm, Keycloak
and Android.I also have intentions to use the UPS for my own mobile
projects in the future.
Thus I would love to contribute to this project for GSoC 2016.
I have been contributing to the JBoss Community for a long time,
particularly to the JBoss Forge project.I have also previously successfully
completed a GSoC project for Forge under George Gastaldi last year.
I have been through the AeroGear cookbooks and guides.
I will be looking forward to a great collaboration with the AeroGear
community in improving and adding new features to Aerodoc.
Best Regards,
Devanshu Singh.
8 years, 9 months