Java324 at

Info iconThis preview shows page 1. Sign up to view the full content.

View Full Document Right Arrow Icon
This is the end of the preview. Sign up to access the rest of the document.

Unformatted text preview: ur beehive home. apache-beehive-svn-snapshot/ant/beehive-tools.xml - Add the encoding option to the call to the <apt> task in the <macrodef name="build-pageflows">. The line to add should be encoding="UTF-8". In the macrodef, the <apt> task should look like this... <apt srcdir="@{srcdir}" destdir="@{destdir}" gendir="@{tempdir}" classpathref="" sourcepathref="@{sourcepathref}" srcExtensions="*.jpf,*.jpfs,*.app,*.jsfb,*.java" encoding="UTF-8" processorOptions="web.content.root=@{webcontentdir}" debug="true"/> - Now try to build your modified sample app. The output for the struts config file will be in UTF-8 Test api.persistencemanager.OptimisticFailure hangs This test is designed to create conflicts in the database from two different JDO transactions. The changes in the cache must not be visible in the datastore or timeouts will occur. The exception here occurs when the second optimistic JDO transaction attempts to read a row that has been changed in the cache by the first optimistic JDO transaction. private void runTestOptimistic(PersistenceManager pm1, PersistenceManager pm2, PersistenceManager pm3) { if (!isOptimisticSupported()) { if (debug) logger.debug("OptimisticFailure tests not run; Optimistic not supported"); return; } Transaction tx1 = pm1.currentTransaction(); Transaction tx2 = pm2.currentTransaction(); Transaction tx3 = pm3.currentTransaction(); try { tx1.setOptimistic(true); tx2.setOptimistic(true); // create four instances to test tx1.begin(); pm1.makePersistent(p1); pm1.makePersistent(p2); pm1.makePersistent(p3); pm1.makePersistent(p4); pm1.makePersistent(p5); p1oid = pm1.getObjectId(p1); p2oid = pm1.getObjectId(p2); p3oid = pm1.getObjectId(p3); p4oid = pm1.getObjectId(p4); p5oid = pm1.getObjectId(p5); tx1.commit(); // update/delete the instances in tx1 tx1.begin(); PCPoint p1tx1 = (PCPoint)pm1.getObjectById(p1oid, true); PCPoint p2tx1 = (PCPoint)pm1.getObjectById(p2oid, true); PCPoint p3tx1 = (PCPoint)pm1.getObjectById(p3oid, true); PCPoint p4tx1 = (PCPoi...
View Full Document

Ask a homework question - tutors are online