Java Mailing List Archive

http://www.gg3721.com/

Home » Struts Users Mailing List »

user Digest 9 Jun 2008 14:52:30 -0000 Issue 8077

user-digest-help

2008-06-09


Author LoginPost Reply

user Digest 9 Jun 2008 14:52:30 -0000 Issue 8077

Topics (messages 187362 through 187372):

Re: How to pass dynamic value to the logic:equal tag?
 187362 by: VenkatBabu

dynamic menu: struts-menu or <s:tree>
 187363 by: Lucie

Re: After Visiting URL with Queyr String, Query String Appears on Every Link
 187364 by: Ralf Fischer

Help required on Struts-Datagrid
 187365 by: mukul.object
 187366 by: Felipe Lorenz
 187371 by: Himanshu Rathore

Re: detached object cannot be persisted exception again
 187367 by: Arun

Use "plainText" result for Ajax
 187368 by: tomate_61

Reading Application Resource saved as UTF8 file and showing polish characters in browser
 187369 by: Raghuveer

Re: Parameter question
 187370 by: Stanley, Eric

Struts 2.0.x : Dojo integration problem (Tag optiontransferselect)
 187372 by: Craftyman

Administrivia:

---------------------------------------------------------------------
To post to the list, e-mail: user@(protected)
To unsubscribe, e-mail: user-digest-unsubscribe@(protected)
For additional commands, e-mail: user-digest-help@(protected)

----------------------------------------------------------------------

Attachment: user_187362.ezm (zipped)

Thanks for your reply Jim...
But the problem is the Vector consists of Strings of codes where i am
passing the codes to the custom tag in the JSP page, which will give the
corresponding information.
So i cant go by generating the string in Java function. I need to do that in
JSP itself.

Please suggest me some other idea...

Jim Kiley wrote:
>
> I would compose the string from the vector in a Java function, and call
> that
> function to get the String, instead of just accessing the Vector. Is
> there
> a reason you couldn't do that?
>
> jk
>
> On Fri, Jun 6, 2008 at 12:54 PM, VenkatBabu <bs_ramana@(protected):
>
>>
>> I am new to this forum...forgive me if the question that i am going to
>> raise
>> is already present. I dont have time to go through all the messages which
>> have been raised already.
>>
>> The problem is:
>> I have <logic:iterate id="ID1" name="formbeanname"
>> property="VectorInBean"
>> indexid="index">
>> <logic:equal name="ID1" property="index" value="Dynamic Value from the
>> bean">
>>
>> logic:equal tag's value attribute shoud get populated by a value from the
>> bean(i am storing the size of the vector in bean) which is used in the
>> logic:iterate. I dont want to use scriptlets.
>>
>> Actually the problem is the Vector in the bean has list of strings which
>> needs to be shown in the JSP one by one sepeared by "commas(,)" and we
>> need
>> to add "and" before the last string from the vector. So i need to check
>> it
>> dynamically whether the vector is reached the last but one.
>>
>> I need to solve this issue as soon as possible. Any help would be very
>> grateful.
>> --
>> View this message in context:
>> http://www.nabble.com/How-to-pass-dynamic-value-to-the-logic%3Aequal-tag--tp17696748p17696748.html
>> Sent from the Struts - User mailing list archive at Nabble.com.
>>
>>
>> ---------------------------------------------------------------------
>> To unsubscribe, e-mail: user-unsubscribe@(protected)
>> For additional commands, e-mail: user-help@(protected)
>>
>>
>
>
> --
> Jim Kiley
> Technical Consultant | Summa
> [p] 412.258.3346 [m] 412.445.1729
> http://www.summa-tech.com
>
>

--
Sent from the Struts - User mailing list archive at Nabble.com.


Attachment: user_187363.ezm (zipped)

Hi,

I need to generate a dynamic menu (read from database) for a struts 2
application.
I used struts-menu for a struts 1.x application, and am wondering if it
makes more
sense to switch to using struts2's <s:tree> tag. Your input is greatly
appreciated.

Lucie


--
Sent from the Struts - User mailing list archive at Nabble.com.


Attachment: user_187364.ezm (zipped)
Hello,

please see the Tag Documentation of <s:url /> [1] for this, and take a
look at the attribute "includeParams". By default the url tag includes
all request parameters in the query string of the current page when
generating a new URL, thus all your parameters are transported
implicitly onto the next page. Just set includeParmas to "none" and
they won't.

Bye,
-Ralf

[1] http://struts.apache.org/2.0.11.1/docs/url.html

On Sat, Jun 7, 2008 at 10:34 AM, Pandolf <richard.rauser@(protected):
>
>
> Hi everyone,
>
> I'm using Struts 2.0.11.1 with FreeMarker 2.3.8. I've created a hyperlink in
> a .FTL as follows:
>
>     <@(protected)">
>        <@(protected)"/>
>        <@(protected)"/>
>     </@>
>
>     <@(protected)>
>
> The link is rendered without a problem. I can click it and arrive at the
> correct page. After clicking through this link, however, Struts 2 appears to
> append the query string (i.e. "?minDaysAway=0&maxDaysAway=7") to every other
> URL in my site! Including URLs that are not supposed to have it.
>
> Why is this? How do I avoid this scenario?
>
> Thanks for any help.
> --
> View this message in context: http://www.nabble.com/After-Visiting-URL-with-Queyr-String%2C-Query-String-Appears-on-Every-Link-tp17706571p17706571.html
> Sent from the Struts - User mailing list archive at Nabble.com.
>
>
> ---------------------------------------------------------------------
> To unsubscribe, e-mail: user-unsubscribe@(protected)
> For additional commands, e-mail: user-help@(protected)
>
>

Attachment: user_187365.ezm (zipped)

Hello All,
I am seeking for suggestions on how can we fix the header/column-names in
Struts-Datagrid.

In my jsp , I have implemented struts-datagrid and showing many rows at a
time.
While scrolling the page , the column-names/header of the datagrid also
scroll up and down and do not remain visible to the user.

Is there any way to fix the column-name/header to the top of datagrid?

Kindly suggest any solution.

Thanks
-Mukul
--
Sent from the Struts - User mailing list archive at Nabble.com.


Attachment: user_187366.ezm (zipped)
I dont know... maybe if you have 2 DIV, the first for header and de second
for data, where hava a scroll.. But how do it, i dont know... but i saw
it...

On Mon, Jun 9, 2008 at 7:33 AM, mukul.object <mukul.object@(protected):

>
> Hello All,
> I am seeking for suggestions on how can we fix the header/column-names in
> Struts-Datagrid.
>
> In my jsp , I have implemented struts-datagrid and showing many rows at a
> time.
> While scrolling the page , the column-names/header of the datagrid also
> scroll up and down and do not remain visible to the user.
>
> Is there any way to fix the column-name/header to the top of datagrid?
>
> Kindly suggest any solution.
>
> Thanks
> -Mukul
> --
> View this message in context:
> http://www.nabble.com/Help-required-on-Struts-Datagrid-tp17730148p17730148.html
> Sent from the Struts - User mailing list archive at Nabble.com.
>
>
> ---------------------------------------------------------------------
> To unsubscribe, e-mail: user-unsubscribe@(protected)
> For additional commands, e-mail: user-help@(protected)
>
>

Attachment: user_187371.ezm (zipped)
Hi Mukul,

This is possible in datagrid. you have to create two tables, one with
headers and other containing data. In second table you need to hide the
header part.

I'll send you sample code tomorrow EOD.

On Mon, Jun 9, 2008 at 4:03 PM, mukul.object <mukul.object@(protected):

>
> Hello All,
> I am seeking for suggestions on how can we fix the header/column-names in
> Struts-Datagrid.
>
> In my jsp , I have implemented struts-datagrid and showing many rows at a
> time.
> While scrolling the page , the column-names/header of the datagrid also
> scroll up and down and do not remain visible to the user.
>
> Is there any way to fix the column-name/header to the top of datagrid?
>
> Kindly suggest any solution.
>
> Thanks
> -Mukul
> --
> View this message in context:
> http://www.nabble.com/Help-required-on-Struts-Datagrid-tp17730148p17730148.html
> Sent from the Struts - User mailing list archive at Nabble.com.
>
>
> ---------------------------------------------------------------------
> To unsubscribe, e-mail: user-unsubscribe@(protected)
> For additional commands, e-mail: user-help@(protected)
>
>


--

Regards,
Himanshu Rathore

Attachment: user_187367.ezm (zipped)
Sorry I was away. I will surely try this.

On 6/5/08, Martin <mgainty@(protected):
>
> Arun-
>
> did you disable the optimistic_lock code..?
> // OPTIMISTIC LOCK MODE (dont use this as this causes OptimisticLockMode
> Exceptions)
> // Attribute olNode = node.attribute( "optimistic-lock" );
> //return Versioning.OPTIMISTIC_LOCK_VERSION;
>
> // entity.setOptimisticLockMode( getOptimisticLockMode( olNode ) );
>
> //try a dirty lock..
> Attribute dirtyNode = node.attribute( "optimistic-lock-dirty");
>
> entity.setOptimisticLockMode( getOptimisticLockMode(dirtyNode) );
>
> //or lock all
> Attribute lockAllNode = node.attribute( "optimistic-lock-all");
>
> entity.setOptimisticLockMode( getOptimisticLockMode(lockAllNode) );
>
> //or No lock
> Attribute lockNoneNode = node.attribute( "optimistic-lock-none");
> entity.setOptimisticLockMode( getOptimisticLockMode(lockNoneNode) );
>
> HTH,
> Martin
> ----- Original Message ----- From: "Arun" <arun.george.1981@(protected)>
> To: "Struts Users Mailing List" <user@(protected)>
> Sent: Thursday, June 05, 2008 12:11 PM
> Subject: detached object cannot be persisted exception again
>
>
> Hi,
>>
>> I am using JPA and ehcache.
>> My entity is this.
>>
>> @Entity
>> @Table(name = "holiday_calendar")
>> @Cache(usage = CacheConcurrencyStrategy.READ_WRITE)
>> public class HolidaysCalendar
>> {
>> @Id
>> @Column(name = "HOLIDAY_CALENDAR_ID", nullable = false, unique = true)
>> private int holidayCalendarId;
>>
>> @Column(name = "DATE", nullable = false)
>> private Date date;
>>
>> @Column(name = "TYPE", nullable = false)
>> private String type;
>>
>> @Column(name = "DESCRIPTION", nullable = true)
>> private String description;
>>
>> ---
>>
>>
>> }
>>
>>
>> when I try to do an entityManager.merge(holidaycalendarobj)
>> First call I am succesful, next tine I get the exception
>> persistenceexception: detached object cannot be persisted.
>> I am using openSessionInViewFilter and spring.
>> I have tried using saveOrUpdate() of hibernate.
>> I got another exception then.
>>
>> My log told me this by which I am confused. Please help
>> javax.persistence.RollbackException: Error while commiting the transaction
>> at org.hibernate.ejb.TransactionImpl.commit (TransactionImpl.java:71)
>> at
>>
>> org.springframework.orm.jpa.JpaTransactionManager.doCommit (JpaTransactionManager.java:433)
>> at
>>
>> org.springframework.transaction.support.AbstractPlatformTransactionManager.processCommit (AbstractPlatformTransactionManager.java:651)
>> at
>>
>> org.springframework.transaction.support.AbstractPlatformTransactionManager.commit (AbstractPlatformTransactionManager.java:621)
>> at
>>
>> org.springframework.transaction.interceptor.TransactionAspectSupport.commitTransactionAfterReturning (TransactionAspectSupport.java:311)
>> at
>>
>> org.springframework.transaction.interceptor.TransactionInterceptor.invoke (TransactionInterceptor.java:117)
>> at
>>
>> org.springframework.aop.framework.ReflectiveMethodInvocation.proceed (ReflectiveMethodInvocation.java:161)
>> at
>>
>> org.springframework.aop.framework.Cglib2AopProxy$DynamicAdvisedInterceptor.intercept(Cglib2AopProxy.java:628)
>> at
>>
>> com.slingmedia.emp.facade.employee.LeaveManager$$EnhancerByCGLIB$$5a2b3b92.createHoliday(<generated>)
>> at
>>
>> com.slingmedia.emp.web.actions.employee.LeaveManagerAction.addHolidays(LeaveManagerAction.java:568)
>> 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:585)
>> at
>>
>> com.opensymphony.xwork2.DefaultActionInvocation.invokeAction (DefaultActionInvocation.java:404)
>> at
>>
>> com.opensymphony.xwork2.DefaultActionInvocation.invokeActionOnly (DefaultActionInvocation.java:267)
>> at
>>
>> com.opensymphony.xwork2.DefaultActionInvocation.invoke (DefaultActionInvocation.java:229)
>> at
>>
>> com.opensymphony.xwork2.interceptor.DefaultWorkflowInterceptor.doIntercept (DefaultWorkflowInterceptor.java:221)
>> at
>>
>> com.opensymphony.xwork2.interceptor.MethodFilterInterceptor.intercept (MethodFilterInterceptor.java:86)
>> at
>>
>> com.opensymphony.xwork2.DefaultActionInvocation$2.doProfiling(DefaultActionInvocation.java:224)
>> at
>>
>> com.opensymphony.xwork2.DefaultActionInvocation$2.doProfiling(DefaultActionInvocation.java:223)
>> at
>>
>> com.opensymphony.xwork2.util.profiling.UtilTimerStack.profile (UtilTimerStack.java:455)
>> at
>>
>> com.opensymphony.xwork2.DefaultActionInvocation.invoke (DefaultActionInvocation.java:221)
>> at
>>
>> com.opensymphony.xwork2.validator.ValidationInterceptor.doIntercept (ValidationInterceptor.java:150)
>> at
>>
>> org.apache.struts2.interceptor.validation.AnnotationValidationInterceptor.doIntercept (AnnotationValidationInterceptor.java:48)
>> at
>>
>> com.opensymphony.xwork2.interceptor.MethodFilterInterceptor.intercept (MethodFilterInterceptor.java:86)
>> at
>>
>> com.opensymphony.xwork2.DefaultActionInvocation$2.doProfiling(DefaultActionInvocation.java:224)
>> at
>>
>> com.opensymphony.xwork2.DefaultActionInvocation$2.doProfiling(DefaultActionInvocation.java:223)
>> at
>>
>> com.opensymphony.xwork2.util.profiling.UtilTimerStack.profile (UtilTimerStack.java:455)
>> at
>>
>> com.opensymphony.xwork2.DefaultActionInvocation.invoke (DefaultActionInvocation.java:221)
>> at
>>
>> com.opensymphony.xwork2.interceptor.ConversionErrorInterceptor.intercept (ConversionErrorInterceptor.java:123)
>> at
>>
>> com.opensymphony.xwork2.DefaultActionInvocation$2.doProfiling(DefaultActionInvocation.java:224)
>> at
>>
>> com.opensymphony.xwork2.DefaultActionInvocation$2.doProfiling(DefaultActionInvocation.java:223)
>> at
>>
>> com.opensymphony.xwork2.util.profiling.UtilTimerStack.profile (UtilTimerStack.java:455)
>> at
>>
>> com.opensymphony.xwork2.DefaultActionInvocation.invoke (DefaultActionInvocation.java:221)
>> at
>>
>> com.opensymphony.xwork2.interceptor.ParametersInterceptor.doIntercept (ParametersInterceptor.java:167)
>> at
>>
>> com.opensymphony.xwork2.interceptor.MethodFilterInterceptor.intercept (MethodFilterInterceptor.java:86)
>> at
>>
>> com.opensymphony.xwork2.DefaultActionInvocation$2.doProfiling(DefaultActionInvocation.java:224)
>> at
>>
>> com.opensymphony.xwork2.DefaultActionInvocation$2.doProfiling(DefaultActionInvocation.java:223)
>> at
>>
>> com.opensymphony.xwork2.util.profiling.UtilTimerStack.profile (UtilTimerStack.java:455)
>> at
>>
>> com.opensymphony.xwork2.DefaultActionInvocation.invoke (DefaultActionInvocation.java:221)
>> at
>>
>> com.opensymphony.xwork2.interceptor.StaticParametersInterceptor.intercept (StaticParametersInterceptor.java:105)
>> at
>>
>> com.opensymphony.xwork2.DefaultActionInvocation$2.doProfiling(DefaultActionInvocation.java:224)
>> at
>>
>> com.opensymphony.xwork2.DefaultActionInvocation$2.doProfiling(DefaultActionInvocation.java:223)
>> at
>>
>> com.opensymphony.xwork2.util.profiling.UtilTimerStack.profile (UtilTimerStack.java:455)
>> at
>>
>> com.opensymphony.xwork2.DefaultActionInvocation.invoke (DefaultActionInvocation.java:221)
>> at
>>
>> org.apache.struts2.interceptor.CheckboxInterceptor.intercept (CheckboxInterceptor.java:83)
>> at
>>
>> com.opensymphony.xwork2.DefaultActionInvocation$2.doProfiling(DefaultActionInvocation.java:224)
>> at
>>
>> com.opensymphony.xwork2.DefaultActionInvocation$2.doProfiling(DefaultActionInvocation.java:223)
>> at
>>
>> com.opensymphony.xwork2.util.profiling.UtilTimerStack.profile (UtilTimerStack.java:455)
>> at
>>
>> com.opensymphony.xwork2.DefaultActionInvocation.invoke (DefaultActionInvocation.java:221)
>> at
>>
>> org.apache.struts2.interceptor.FileUploadInterceptor.intercept (FileUploadInterceptor.java:207)
>> at
>>
>> com.opensymphony.xwork2.DefaultActionInvocation$2.doProfiling(DefaultActionInvocation.java:224)
>> at
>>
>> com.opensymphony.xwork2.DefaultActionInvocation$2.doProfiling(DefaultActionInvocation.java:223)
>> at
>>
>> com.opensymphony.xwork2.util.profiling.UtilTimerStack.profile (UtilTimerStack.java:455)
>> at
>>
>> com.opensymphony.xwork2.DefaultActionInvocation.invoke (DefaultActionInvocation.java:221)
>> at
>>
>> com.opensymphony.xwork2.interceptor.ModelDrivenInterceptor.intercept (ModelDrivenInterceptor.java:74)
>> at
>>
>> com.opensymphony.xwork2.DefaultActionInvocation$2.doProfiling(DefaultActionInvocation.java:224)
>> at
>>
>> com.opensymphony.xwork2.DefaultActionInvocation$2.doProfiling(DefaultActionInvocation.java:223)
>> at
>>
>> com.opensymphony.xwork2.util.profiling.UtilTimerStack.profile (UtilTimerStack.java:455)
>> at
>>
>> com.opensymphony.xwork2.DefaultActionInvocation.invoke (DefaultActionInvocation.java:221)
>> at
>>
>> com.opensymphony.xwork2.interceptor.ScopedModelDrivenInterceptor.intercept (ScopedModelDrivenInterceptor.java:127)
>> at
>>
>> com.opensymphony.xwork2.DefaultActionInvocation$2.doProfiling(DefaultActionInvocation.java:224)
>> at
>>
>> com.opensymphony.xwork2.DefaultActionInvocation$2.doProfiling(DefaultActionInvocation.java:223)
>> at
>>
>> com.opensymphony.xwork2.util.profiling.UtilTimerStack.profile (UtilTimerStack.java:455)
>> at
>>
>> com.opensymphony.xwork2.DefaultActionInvocation.invoke (DefaultActionInvocation.java:221)
>> at
>>
>> org.apache.struts2.interceptor.ProfilingActivationInterceptor.intercept (ProfilingActivationInterceptor.java:107)
>> at
>>
>> com.opensymphony.xwork2.DefaultActionInvocation$2.doProfiling(DefaultActionInvocation.java:224)
>> at
>>
>> com.opensymphony.xwork2.DefaultActionInvocation$2.doProfiling(DefaultActionInvocation.java:223)
>> at
>>
>> com.opensymphony.xwork2.util.profiling.UtilTimerStack.profile (UtilTimerStack.java:455)
>> at
>>
>> com.opensymphony.xwork2.DefaultActionInvocation.invoke (DefaultActionInvocation.java:221)
>> at
>>
>> org.apache.struts2.interceptor.debugging.DebuggingInterceptor.intercept (DebuggingInterceptor.java:206)
>> at
>>
>> com.opensymphony.xwork2.DefaultActionInvocation$2.doProfiling(DefaultActionInvocation.java:224)
>> at
>>
>> com.opensymphony.xwork2.DefaultActionInvocation$2.doProfiling(DefaultActionInvocation.java:223)
>> at
>>
>> com.opensymphony.xwork2.util.profiling.UtilTimerStack.profile (UtilTimerStack.java:455)
>> at
>>
>> com.opensymphony.xwork2.DefaultActionInvocation.invoke (DefaultActionInvocation.java:221)
>> at
>>
>> com.opensymphony.xwork2.interceptor.ChainingInterceptor.intercept (ChainingInterceptor.java:115)
>> at
>>
>> com.opensymphony.xwork2.DefaultActionInvocation$2.doProfiling(DefaultActionInvocation.java:224)
>> at
>>
>> com.opensymphony.xwork2.DefaultActionInvocation$2.doProfiling(DefaultActionInvocation.java:223)
>> at
>>
>> com.opensymphony.xwork2.util.profiling.UtilTimerStack.profile (UtilTimerStack.java:455)
>> at
>>
>> com.opensymphony.xwork2.DefaultActionInvocation.invoke (DefaultActionInvocation.java:221)
>> at
>>
>> com.opensymphony.xwork2.interceptor.I18nInterceptor.intercept (I18nInterceptor.java:143)
>> at
>>
>> com.opensymphony.xwork2.DefaultActionInvocation$2.doProfiling(DefaultActionInvocation.java:224)
>> at
>>
>> com.opensymphony.xwork2.DefaultActionInvocation$2.doProfiling(DefaultActionInvocation.java:223)
>> at
>>
>> com.opensymphony.xwork2.util.profiling.UtilTimerStack.profile (UtilTimerStack.java:455)
>> at
>>
>> com.opensymphony.xwork2.DefaultActionInvocation.invoke (DefaultActionInvocation.java:221)
>> at
>>
>> com.opensymphony.xwork2.interceptor.PrepareInterceptor.doIntercept (PrepareInterceptor.java:121)
>> at
>>
>> com.opensymphony.xwork2.interceptor.MethodFilterInterceptor.intercept (MethodFilterInterceptor.java:86)
>> at
>>
>> com.opensymphony.xwork2.DefaultActionInvocation$2.doProfiling(DefaultActionInvocation.java:224)
>> at
>>
>> com.opensymphony.xwork2.DefaultActionInvocation$2.doProfiling(DefaultActionInvocation.java:223)
>> at
>>
>> com.opensymphony.xwork2.util.profiling.UtilTimerStack.profile (UtilTimerStack.java:455)
>> at
>>
>> com.opensymphony.xwork2.DefaultActionInvocation.invoke (DefaultActionInvocation.java:221)
>> at
>>
>> org.apache.struts2.interceptor.ServletConfigInterceptor.intercept (ServletConfigInterceptor.java:170)
>> at
>>
>> com.opensymphony.xwork2.DefaultActionInvocation$2.doProfiling(DefaultActionInvocation.java:224)
>> at
>>
>> com.opensymphony.xwork2.DefaultActionInvocation$2.doProfiling(DefaultActionInvocation.java:223)
>> at
>>
>> com.opensymphony.xwork2.util.profiling.UtilTimerStack.profile (UtilTimerStack.java:455)
>> at
>>
>> com.opensymphony.xwork2.DefaultActionInvocation.invoke (DefaultActionInvocation.java:221)
>> at
>>
>> com.opensymphony.xwork2.interceptor.AliasInterceptor.intercept (AliasInterceptor.java:123)
>> at
>>
>> com.opensymphony.xwork2.DefaultActionInvocation$2.doProfiling(DefaultActionInvocation.java:224)
>> at
>>
>> com.opensymphony.xwork2.DefaultActionInvocation$2.doProfiling(DefaultActionInvocation.java:223)
>> at
>>
>> com.opensymphony.xwork2.util.profiling.UtilTimerStack.profile (UtilTimerStack.java:455)
>> at
>>
>> com.opensymphony.xwork2.DefaultActionInvocation.invoke (DefaultActionInvocation.java:221)
>> at
>>
>> com.opensymphony.xwork2.interceptor.ExceptionMappingInterceptor.intercept (ExceptionMappingInterceptor.java:176)
>> at
>>
>> com.opensymphony.xwork2.DefaultActionInvocation$2.doProfiling(DefaultActionInvocation.java:224)
>> at
>>
>> com.opensymphony.xwork2.DefaultActionInvocation$2.doProfiling(DefaultActionInvocation.java:223)
>> at
>>
>> com.opensymphony.xwork2.util.profiling.UtilTimerStack.profile (UtilTimerStack.java:455)
>> at
>>
>> com.opensymphony.xwork2.DefaultActionInvocation.invoke (DefaultActionInvocation.java:221)
>> at
>>
>> org.apache.struts2.impl.StrutsActionProxy.execute (StrutsActionProxy.java:50)
>> at
>>
>> org.apache.struts2.dispatcher.Dispatcher.serviceAction (Dispatcher.java:504)
>> at
>>
>> org.apache.struts2.dispatcher.FilterDispatcher.doFilter (FilterDispatcher.java:419)
>> at
>>
>> org.apache.catalina.core.ApplicationFilterChain.internalDoFilter (ApplicationFilterChain.java:202)
>> at
>>
>> org.apache.catalina.core.ApplicationFilterChain.doFilter (ApplicationFilterChain.java:173)
>> at
>>
>> org.springframework.orm.jpa.support.OpenEntityManagerInViewFilter.doFilterInternal (OpenEntityManagerInViewFilter.java:111)
>> at
>>
>> org.springframework.web.filter.OncePerRequestFilter.doFilter (OncePerRequestFilter.java:75)
>> at
>>
>> org.apache.catalina.core.ApplicationFilterChain.internalDoFilter (ApplicationFilterChain.java:202)
>> at
>>
>> org.apache.catalina.core.ApplicationFilterChain.doFilter (ApplicationFilterChain.java:173)
>> at
>>
>> org.apache.catalina.core.StandardWrapperValve.invoke (StandardWrapperValve.java:213)
>> at
>>
>> org.apache.catalina.core.StandardContextValve.invoke (StandardContextValve.java:178)
>> at
>>
>> org.apache.catalina.authenticator.AuthenticatorBase.invoke (AuthenticatorBase.java:524)
>> at
>>
>> org.apache.catalina.core.StandardHostValve.invoke (StandardHostValve.java:126)
>> at
>>
>> org.apache.catalina.cluster.tcp.ReplicationValve.invoke (ReplicationValve.java:346)
>> at
>>
>> org.apache.catalina.valves.ErrorReportValve.invoke (ErrorReportValve.java:105)
>> at
>>
>> org.apache.catalina.core.StandardEngineValve.invoke (StandardEngineValve.java:107)
>> at
>>
>> org.apache.catalina.connector.CoyoteAdapter.service (CoyoteAdapter.java:148)
>> at
>> org.apache.coyote.http11.Http11Processor.process (Http11Processor.java:869)
>> at
>>
>> org.apache.coyote.http11.Http11BaseProtocol$Http11ConnectionHandler.processConnection(Http11BaseProtocol.java:664)
>> at
>>
>> org.apache.tomcat.util.net.PoolTcpEndpoint.processSocket (PoolTcpEndpoint.java:527)
>> at
>>
>> org.apache.tomcat.util.net.LeaderFollowerWorkerThread.runIt (LeaderFollowerWorkerThread.java:80)
>> at
>>
>> org.apache.tomcat.util.threads.ThreadPool$ControlRunnable.run(ThreadPool.java:684)
>> at java.lang.Thread.run (Thread.java:595)
>> Caused by: javax.persistence.OptimisticLockException:
>> org.hibernate.StaleStateException: Batch update returned unexpected row
>> count from update [0]; actual row count: 0; expected: 1
>> at
>>
>> org.hibernate.ejb.AbstractEntityManagerImpl.wrapStaleStateException (AbstractEntityManagerImpl.java:654)
>> at org.hibernate.ejb.TransactionImpl.commit (TransactionImpl.java:59)
>> ... 129 more
>> Caused by: org.hibernate.StaleStateException: Batch update returned
>> unexpected row count from update [0]; actual row count: 0; expected: 1
>> at
>>
>> org.hibernate.jdbc.Expectations$BasicExpectation.checkBatched(Expectations.java:61)
>> at
>>
>> org.hibernate.jdbc.Expectations$BasicExpectation.verifyOutcome(Expectations.java:46)
>> at
>> org.hibernate.jdbc.BatchingBatcher.checkRowCounts (BatchingBatcher.java:68)
>> at
>> org.hibernate.jdbc.BatchingBatcher.doExecuteBatch (BatchingBatcher.java:48)
>> at
>> org.hibernate.jdbc.AbstractBatcher.executeBatch (AbstractBatcher.java:246)
>> at org.hibernate.engine.ActionQueue.executeActions (ActionQueue.java:266)
>> at org.hibernate.engine.ActionQueue.executeActions (ActionQueue.java:168)
>> at
>>
>> org.hibernate.event.def.AbstractFlushingEventListener.performExecutions (AbstractFlushingEventListener.java:298)
>> at
>>
>> org.hibernate.event.def.DefaultFlushEventListener.onFlush (DefaultFlushEventListener.java:27)
>> at org.hibernate.impl.SessionImpl.flush (SessionImpl.java:1000)
>> at org.hibernate.impl.SessionImpl.managedFlush (SessionImpl.java:338)
>> at
>> org.hibernate.transaction.JDBCTransaction.commit (JDBCTransaction.java:106)
>> at org.hibernate.ejb.TransactionImpl.commit (TransactionImpl.java:54)
>> ... 129 more
>>
>>
>>
>> Does any body has a soultion.I know this is becuase I use persist and
>> secondlevel cache together.
>> I am checking if the entity already exists in db. So the argument that I
>> am
>> trying to persist an already existing entity itself is wrong.
>> My guess is the cache is not synching with db or something of that sort.
>> I have enabled query caching and is using that.
>> Is it becuase of that?
>>
>> public List<HolidaysCalendar> getHolidaysCalendarForYear(int year, String
>> type)
>> {
>> Query query = null;
>>
>> if ( "-1".equals(type) )
>> {
>> query = entityManager.createQuery("select hcal from HolidaysCalendar hcal
>> where YEAR(hcal.date) = :year ");
>> }
>> else
>> query = entityManager.createQuery("select hcal from HolidaysCalendar hcal
>> where YEAR(hcal.date) = :year and hcal.type= :type");
>>
>> query.setHint("org.hibernate.cacheable", true);
>> //query.setHint("org.hibernate.timeout", 24 * 60 * 60);// 1 day cache.
>> query.setParameter("year", year);
>> if ( !"-1".equals(type) )
>> query.setParameter("type", type);
>> return query.getResultList();
>> }
>>
>>
>>
>> Is query level caching affecting this or some sort of things like that?
>> Please help!!!
>>
>>
>> --
>> Thanks
>> Arun George
>>
>>
>
> ---------------------------------------------------------------------
> To unsubscribe, e-mail: user-unsubscribe@(protected)
> For additional commands, e-mail: user-help@(protected)
>
>


--
Thanks
Arun George

Attachment: user_187368.ezm (zipped)

hi,
I used Ajax in my .jsp page for getting "plainText" data from action.

In my struts.xml, I config my action like this:
  <action name="myAction" class="com.myWeb.MyAction">
 <result type="plainText"></result>
  </action>

My webApp works well when deployed in tomcat. But in "Eclipse->Run As->Run
On Server" model, I get some Exception like behind:
SEVERE: Servlet.service() for servlet default threw exception
java.lang.NullPointerException
 at java.io.Reader.<init>(Unknown Source)
 at java.io.InputStreamReader.<init>(Unknown Source)
 at
org.apache.struts2.dispatcher.PlainTextResult.doExecute (PlainTextResult.java:148)
 at
org.apache.struts2.dispatcher.StrutsResultSupport.execute (StrutsResultSupport.java:178)
 at com.opensymphony.xwork2.DefaultActionInvocation...   ......

For fixing this Exception, I create a total blank jsp page "blank.jsp" ,
and modify struts.xml:
  <action name="myAction" class="com.myWeb.MyAction">
 <result type="plainText">/blank.jsp</result>
  </action>

I don't think this is a good way to solve problem. And is there some miss
in struts for supporting Ajax?

thx a lot
--
Sent from the Struts - User mailing list archive at Nabble.com.


Attachment: user_187369.ezm (zipped)
Is it possible in struts to configure the controller to read the application
resource file which is saved as UTF8 format?



It is possible to save the notepad file in UTF8 instead of ANSII.

I am able to save a similar file and read by input stream reader in UTF8 and
show the Polish characters in browser.



How about same in struts.






Attachment: user_187370.ezm (zipped)
Dave,
 Thanks for the reply, and that is what I am talking about. I do
append params to the action pointed to by a link. Its just that after I
have clicked that link with params, every subsequent request has that
same exact parameter appended. I need to stop this from happening. That
parameter should only apply to that action/link.

-Ryan

-----Original Message-----
From: Dave Newton [mailto:newton.dave@(protected)]
Sent: Thursday, June 05, 2008 7:15 PM
To: Struts Users Mailing List
Subject: Re: Parameter question

Are you talking about links to actions having parameters appended?

If so, are you either excluding parameters at each <s:url...> or,
alternatively, setting a default excludeParams via config?

Dave

--- On Thu, 6/5/08, Stanley, Eric <Eric.R.Stanley@(protected):
>   In my app, I have this package/action defined:
>
> <package name="data"
> extends="struts-default"
> namespace="/data">
>
> <default-interceptor-ref
> name="paramsPrepareParamsStack" />
>
> <action name="displayData"
> class="fm.gui.action.DataAction">
>
> <result
> name="success">/pages/data/viewData.jsp</result>
>
> <result
> name="error">/pages/error.jsp</result>
>
> </action>
>
> </package>
>
>
>
> The problem is that as soon as its called, every subsequent action has

> a bunch of parameters appended to it. This causes any other action to
> fail. They fail because there is no object for the parameters to be
> applied to, and rightfully so. I still dont completely grasp this
> interceptor, and I think fixing this will help a lot as far as that
> goes. Please let me know.
>
>
> E. Ryan Stanley
> Phone: 720.578.3703
> Pager: 801.482.0172
> <mailto:exstanl@(protected)>
>
>
>
> This communication is the property of Qwest and may contain
> confidential or privileged information. Unauthorized use of this
> communication is strictly prohibited and may be unlawful. If you have

> received this communication in error, please immediately notify the
> sender by reply e-mail and destroy all copies of the communication and

> any attachments.

---------------------------------------------------------------------
To unsubscribe, e-mail: user-unsubscribe@(protected)
For additional commands, e-mail: user-help@(protected)


Attachment: user_187372.ezm (zipped)
Hi,

I'm using Struts 2.0.9 and I would like to use optiontransferselect tag.
Nevertheless this tag seemed to required dojo struts integrate libraries.

I'm add the <s:head /> tag on the header on my jsp but dojo is not found
(Error message : dojo is required)
I'm also test with the tag <s:head theme="ajax" /> with the same result

I'm know that dojo is located in struts core jar but it is not loaded or
found.
I'm always try the solution of this thread but it's not resolv my problem :
http://www.mail-archive.com/user@(protected)

I need do declare dojo in my webApp ?

Here my jsp code (Inspirate by the struts showcase code):

<%@(protected)" %>

<html>
<head>
<title>Show Case - Tags - UI Tags - Optiontransferselect</title>
<s:head/>
</head>
<body>

<s:form action="lotsOfOptiontransferselectSubmit" namespace="/tags/ui"
method="post">
 <s:optiontransferselect
  label="Favourite Cartoons Characters"
  name="leftSideCartoonCharacters"
  list="{'Popeye', 'He-Man', 'Spiderman'}"
  doubleName="rightSideCartoonCharacters"
  doubleList="{'Superman', 'Mickey Mouse', 'Donald Duck'}"
  />
  <s:submit value="Submit It" />
</s:form>

</body>
</html>

Here the main configuration of my web.xml configuration

<?xml version="1.0" encoding="ISO-8859-1"?>

<!DOCTYPE web-app
  PUBLIC "-//Sun Microsystems, Inc.//DTD Web Application 2.3//EN"
  "http://java.sun.com/dtd/web-app_2_3.dtd">


<web-app>
  <description>My Application</description>

  <!-- ======== -->
  <!-- Struts 2 -->
  <!-- ======== -->
  <filter>
    <filter-name>struts2</filter-name>

<filter-class>org.apache.struts2.dispatcher.FilterDispatcher</filter-class>
  </filter>
  <filter-mapping>
    <filter-name>struts2</filter-name>
    <url-pattern>*.action</url-pattern>
  </filter-mapping>

  <!-- ======= -->
  <!-- TagLibs -->
  <!-- ======= -->
  <taglib>
    <taglib-uri>http://tiles.apache.org/tags-tiles</taglib-uri>
    <taglib-location>/WEB-INF/tld/tiles-jsp.tld</taglib-location>
  </taglib>
  <taglib>
    <taglib-uri>http://displaytag.sf.net</taglib-uri>
    <taglib-location>/WEB-INF/tld/displaytag.tld</taglib-location>
  </taglib>
  <taglib>
    <taglib-uri>http://java.sun.com/jstl/core</taglib-uri>
    <taglib-location>/WEB-INF/tld/taglibs-core.tld</taglib-location>
  </taglib>
  <taglib>
    <taglib-uri>http://ajaxtags.org/tags/ajax</taglib-uri>
    <taglib-location>/WEB-INF/tld/ajaxtags.tld</taglib-location>
  </taglib>

</web-app>

Best Regards
Cédric
©2008 gg3721.com - Jax Systems, LLC, U.S.A.