- Implementing composite keys with JPA and Hibernate – Occasionally, you come across a situation where a composite key is required, and you need a strategy for this. This tip shows you how to implement composite keys with JPA and Hibernate.
- A Simple Java class for Amazon SimpleSQS – With such a beautiful service such as the Amazon Simple Queue Service, it shouldn't be wrapped up with a lot of complicated layers of classes for utilizing. That is why I developed the simple POJO, single class method for utilising Amazon SQS from within Java
- Welcome to Solr – Solr is an open source enterprise search server based on the Lucene Java search library, with XML/HTTP and JSON APIs, hit highlighting, faceted search, caching, replication, a web administration interface and many more features
- Scrummerfall « Tales from a Trading Desk – Scrummerfall. n. The practice of combining Scrum and Waterfall so as to ensure failure at a much faster rate than you had with Waterfall alone
- Generate PDFs with XStream and XSL-FO – In this article, you saw how easily you can create a PDF document from Java business objects using XStream and XSL-FO. The separation of concerns allows you to isolate the view from the business objects, thus you can change the view (PDF document) without having to modify the Java code
- log4jdbc – JDBC proxy driver for logging SQL and other interesting information – log4jdbc is a Java JDBC driver that can log SQL and/or JDBC calls (and optionally SQL timing information) for other JDBC drivers using the Simple Logging Facade For Java (SLF4J) logging system.
- beet – Beet records user behavior and performance data for your Spring-based Java application. It can thus help you to analyze usage patterns and research production performance issues.
- Prototype JavaScript framework: Prototype 1.6.1 released – We’re pleased to announce the release of Prototype 1.6.1 today. This version features improved performance, an element metadata storage system, new mouse events, and compatibility with the latest browsers. It’s also the first release of Prototype built with Sprockets, our JavaScript packaging tool, and PDoc, our inline documentation tool.
- InfoQ: Hypertable – An Open Source, High Performance, Scalable Database – This presentation discusses Hypertable, an open source, high performance, distributed database modeled after Google's Bigtable. Doug discusses the differences between Hypertable and traditional database technology, support for massive sparse tables, scaling to petabytes size, and how Hypertable is designed to run on top of an existing distributed file system, such as the Hadoop DFS.
- Clojure vs Scala, Part 2 | Code Monkeyism – There are two languages stirring up the Java World: Clojure and Scala. Clojure a Lisp dialect on the JVM, powerful and pure and the Scala language a tight integration of object and functional programming. Which should you learn?
Tag Archives: XStream
Daily del.icio.us for May 7th through May 9th
- Botnet master hits the kill switch, takes down 100,000 PCs – Ars Technica – Botnets aren't just dangerous because they can steal massive amounts of personal data and launch denial-of-service attacks—they can also self-destruct, leaving the owners of affected machines in the dust.
- SpringSource Team Blog » Jump into Roo for extreme Java productivity – Roo's mission is to fundamentally and sustainably improve Java developer productivity without compromising engineering integrity or flexibility.
- InfoQ: The Emergence of Virtual Service Oriented Grids – In much the same way the Internet changed business forever, virtual service oriented grid computing has the potential to force change once again
- Outside the Box() » Slick Speed – So in the interest of getting to the bottom of the story, I did a little unscientific testing of my own using Slickspeed, which tests selector engine performance.
- Apache Camel: tutorial-osgi-camel-part2 – Designing a Service Oriented Architecture seems very obvious for most of us but implies that different parameters are taken into account
- Fuji – The Next Generation of OpenESB | Java™ Software Development Videos and Tutorials Directory – Project Fuji forms the core component of Open ESB v3 effort and represents Sun’s next generation open source integration runtime, focused on providing a lightweight, developer-friendly, and extensible platform for composite application development.
- State of the Art – With a Private MiFi Hot Spot, Be Online Wherever You Like – NYTimes.com – When you turn on your MiFi and wait 30 seconds, it provides a personal, portable, powerful, password-protected wireless hot spot.
- A Review of 5 Java JSON Libraries – Rob@Rojotek – If you are looking for a simple lightweight Java library that reads and writes JSON, and supports Streams, JSON.simple is probably a good match. It does what it says on the box in 12 classes, and works on legacy (1.4) JREs.
- google-gson – A Java library to convert JSON to Java objects and vice-versa – Gson is a Java library that can be used to convert Java Objects into its JSON representation. It can also be used to convert a JSON string to an equivalent Java object. Gson can work with arbitrary Java objects including pre-existing objects that you do not have source-code of.
- Jailer – Database Subsetting and Sampling Tool – Jailer is a tool for database subsetting and sampling, schema browsing, and rendering. It exports consistent, referentially intact row-sets from relational databases. It removes obsolete data without violating integrity. It is DBMS agnostic (by using JDBC), platform independent, and generates DbUnit datasets, hierarchically structured XML, and topologically sorted SQL-DML.
Daily del.icio.us for March 24th through March 27th
- JPivot – Home – JPivot is a JSP custom tag library that renders an OLAP table and let users perform typical OLAP navigations like slice and dice, drill down and roll up. It uses Mondrian as its OLAP Server. JPivot also supports XMLA datasource access.
- olap4j: Open Java API for OLAP – olap4j is designed to be a common API for any OLAP server, so you can write an application on one OLAP server and easily switch it to another. And built on that API, there will be a growing collection of tools and components
- Mistaeks I Hav Made: Mapping Inheritance Cleanly with XStream – This works with multiple subclasses and with SingleValueConverters. As long as you can determine the concrete type to be unmarshalled from the contents of the marshalled element, you can use this technique to elide the class attribute and get cleaner XML.
- Amazon Web Services: No Open Cloud Manifesto for us | Between the Lines | ZDNet.com – Amazon will join Microsoft as two big cloud computing players not signing on to the Open Cloud Manifesto.
The manifesto, which has raised a ruckus following a Microsoft blog post, is set to be released Monday with IBM as the ringleader. Given the hubbub it was only natural to wonder where Amazon Web Services, one of the premier cloud computing players stood
- MapReduce programming with Apache Hadoop – JavaWorld – Google and its MapReduce framework may rule the roost when it comes to massive-scale data processing, but there's still plenty of that goodness to go around. This article gets you started with Hadoop, the open source MapReduce implementation for processing large data sets
- RSS to PDF Newspaper – This is a free software project to let people create printable PDFs from content found on the web. It is a free alternative to HP's Tabbloid service. It is being developed as part of the Five Filters project to promote alternative, non-corporate media.
- Oracle: If RHEL were free, we wouldn’t compete | The Open Road – CNET News – Now we find out that it's not a question of support at all, but rather that Oracle simply wants Linux to be free. Why? Because that makes its overpriced software seem cheaper.
At least Oracle is being honest now. Coekaerts' argument is cheeky, but it makes strategic sense for Oracle. It just makes no financial sense for Red Hat.
- Ubuntu promises DIY Amazon cloud • The Register – The Jaunty Jackalope edition of Ubuntu, version 9.04, due in April, will let you take existing Amazon Machine Images (AMIs) from Amazon's Elastic Compute Cloud (EC2) and run them on your own Ubuntu servers.
- Book Review: Pragmatic Thinking & Learning – Andy Hunt, co-author of several titles in the Pragmatic Programmers series, has turned his pragmatic prism on our brains. His new book, Pragmatic Thinking and Learning: Refactoring Your Wetware, is a delight to read, provided you understand the vocabulary of agile development. It could be a perfect gift for your favorite geek this holiday season.
- jaxb: A JAXB Tutorial – Wolfgang Laun has created an outstanding tutorial. Wolfgang’s tutorial is possibly the most comprehensive (and most current) information on every aspect of JAXB. I highly recommend it both as a getting started guide and a reference.
Daily del.icio.us for February 10th through February 14th
- Zimbra’s new Desktop: Look ma, no browser! | The Open Road – The Business and Politics of Open Source by Matt Asay – CNET Blogs – It's very cool. You should give it a spin. This is the best e-mail "client" ever built…largely because of its successful marriage of the Web with the desktop. In the future, all applications will be like this–or should be.
- Ext Road Map – Our goals for 2008 are to continue improving the 2.x version line by adding new components and enhancing some of the existing areas of functionality in Ext as shown below. Looking ahead to 3.0, there are some big new areas that we'll be getting into. In a
- The Making of MarkMail: Announcing an Informal Partnership with Codehaus – We're happy to announce we've developed an informal partnership with Codehaus to load all their mail archives and receive automatic notification of new Codehaus lists as they get created.
- A Conversation with Matt Mullenweg (Yahoo! Developer Network blog) – A few weeks ago, Matt Mullenweg (creator of WordPress) came by Yahoo to talk to a bunch of Yahoo! bloggers about the current and future state of WordPress. After the meeting, I sat down with him for our Developer Spotlight series on YDN Theater to catch u
- Andres Almiray’s Weblog : Weblog – JSON-lib is a java library for transforming beans, maps and XML to JSON and back again to beans and DynaBeans. It is based on the work by Douglas Crockford in http://www.json.org/java.
- The State of BPM: Top-Five Trends | The Intelligent Enterprise Blog – The results show a number of interesting trends indicating that CIOs and business leaders are focused on improving their processes. Existing customers described how they expect to get their ROI from their BPM implementations, and most expect to see ROI ov
- Starbucks ditches T-Mobile for AT&T | Crave : The gadget blog – The new AT&T plan allows all customers 2 free hours per day, with a $3.99 fee for additional 2-hour chunks of time. Monthly subscriptions will cost $19.99 and will enable access to other AT&T hot-spot locations in addition to Starbucks.
- Anthony Park :: 100% Geek Content by Volume » New Vista Media Center Plugin – MyNetflix (beta) – I’ve kept this pretty quiet, but I’ve been working on a new Media Center plugin for a little while now. It is now ready for beta testing, and I’ve decided to run a public beta for this one. MyNetflix features * View your Netflix queue * Browse movie
- Humanized > Our Products > Enso Launcher – Enso Launcher is designed to give you instant access to your applications and windows. With a few easily remembered keystrokes, you can launch an application, switch to a window by name, and control the state of your windows.
- Martin Wolf : Advanced Java 5 Generics – Here's an article about a few of the more subtle aspects of Java 5 Generics. This is hardly the 1st article about this particular subject, but none of them explain it quite the way I would have wanted to see it when I was wrestling with this issue myself.
- Panopticon: The Power of Pre-Attentive Processing – Our visualization software is easy to use and is a great way to explore large datasets, identify outliers and find hidden patterns.
Daily del.icio.us for May 25, 2007
- Flex.org – Flex for Java Developers – Flex.org has a new (new to me anyways) resource – Flex for Java Developers
- Sarbanes-Oxley Audit Rules To Ease; Bad For IT Spending; Good For Corporate Earnings – On Wednesday, the SEC approved new guidance for how to implement Section 404.
- Haus News – XStream 1.2.2 released – The XStream Development Team is proud to present XStream 1.2.1. XStream is a simple library to serialize objects to XML and back again.
- Ajaxian – ProtoPacked 2.13: Protoype + Script.aculo.us == 32kb – This updated pack includes compressed versions of Prototype: 1.4, 1.5, 1.5.1 and Scriptaculous: 1.7.1_beta2. There is also a ?Protoculous? option as well (Prototype and Scriptaculous combined)
- Ajaxian – Interface Elements for jQuery – Interface Elements is to jQuery, as Script.aculo.us is to Prototype.
Daily del.icio.us for May 22, 2007 through May 25, 2007
- Flex.org – Flex for Java Developers – Flex.org has a new (new to me anyways) resource – Flex for Java Developers
- Sarbanes-Oxley Audit Rules To Ease; Bad For IT Spending; Good For Corporate Earnings – On Wednesday, the SEC approved new guidance for how to implement Section 404.
- Haus News – XStream 1.2.2 released – The XStream Development Team is proud to present XStream 1.2.1. XStream is a simple library to serialize objects to XML and back again.
- Ajaxian – ProtoPacked 2.13: Protoype + Script.aculo.us == 32kb – This updated pack includes compressed versions of Prototype: 1.4, 1.5, 1.5.1 and Scriptaculous: 1.7.1_beta2. There is also a ?Protoculous? option as well (Prototype and Scriptaculous combined)
- Ajaxian – Interface Elements for jQuery – Interface Elements is to jQuery, as Script.aculo.us is to Prototype.
- GPL author: Google must share code | InfoWorld | News | 2007-05-23 | By Robert McMillan, IDG News Service – Companies like Google that build their business on software such as Linux have a moral imperative to contribute back to the free software community, a prominent open-source advocate said Tuesday.
- reviewboard – Google Code – Review Board is a web-based tool designed to help projects and companies keep track of pending code changes and make code reviews much less painful and time-consuming
- Tabbed Navigation Using CSS – This tutorial will teach you how to create low-bandwidth tab navigation on a web page using CSS. As an extra bonus you’ll also learn how to switch tabs without loading the page more than once.
Declarative Caching Services for Spring
Declarative Caching Services for Spring by Alex Ruiz — Caching is an essential practice that improves the performance of enterprise applications. In this article, Alex Ruiz demonstrates a declarative caching framework for Spring 2.0, which supports pluggable cache implementations.
spring, spring2.0, caching, aspectj, AOP, SpringAOP, XStream
Life is beautiful with XMLBeans and XStream
XML creation, parsing and processing with Java has gotten so much easier with tools like XMLBeans, XStream and many other such tools. I personally love XMLBeans and XStream and I try to use them for all of my XML processing needs. While they both consume XML, they solve different problems. XMLBeans allows you to process XML by binding it to Java types using XML schema that has been compiled to generate Java types that represent schema types. XStream on the other hand allows you to serialize objects to XML and back again using special reflective secret sauce.
I’ve been using these tools for many years now and so you tend to forget just how useful and powerful they are and how productive they make you. Case in point – A friend of mine came to me for help. He was building an application that would allow him to resale items from Amazon on his site and he wanted to use the Amazon eCommerce Web Services to search for products programmatically and update a local database that housed his content. Having played with Amazon E-Commerce Service (ECS) before, I offered to write up a simple application that would make the Web Services call, process the results and present them back to you.
Amazon’s ECS is an API that allows you to access Amazon data and functionality through a Web site or Web-enabled application. ECS follows the standard Web services model: users of the service request data through XML over HTTP (REST) or SOAP and data is returned by the service as an XML-formatted stream of text. In addition to the WSDL, ECS also provides XML schemas for validating the XML output of REST requests. So I decide to use XMLBeans to create my type system using the XML Schema provided by Amazon. XMLBeans provides you with a utility (scomp) to compile your schema into Java XMLBeans classes and metadata. To generate the Java code, use the following command:
scomp –jar amznws.jar AWSECommerceService.xsd
This generates a jar file named amznws.jar, which will contain all of the code needed to bind an XML instance to the Java types representing your schema. In my application, I use HttpClient to make my REST request and then use the XMLBeans generated jar file to process the result. Here’s a snippet of code from my sample class:
https://gist.github.com/311527.js
As you can tell, HttpClient makes the REST call a snap and XMLBeans makes processing the results easy as well. In total, I spent 3-4 hours getting the application working and a lot of the time was spent figuring out the data set returned from Amazon and trying to come up with a meaningful example. Here is a zip file with the IDEA project that has all the stuff needed to make this work including a simple JSP and a JUnit test class.
Links of Interest: