background preloader

Development

Facebook Twitter

Js

Timeline JS - Beautifully crafted timelines that are easy, and intuitive to use. Architecture. Spring. Android. Client Side Frameworks. Collaborative writing. Json-path - Java JsonPath implementation. REST Pagination in Spring. We Recommend These Resources This is the seventh of a series of articles about setting up a secure RESTful Web Service using Spring 3.1 and Spring Security 3.1 with Java based configuration.

REST Pagination in Spring

This article will focus on the implementation of pagination in a RESTful web service. The REST with Spring series: Page as resource vs Page as representation The first question when designing pagination in the context of a RESTful architecture is whether to consider the page an actual resource or just a representation of resources. The next question in the pagination design in the context of REST is where to include the paging information: in the URI path: /foo/page/1the URI query: /foo?

Keeping in mind that a page is not a resource, encoding the page information in the URI is no longer an option. Page information in the URI query Encoding paging information in the URI query is the standard way to solve this issue in a RESTful service. /foo? The Controller 01. 02. 03.public List< Foo > findPaginated( Logo Store & Logo Design Templates. Hibernate Annotations.

First, set up your classpath (after you have created a new project in your favorite IDE): Alternatively, import your pom.xml in your favorite IDE and let the dependencies be resolved automatically, We recommend you use Hibernate Validator and the Bean Validation specification capabilities as its integration with Java Persistence 2 has been standardized.

Hibernate Annotations

Download Hibernate Validator 4 or above from the Hibernate website and add hibernate-validator.jar and validation-api.jar in your classpath. Alternatively add the following dependency in your pom.xml. <project> ... If you wish to use Hibernate Search, download it from the Hibernate website and add hibernate-search.jar and its dependencies in your classpath. <project> ... We recommend you use the JPA 2 APIs to bootstrap Hibernate (see the Hibernate EntityManager documentation for more information). Developing Backbone.js Applications - By Addy Osmani (@addyosmani) Available free for open-source reading below or for purchase via the O'Reilly store.

Developing Backbone.js Applications -

Pull requests and comments always welcome. Prelude Not so long ago, “data-rich web application” was an oxymoron. Today, these applications are everywhere and you need to know how to build them. Traditionally, web applications left the heavy-lifting of data to servers that pushed HTML to the browser in complete page loads. Think of the Ajax shopping cart which doesn’t require a refresh on the page when adding an item to your basket. The rise of arbitrary code on the client-side which can talk to the server however it sees fit has meant an increase in client-side complexity.

Thankfully, there are a growing number of JavaScript libraries that can help improve the structure and maintainability of your code, making it easier to build ambitious interfaces without a great deal of effort. Target Audience Acknowledgements Credits Target Version Reading What Is MVC? What is Backbone.js? <! Views. Wufoo · Online Form Builder! Spring security 3 Ajax login – accessing protected resources. I have seen some blogs about Spring Security 3 Ajax login, however I could not find any that tackles how to invoke Ajax based login, where a protected resource is being accessed in Ajax by an anonymous user.

Spring security 3 Ajax login – accessing protected resources

The problem – The web application enables anonymous access to certain parts and certain parts are protected resources which require the user to login. When an anonymous user accesses protected resources (via Http Get / Post), Spring Security automatically invokes the login page and after a successful authentication, redirects to the required resource/page. However, if the protected resource is being accessed in Ajax, the login page will not appear correctly (will be set on part of the page). The 302 code (redirect to login page) will not function as expected in Ajax. Please note that this is NOT the same as initiating an Ajax login screen (e.g. when user press on the login button and a popup with user/password fields is being invoked).

Regarding part 2 – Requires the following: Kendo UI - jQuery HTML5 framework for desktop, mobile app development, HTML5 data visualization.