Archives for categorie "LiveCycle"

LiveCycle control managed object [Managed] to basic operations CRUD with tag autoCommit.

It can control the same process using Assembler methods with flex DataService (createItem, deleteItem, commit).
Updating process use commit without any responder:

public function updateItem(item:myManagedClass):void {
   service.commit();
   //var call:AsyncToken = service.commit(); // Don't use it
   //call.addResponder(responder); // Don't use it
}
  • Share/Bookmark
LCDS-Spring-Helloworld Project
Configuration example of a J2EE web application with LiveCycle, issues:

  • Start the database hsqldb with the init scripts startdb.bat (Windows) o startdb.sh (Unix) adapted to our enviroment pointed to hsqldb.jar (you can configure another database connection modifying jdbc.properties file)
  • Load the database with SQL scripts in db directory using build.xml Ant file (on project top directory).
  • Adjust hidden files .actionScriptProperties, .flexProperties of flex enviroment to our local configuration.
  • Adapt local web servers paths of the project in build.properties.
  • Configurate deploy properties of the project (url, port…)

LCDS-Spring-HelloWorld

  • Share/Bookmark

Configuration example of a J2EE web application with LiveCycle, issues:

  • Start the database hsqldb with the init scripts startdb.bat (Windows) o startdb.sh (Unix) adapted to our enviroment pointed to hsqldb.jar (you can configure another database connection modifying jdbc.properties file)
  • Load the database with SQL scripts in db directory using build.xml Ant file (on project top directory).
  • Adjust hidden files .actionScriptProperties, .flexProperties of flex enviroment to our local configuration.
  • Adapt local web servers paths of the project in build.properties.
  • Configurate deploy properties of the project (url, port…)

  • Share/Bookmark

Collections handled by liveCycle are not synchronized with Command Result, so the data can be not available in the operation Result. It must be added collection handler (change, update) to ensure that data will be completely updated.

We may include a listener in the Model:

myCollection.addEventListener(
   CollectionEvent.COLLECTION_CHANGE, collectionHandler
);

We can control the update using a Setter in the property:

private var _myCollection:ArrayCollection;
public function set myCollection (value:ArrayCollection):void {
   _myCollection=value;
   _myCollection.addEventListener(
      CollectionEvent.COLLECTION_CHANGE, collectionHandler
   );
}
  • Share/Bookmark

[RPC Fault faultString="Unable to access UserTransaction in DataService." faultCode="Server.Processing" faultDetail="null"]
at mx.data::ConcreteDataService/http://www.adobe.com/2006/flex/mx/internal::dispatchFaultEvent()[C:\depot\DataServices\branches\lcds26_hotfixes\frameworks\projects\data\src\mx\data\ConcreteDataService.as:2556]
at mx.data::CommitResponder/fault()[C:\depot\DataServices\branches\lcds26_hotfixes\frameworks\projects\data\src\mx\data\CommitResponder.as:176]
at mx.rpc::AsyncRequest/fault()[E:\dev\3.1.0\frameworks\projects\rpc\src\mx\rpc\AsyncRequest.as:103]
at NetConnectionMessageResponder/statusHandler()[E:\dev\3.1.0\frameworks\projects\rpc\src\mx\messaging\channels\NetConnectionChannel.as:545]
at mx.messaging::MessageResponder/status()[E:\dev\3.1.0\frameworks\projects\rpc\src\mx\messaging\MessageResponder.as:222]

SOLUTION: Install JTOM in Tomcat, include jtom libraries and add in the file “context.xml” of the server this code:

<Transaction factory="org.objectweb.jotm.UserTransactionFactory" jotm.timeout="60"/>
  • Share/Bookmark
Creative Commons License
This blog is under Creative Commons licence, unless indicated otherwise.
Special thanks to Mark James for the icon set used in this blog.