[JBoss Seam] - Re: how is DataModelSelection populated
by bfo81
@Gavin:
I don't know how to get the ListDataModel object. The only thing I have is a annotated java.util.List.
@balamg:
The page main.seam is called, main.seam (or main.xhtml in reality) uses the hotelSearch managed bean, which is in reality the HotelSearchingAction instance. And this one gets the (in this case) 3rd row of the hotel list injected into the selectedHotel property. After that, the hotelBooking bean gets it's injections and the selectHotel method is invoked.
Don't know if that was 100% correct and if this was what you wanted to know. But I just had the eager to write that down ;).
@Seam team:
I write my diploma thesis in informatics about new J2EE technologies and Seam is definitely one of 'em. But there's one thing I'd like to say (and please don't be offended, just take it as constructive critisism). The examples should be the best start to get familiar with Seam and they should be templates for your own apps. But in my opinion they seem to be built in a hurry, and they're far from perfect.
Take the booking example: Open two search windows. Perform a clean search in window 1, and a search for "at" in window 2. Click on "Conrad Miami" in window 1. But instead of "Conrad Miami" you will get "Ritz Carlton" in window 1. Why? Cause the search list is a session bean, and the list of window 1 has been overwritten by the list generated by window 2's search. To get rid of this bug the search lists should have been conversational, too. Ok, it might be only a demo, but you suggest to take it as a template for an own application.
And what I really miss are simple CRUD templates. I guess there's almost no app without creating, listing, editing or deleting entities. Plus there are many "Todo"-blocks in the documentation- What is the pageflow example good for without a detailed explanation? Or mistakes like the default scope "conversation" - in fact it's "event". Then there's a blog not working, an old and small FAQ, a fragmentary problems FAQ, a deadlink to a tutorial movie, and a WIKI that just doesn't fulfill a novice's needs.
I'm sure you have diagrams showing the interaction between the classes or how Seam is exactly integrated into the JSF lifecycle. You even know many common mistakes which one should avoid. Well, we don't, and so there will always be questions like the one balamg asked.
Seam is said to be easy and it surely is... but only if you really understand how it works. If not, you definitely will run into tons of exceptions. You all have many years of J2EE expertise. But you can't premise that all programmer's out there have that knowledge, too. If you want Seam to become a killer you must also make it accessible to beginners. A good technology can't succeed without broad acceptance.
I don't want to put Seam down, no. It's great and I really want to use it. But it's very frustrating to learn it the hard way and being left alone with problems and questions. Ok, there's the forum, but we'd have to open a dozen threads every day, and that's not the way it should be ;).
Seam might be 1.0 and ready for production, but the docs and examples aren't... yet.
View the original post : http://www.jboss.com/index.html?module=bb&op=viewtopic&p=3957308#3957308
Reply to the post : http://www.jboss.com/index.html?module=bb&op=posting&mode=reply&p=3957308
19 years, 9 months
[Clustering/JBoss] - Re: Changing Ports (two nodes, same machine, 4.0.4)
by burakbayramli
Yes it does seem like a packaging issue.
Rebuilding from sources: I tried as best as I could. Following directions in JBoss Dev Process Guide and after downloading 600 MB of CVS src/jar (ant synchronize), I had to mkdir the following directories manually (the build process needs some work IMHO)
| ../common/output
| ../common/output/lib
| ../j2se/output/lib
| ../j2se/output/
| ../j2se/output/lib
| ../j2ee/output
| ../j2ee/output/lib
| ../naming/output
| ../naming/output/lib
| ../container/output
| ../container/output/lib
| ../mbeans/output
| ../mbeans/output/lib
| ../mbeans/output
| ../mbeans/output
| ../mbeans/output/resources
| ../mbeans/output/resources/dtd
| ../jmx/output
| ../jmx/output/lib
| ../system/output
| ../system/output/lib
| ../system/output/bin
| ../system/output/resources
| ../system/output/resources/dtd
| ../transaction/output
| ../transaction/output/lib
| ../server/output
| ../server/output/lib
| ../server/output/resources/exception-processor
| ../server/output/resources/
| ../server/output/resources/exception-processor
| ../server/output/resources/client-deployer
| ../server/output/resources/jmx-invoker-adaptor
| ../server/output/resources/jmx-invoker-adaptor/META-INF
| ../server/output/etc
| ../server/output/etc/deploy
| ../server/output/etc/conf
| ../server/output/etc/conf/default
And finally I did "ant build" got stuck at this step;
| BUILD FAILED
| Error executing 'build.main' for Build@13e754f{id=jbossas}
| Cause: The following error occurred while executing this line:
| Error executing 'release.server.jboss-minimal.xml' for Artifact@fb6354{id=jboss-
| minimal.xml}
| Cause: Cannot perform operation from directory to file.
Ben, if you have any input into this last problem, great. If not, I can wait for a package that let's me do ejb3 and port changes, as I have spent already lots of time on this issue. This is needed for a class I am about to teach, but I can use a Linux box as the second node, so there won't be any need for port change.
Thanks,
View the original post : http://www.jboss.com/index.html?module=bb&op=viewtopic&p=3957302#3957302
Reply to the post : http://www.jboss.com/index.html?module=bb&op=posting&mode=reply&p=3957302
19 years, 9 months
[JBossCache] - Re: Transactions in JBossCache 1.4CR2
by KChvilyov
Thank you for answers and questions.
We are not using any transaction in error situation. But is it necessary for each operation with cache?
Last fix have not resolve our problem for using transactions with 1.4 version. I have gotten last head JBossCache version from CVS.
Now error trase is:
06-07-12 11:29:19,687 [main] ERROR ObjectManager ? - Exception:
java.lang.reflect.InvocationTargetException
at sun.reflect.NativeMethodAccessorImpl.invoke0(Native Method)
at sun.reflect.NativeMethodAccessorImpl.invoke(Unknown Source)
at sun.reflect.DelegatingMethodAccessorImpl.invoke(Unknown Source)
at java.lang.reflect.Method.invoke(Unknown Source)
at com.intersolved.xmlserver.deployer.ObjectManager.invokeMethod(ObjectManager.java:278)
at com.intersolved.xmlserver.deployer.ObjectManager.processInvoke(ObjectManager.java:297)
at com.intersolved.xmlserver.deployer.ObjectManager.start(ObjectManager.java:110)
at com.intersolved.xmlserver.Server.main(Server.java:32)
Caused by: java.lang.RuntimeException: PojoCache.putObject(): fqn: /<<SYSTEM-INF>>/STORAGES
at org.jboss.cache.aop.PojoCache.putObject(PojoCache.java:477)
at com.intersolved.cluster.jsync.components.Synchronizer.putObject(Synchronizer.java:221)
at com.intersolved.xmlserver.global_services.synchronizator.SynchronizationMetaData.createMetaDataStructure(SynchronizationMetaData.java:49)
at com.intersolved.xmlserver.global_services.synchronizator.SynchronizationMetaData.(SynchronizationMetaData.java:33)
at com.intersolved.xmlserver.global_services.synchronizator.SynchronizationService2.initRootSynchronizationStorage(SynchronizationService2.java:36)
at com.intersolved.xmlserver.global_services.synchronizator._SynchronizationService.start(_SynchronizationService.java:32)
... 8 more
Caused by: java.lang.IllegalStateException: PojoCache.registerTxHanlder(). Can't have null tx handle.
at org.jboss.cache.aop.PojoCache.registerTxHandler(PojoCache.java:743)
at org.jboss.cache.aop.PojoCache._putObject(PojoCache.java:729)
at org.jboss.cache.aop.PojoCache.putObject(PojoCache.java:461)
... 13 more
1.4 version have addition invoke registerTxHandler() in _putObject(Fqn fqn, Object obj).
For my mind the reason of current error situation is:
getLocalTransaction() method returns null when there is not transaction in current thread.
I think new transaction should be created for current thread in this situation.
Would you like to see the suspicions (for my mind :) code changes in version 1.4 for this situation?
View the original post : http://www.jboss.com/index.html?module=bb&op=viewtopic&p=3957300#3957300
Reply to the post : http://www.jboss.com/index.html?module=bb&op=posting&mode=reply&p=3957300
19 years, 9 months
[JBossCache] - Re: TreeCache/Hibernate/JBossAS optimistic locking problem
by floefliep
Just checked out the latest Hibernate source from http://anonhibernate.labs.jboss.com/trunk/Hibernate3, but I can't find a method testNoVersioningProvided() in there ... where should this be included?
Anyway, my guess is still remains: TreeCache doesn't work fine if you mix non-versioning and versioning calls in the same transaction. So either one could fix TreeCache such that DefaultDataVersion.ZERO is again correctly assigned to WorkSpaceNodeImpl when using a non-versioning call, either you pass in via OptimisticTreeCache a DefaultDataVersion.ZERO, as I tried.
Same way, problem nr 2 can be fixed by adding to writeUpdate() and writeLoad():
if ( source != null ) {
| ...
| } else
| option.setDataVersion(DefaultDataVersion.ZERO);
and modifying :
public boolean newerThan(DataVersion dataVersion) {
| if ( previousVersion == null ) {
| log.warn( "Unexpected optimistic lock check on inserted data" );
| return false;
| }
| ...
Replacing the null parameter in writeLoad to currentVersion may have the same effect.
But I'm still confused by the warning issued by the code above. Why shouldn't there be an optimistic lock check on inserted data? Based on what I read in the TreeCache documentation and from what I saw in the code, everything accessed by a transaction is put into it's workspace (both read/write, it seems). At commit time, everything in the workspace is being checked for newer versions against the cache (see org.jboss.cache.interceptors.OptimisticValidatorInterceptor.simpleValidate()) which, as I understand it, boils down to obtaining both optimistic read and write locks, which is neat and exactly what I want.
Being non-familiar with the JBoss code, I may be totally wrong or looking at the wrong root cause, but this is the only explanation IMHO I'm able to see.
View the original post : http://www.jboss.com/index.html?module=bb&op=viewtopic&p=3957298#3957298
Reply to the post : http://www.jboss.com/index.html?module=bb&op=posting&mode=reply&p=3957298
19 years, 9 months