[JBoss Seam] - Re: Friendly URLs (e.g. /request/parameter1/parameter2)
by tluzat
Thanks!
Looking through the forums and the blog example I got some ideas:
-For requests pages.xml can be used for view-ids such as article/* and gallery/*. The actions called can then use a FacesContext to get the parameters encoded in the URL through facesContext.getExternalContext().getPathInfo().
-For generated links (s:link, h:outputLink, ...?) I'll have to supply alternatives (extended versions) which support alternative ways of formatting the result, probably through a formatter class.
I haven't tested any of these and actually not written any code using Facelets and Seam yet, but does this sound reasonable? :-) I'll run some tests tomorrow. If it works it might be worthwhile to add extended tags (s:link, ...) which support different URL formatters and actions which parse different types of URLs to the Seam distribution. Please comment!
View the original post : http://www.jboss.com/index.html?module=bb&op=viewtopic&p=3967603#3967603
Reply to the post : http://www.jboss.com/index.html?module=bb&op=posting&mode=reply&p=3967603
19 years, 8 months
[Persistence, JBoss/CMP, Hibernate, Database] - Failure to get next in sequence - EBJ3 CMP entity bean
by fbadt
Could you please look at the below errors and suggest what is going on and how to fix it?
javax.ejb.EJBException: javax.persistence.PersistenceException: org.hibernate.exception.GenericJDBCException: could not get next sequence value
at org.jboss.ejb3.tx.Ejb3TxPolicy.handleExceptionInOurTx(Ejb3TxPolicy.java:69)
The EJB is annotated as:
==== class
@Entity
@Table(name="equifax_request")
@TransactionManagement(TransactionManagementType.CONTAINER)
==== pk id annotation
@Id
@GeneratedValue(strategy = GenerationType.SEQUENCE, generator="WW")
@SequenceGenerator(name="WW", sequenceName="my_seq")
@Column(name="eqrq_no", nullable=false, insertable=true )
This is an informix 9.4 DB with the IBM informix drivers and Hibernate Persistence in JBoss 4.04 I have verified that the sequence exists. I have also successfully used iSQL (java sourceforge sql tool) to run the logged hibernate query of:
select my_seq.nextval from systables where tabid=1
View the original post : http://www.jboss.com/index.html?module=bb&op=viewtopic&p=3967602#3967602
Reply to the post : http://www.jboss.com/index.html?module=bb&op=posting&mode=reply&p=3967602
19 years, 8 months
[JBoss Seam] - Re: Invitation to try new Seam authentication features
by SmokingAPipe
I would like to try this, but it seems complicated to set up and I didn't want to run CVS code in production, so I'll wait. I ended up using a plain old Servlet Filter, like I have always done. I would prefer to use more Seam-oriented methods, including being able to restrict which user classes can access which methods in other objects, but for now, a filter is it.
I also took a long look at JAAS but it seemed like a bad idea. It looked like a lot of work just to get a login page working, it doesn't work with my entities, and it doesn't install my entities into the Session, which is where they need to be.
It is unfortunate that Java has such an advanced security system, but I can't use it to do stupid-simple Web application authentication: "Check the password. If the password is correct put the user object into the session and redirect to a welcome page." That should NOT be something that requires five XML files and a complicated configuration.
View the original post : http://www.jboss.com/index.html?module=bb&op=viewtopic&p=3967601#3967601
Reply to the post : http://www.jboss.com/index.html?module=bb&op=posting&mode=reply&p=3967601
19 years, 8 months
[EJB 3.0] - Failure to get next in sequence - EBJ3 CMP entity bean
by fbadt
Could you please look at the below errors and suggest what is going on and how to fix it?
javax.ejb.EJBException: javax.persistence.PersistenceException: org.hibernate.exception.GenericJDBCException: could not get next sequence value
at org.jboss.ejb3.tx.Ejb3TxPolicy.handleExceptionInOurTx(Ejb3TxPolicy.java:69)
The EJB is annotated as:
==== class
@Entity
@Table(name="equifax_request")
@TransactionManagement(TransactionManagementType.CONTAINER)
==== pk id annotation
@Id
@GeneratedValue(strategy = GenerationType.SEQUENCE, generator="WW")
@SequenceGenerator(name="WW", sequenceName="my_seq")
@Column(name="eqrq_no", nullable=false, insertable=true )
This is an informix 9.4 DB with the IBM informix drivers and Hibernate Persistence in JBoss 4.04 I have verified that the sequence exists. I have also successfully used iSQL (java sourceforge sql tool) to run the logged hibernate query of:
select my_seq.nextval from systables where tabid=1
View the original post : http://www.jboss.com/index.html?module=bb&op=viewtopic&p=3967600#3967600
Reply to the post : http://www.jboss.com/index.html?module=bb&op=posting&mode=reply&p=3967600
19 years, 8 months