[JBoss Seam] - Re: nested conversation question
by valbosoft
Thanks PdP, looks like it's got to do with it.
Jacob,
a strange thing is happening:
the Home component is already being created when I load the page before (Vivienda.xhtml), where I put the link to the next page, which is supposed to start the nested conversation. I use the following construction:
<s:link propagation="nest" ....><f:param ..../></s:link>
On this page, I have no reference whatsoever to the Home component.
The page.xml file for the NEXT page (presentacionEdit.xhtml, which starts the nested conversation) *does* contain references to the Home component.
Now, the Home component doesn't get constructed during the loading of Vivienda.xhtml when I take away the references to the Home in the presentacionEdit.page.xml file (!!)
It seems like Seam anticipates on the load to the next page, and loads the corresponding page.xml file, which initiates the Home component.
My intention was to initiate the Home component with a page parameter every time I clic on the <s:link> link...
Regards,
Bo
View the original post : http://www.jboss.com/index.html?module=bb&op=viewtopic&p=4096213#4096213
Reply to the post : http://www.jboss.com/index.html?module=bb&op=posting&mode=reply&p=4096213
18Â years, 9Â months
[JBoss Seam] - How to decode hash password?
by LockDog
Seamspace example:
package org.teamdev.librarian.user;
|
| import org.apache.commons.codec.binary.Hex;
| import org.jboss.seam.Component;
| import org.jboss.seam.annotations.Name;
|
| import java.security.MessageDigest;
|
| @Name("hash")
| public class Hash {
| String hashFunction = "MD5";
| String charset = "UTF-8";
|
| public String hash(String password) {
| try {
| MessageDigest md = MessageDigest.getInstance(hashFunction);
| md.update(password.getBytes(charset));
| byte[] raw = md.digest();
| return new String(Hex.encodeHex(raw));
| }
| catch (Exception e) {
| throw new RuntimeException(e);
| }
| }
|
| public String getCharset() {
| return charset;
| }
|
| public void setCharset(String charset) {
| this.charset = charset;
| }
|
| public String getHashFunction() {
| return hashFunction;
| }
|
| public void setHashFunction(String hashFunction) {
| this.hashFunction = hashFunction;
| }
|
| public static Hash instance() {
| return (Hash) Component.getInstance(Hash.class);
| }
| }
How to decode (unhash) password?
public String unHash(String hashedPassword) {
| try {
| MessageDigest md = MessageDigest.getInstance(hashFunction);
| md.update(hashedPassword.getBytes(charset));
| char[] raw = md.digest().toString().toCharArray();
| return new String(Hex.decodeHex(raw));
| }
| catch (Exception e) {
| throw new RuntimeException(e);
| }
| }
Don't work =(
View the original post : http://www.jboss.com/index.html?module=bb&op=viewtopic&p=4096212#4096212
Reply to the post : http://www.jboss.com/index.html?module=bb&op=posting&mode=reply&p=4096212
18Â years, 9Â months
[JBoss Seam] - IllegalArgumentException: Stack must not be null
by gaboo
I've got this because I'm modifying an object managed by hibernate in an asynchronous method.
Persisting new objects work fine though.
The error occur after the method is run.
I'm usins seam CVS.
Any ideas ?
here is the full stack :
19:07:48,163 WARN [arjLoggerI18N] [com.arjuna.ats.arjuna.coordinator.TwoPhaseCoordinator_2] TwoPhaseCoordinator.beforeCompletion - failed for com.arjuna.ats.internal.jta.resources.arjunacore.SynchronizationImple@7a3f3b
| javax.persistence.PersistenceException: javax.el.ELException: java.lang.IllegalArgumentException: Stack must not be null
| at org.hibernate.ejb.AbstractEntityManagerImpl$1.beforeCompletion(AbstractEntityManagerImpl.java:527)
| at com.arjuna.ats.internal.jta.resources.arjunacore.SynchronizationImple.beforeCompletion(SynchronizationImple.java:114)
| at com.arjuna.ats.arjuna.coordinator.TwoPhaseCoordinator.beforeCompletion(TwoPhaseCoordinator.java:247)
| at com.arjuna.ats.arjuna.coordinator.TwoPhaseCoordinator.end(TwoPhaseCoordinator.java:86)
| at com.arjuna.ats.arjuna.AtomicAction.commit(AtomicAction.java:177)
| at com.arjuna.ats.internal.jta.transaction.arjunacore.TransactionImple.commitAndDisassociate(TransactionImple.java:1382)
| at com.arjuna.ats.internal.jta.transaction.arjunacore.BaseTransaction.commit(BaseTransaction.java:135)
| at com.arjuna.ats.jbossatx.BaseTransactionManagerDelegate.commit(BaseTransactionManagerDelegate.java:87)
| at org.jboss.aspects.tx.TxPolicy.endTransaction(TxPolicy.java:175)
| at org.jboss.aspects.tx.TxPolicy.invokeInOurTx(TxPolicy.java:87)
| at org.jboss.aspects.tx.TxInterceptor$Required.invoke(TxInterceptor.java:191)
| at org.jboss.aop.joinpoint.MethodInvocation.invokeNext(MethodInvocation.java:101)
| at org.jboss.aspects.tx.TxPropagationInterceptor.invoke(TxPropagationInterceptor.java:76)
| at org.jboss.aop.joinpoint.MethodInvocation.invokeNext(MethodInvocation.java:101)
| at org.jboss.ejb3.stateless.StatelessInstanceInterceptor.invoke(StatelessInstanceInterceptor.java:62)
| at org.jboss.aop.joinpoint.MethodInvocation.invokeNext(MethodInvocation.java:101)
| at org.jboss.aspects.security.AuthenticationInterceptor.invoke(AuthenticationInterceptor.java:77)
| at org.jboss.ejb3.security.Ejb3AuthenticationInterceptor.invoke(Ejb3AuthenticationInterceptor.java:106)
| at org.jboss.aop.joinpoint.MethodInvocation.invokeNext(MethodInvocation.java:101)
| at org.jboss.ejb3.ENCPropagationInterceptor.invoke(ENCPropagationInterceptor.java:46)
| at org.jboss.aop.joinpoint.MethodInvocation.invokeNext(MethodInvocation.java:101)
| at org.jboss.ejb3.asynchronous.AsynchronousInterceptor.invoke(AsynchronousInterceptor.java:106)
| at org.jboss.aop.joinpoint.MethodInvocation.invokeNext(MethodInvocation.java:101)
| at org.jboss.ejb3.stateless.StatelessContainer.localInvoke(StatelessContainer.java:214)
| at org.jboss.ejb3.stateless.StatelessContainer.localInvoke(StatelessContainer.java:184)
| at org.jboss.ejb3.stateless.StatelessLocalProxy.invoke(StatelessLocalProxy.java:81)
| at $Proxy1350.run(Unknown Source)
| at sun.reflect.NativeMethodAccessorImpl.invoke0(Native Method)
| at sun.reflect.NativeMethodAccessorImpl.invoke(NativeMethodAccessorImpl.java:39)
| at sun.reflect.DelegatingMethodAccessorImpl.invoke(DelegatingMethodAccessorImpl.java:25)
| at java.lang.reflect.Method.invoke(Method.java:597)
| at org.jboss.seam.util.Reflections.invoke(Reflections.java:21)
| at org.jboss.seam.intercept.RootInvocationContext.proceed(RootInvocationContext.java:31)
| at org.jboss.seam.intercept.ClientSideInterceptor$1.proceed(ClientSideInterceptor.java:76)
| at org.jboss.seam.intercept.SeamInvocationContext.proceed(SeamInvocationContext.java:56)
| at org.jboss.seam.async.AsynchronousInterceptor.aroundInvoke(AsynchronousInterceptor.java:50)
| at org.jboss.seam.intercept.SeamInvocationContext.proceed(SeamInvocationContext.java:68)
| at org.jboss.seam.intercept.RootInterceptor.invoke(RootInterceptor.java:106)
| at org.jboss.seam.intercept.ClientSideInterceptor.invoke(ClientSideInterceptor.java:54)
| at org.javassist.tmp.java.lang.Object_$$_javassist_11.run(Object_$$_javassist_11.java)
| at sun.reflect.NativeMethodAccessorImpl.invoke0(Native Method)
| at sun.reflect.NativeMethodAccessorImpl.invoke(NativeMethodAccessorImpl.java:39)
| at sun.reflect.DelegatingMethodAccessorImpl.invoke(DelegatingMethodAccessorImpl.java:25)
| at java.lang.reflect.Method.invoke(Method.java:597)
| at org.jboss.seam.util.Reflections.invoke(Reflections.java:21)
| at org.jboss.seam.util.Reflections.invokeAndWrap(Reflections.java:125)
| at org.jboss.seam.async.AsynchronousInvocation.call(AsynchronousInvocation.java:52)
| at org.jboss.seam.async.Asynchronous.executeInContexts(Asynchronous.java:76)
| at org.jboss.seam.async.Asynchronous.execute(Asynchronous.java:45)
| at org.jboss.seam.async.ThreadPoolDispatcher$RunnableAsynchronous.run(ThreadPoolDispatcher.java:114)
| at java.util.concurrent.Executors$RunnableAdapter.call(Executors.java:441)
| at java.util.concurrent.FutureTask$Sync.innerRun(FutureTask.java:303)
| at java.util.concurrent.FutureTask.run(FutureTask.java:138)
| at java.util.concurrent.ScheduledThreadPoolExecutor$ScheduledFutureTask.access$301(ScheduledThreadPoolExecutor.java:98)
| at java.util.concurrent.ScheduledThreadPoolExecutor$ScheduledFutureTask.run(ScheduledThreadPoolExecutor.java:207)
| at java.util.concurrent.ThreadPoolExecutor$Worker.runTask(ThreadPoolExecutor.java:885)
| at java.util.concurrent.ThreadPoolExecutor$Worker.run(ThreadPoolExecutor.java:907)
| at java.lang.Thread.run(Thread.java:619)
| Caused by: javax.el.ELException: java.lang.IllegalArgumentException: Stack must not be null
| at org.jboss.el.util.ReflectionUtil.invokeMethod(ReflectionUtil.java:332)
| at org.jboss.el.util.ReflectionUtil.invokeMethod(ReflectionUtil.java:341)
| at org.jboss.el.parser.AstPropertySuffix.invoke(AstPropertySuffix.java:58)
| at org.jboss.el.parser.AstValue.invoke(AstValue.java:96)
| at org.jboss.el.MethodExpressionImpl.invoke(MethodExpressionImpl.java:276)
| at org.jboss.seam.core.Expressions$2.invoke(Expressions.java:174)
| at org.jboss.seam.core.Events.raiseEvent(Events.java:68)
| at org.jboss.seam.security.Identity.checkPermission(Identity.java:541)
| at org.jboss.seam.security.Identity.checkEntityPermission(Identity.java:705)
| at org.jboss.seam.security.EntitySecurityListener.preUpdate(EntitySecurityListener.java:44)
| at sun.reflect.NativeMethodAccessorImpl.invoke0(Native Method)
| at sun.reflect.NativeMethodAccessorImpl.invoke(NativeMethodAccessorImpl.java:39)
| at sun.reflect.DelegatingMethodAccessorImpl.invoke(DelegatingMethodAccessorImpl.java:25)
| at java.lang.reflect.Method.invoke(Method.java:597)
| at org.hibernate.ejb.event.ListenerCallback.invoke(ListenerCallback.java:31)
| at org.hibernate.ejb.event.EntityCallbackHandler.callback(EntityCallbackHandler.java:78)
| at org.hibernate.ejb.event.EntityCallbackHandler.preUpdate(EntityCallbackHandler.java:63)
| at org.hibernate.ejb.event.EJB3FlushEntityEventListener.invokeInterceptor(EJB3FlushEntityEventListener.java:43)
| at org.hibernate.event.def.DefaultFlushEntityEventListener.handleInterception(DefaultFlushEntityEventListener.java:308)
| at org.hibernate.event.def.DefaultFlushEntityEventListener.scheduleUpdate(DefaultFlushEntityEventListener.java:248)
| at org.hibernate.event.def.DefaultFlushEntityEventListener.onFlushEntity(DefaultFlushEntityEventListener.java:128)
| at org.hibernate.event.def.AbstractFlushingEventListener.flushEntities(AbstractFlushingEventListener.java:196)
| at org.hibernate.event.def.AbstractFlushingEventListener.flushEverythingToExecutions(AbstractFlushingEventListener.java:76)
| at org.hibernate.event.def.DefaultFlushEventListener.onFlush(DefaultFlushEventListener.java:26)
| at org.hibernate.impl.SessionImpl.flush(SessionImpl.java:1000)
| at org.hibernate.impl.SessionImpl.managedFlush(SessionImpl.java:338)
| at org.hibernate.ejb.AbstractEntityManagerImpl$1.beforeCompletion(AbstractEntityManagerImpl.java:515)
| ... 57 more
| Caused by: java.lang.IllegalArgumentException: Stack must not be null
| at org.jboss.seam.core.ConversationEntry.<init>(ConversationEntry.java:39)
| at org.jboss.seam.core.ConversationEntries.createConversationEntry(ConversationEntries.java:53)
| at org.jboss.seam.core.Manager.createConversationEntry(Manager.java:535)
| at org.jboss.seam.core.Manager.beginConversation(Manager.java:556)
| at org.jboss.seam.core.Conversation.reallyBegin(Conversation.java:223)
| at org.jboss.seam.core.Conversation.begin(Conversation.java:259)
| at org.jboss.seam.faces.Redirect.captureCurrentView(Redirect.java:109)
| at sun.reflect.NativeMethodAccessorImpl.invoke0(Native Method)
| at sun.reflect.NativeMethodAccessorImpl.invoke(NativeMethodAccessorImpl.java:39)
| at sun.reflect.DelegatingMethodAccessorImpl.invoke(DelegatingMethodAccessorImpl.java:25)
| at java.lang.reflect.Method.invoke(Method.java:597)
| at org.jboss.el.util.ReflectionUtil.invokeMethod(ReflectionUtil.java:328)
| ... 83 more
View the original post : http://www.jboss.com/index.html?module=bb&op=viewtopic&p=4096206#4096206
Reply to the post : http://www.jboss.com/index.html?module=bb&op=posting&mode=reply&p=4096206
18Â years, 9Â months