Menu

Front-end in the cloud

PushMode streams app's HTML output down to the browser while user's actions are streamed back to the cloud. All application code executes in the cloud. The only code the browser ever sees is a tiny JavaScript file provided by PushMode framework.

PushMode's unique application streaming architecture lets you run your application in the cozy cloud environment while offering fully interactive user experience for your customers.

Restrictions of JavaScript disappear. PushMode pages load and respond instantly. You can be liberal in use of libraries. You can be sure the software runs on single predictable platform. You can utilize unlimited compute power of the cloud. Monitoring and profiling is straightforward. There's no client-server API to develop and secure. Database is an API call away. This is developer's dream. Yet, despite all these comforts, user experience is stellar.

Good framework is not so much about the features you use but rather about the headaches you can forget.

No spinning wheel

PushMode rivals native performance. Building on top of the cloud, H2, websocket, and GeoDNS, PushMode offers plain HTML initial response, single round-trip interactivity, speed of Java in 100% server-side application logic, and naturally parallel database queries with in-process caching.

No refresh button

PushMode is thoroughly reactive from browser to database, built on top of the hookless framework. optionally using reredis for reactive redis access. PushMode encourages stateless functional architecture, streaming HTML like video, one frame at a time.

No submit button

No widgets either. Applications can subscribe to events on any HTML element, data bind to any user-modifiable attribute. Applications can do anything a JavaScript app could do, but PushMode additionally handles transparent client-server communication.

No client-server networking

PushMode handles all client-server communication, creating an illusion of latency-free mirror browser for 100% server-side application. Only user actions and visible output are ever transmitted, eliminating all security issues with application-specific REST APIs. All application code has direct database access.

No boilerplate

PushMode uses transparent reactivity from hookless. Code is no more complicated than equivalent PHP template or plain HTML. Java-embedded templates, built on top of fluent, exception-free, and null-safe PushMode API, can be structured with all Java language features and freely mixed with Java code.

No SEO woes

PushMode serves fully rendered plain HTML pages. Interactivity is added on top, not in place of indexable content. PushMode sites are navigable with sensible URLs. Applications have full control over HTML content while PushMode takes care of quick response and valid HTML5 output.

Creating a new framework only makes sense if the framework brings radical change.

HelloPage.java

package hellopushmode;

import pushmode.*;

import pushmode.dom.*;

// Every distinct page on the site usually gets its own class.

public class HelloPage extends PushPage {

// This is where we put our HTML "template".

@Override public DomElement document() {

// We can create new HTML elements through Html factory class.

return Html.html()

// Notice how elements are nested by calling add() on parent element.

.add(Html.head()

// Insert link to pushmode.js, which makes all the PushMode magic happen.

.setupPushMode()

.add(Html.link()

// Attributes are set through a chain of fluent setters.

.rel("stylesheet")

.type("text/css")

.href("http://localhost:8082/styles/style.css"))

.add(Html.title()

// Method text() will append inline text to the element.

.text("Hello World")))

.add(Html.body()

.add(Html.div()

.add(Html.p()

.text("Hello World!"))));

}

}

Run PushMode

Hands-on learner? Run your first PushMode app in minutes by tweaking one of the samples included in PushMode tutorial.

Take the Tutorial