incubator-empire-db-dev mailing list archives

Site index · List index
Message view « Date » · « Thread »
Top « Date » · « Thread »
From Benjamin Venditti <>
Subject re: Uprading struts2 extensions to struts 2.1.6
Date Mon, 13 Jul 2009 21:49:57 GMT
Hi Rainer,

i tested both web applications and couldn't find any problems. However 2 more things had to
be fixed and therefore i updated the patch (included in this mail).

About the problem with the "targets" property of the "Anchor" class. Unfortunately i couldn't
find the sources for sturts 2.0.11 but i had a look in the sources of 2.0.12.
To me it looks like that the property "targets" has been removed without replacement and the
property "href", which was previously inherited from "AbstractRemoteCallUIBean", has now moved
to "Anchor" directly itself. Another point why i think that "href" is not is not the replacement
for "targets" is the drescription in the sources.
    targes:     Comma delimited list of ids of the elements whose content will be updated
    href:        The URL.

Please let me know what you think about it.

best regards,

-----Ursprüngliche Nachricht-----
Von: "Rainer Döbele" <>
Gesendet: 09.07.09 16:10:11
An: <>
Betreff: re: Uprading struts2 extensions to struts 2.1.6

Hi Benni,

I have actually compared the Struts2 source code of 2.0.11 and 2.1.6 (which you should have
as well) and to me it looked as if they have just renamed targets to href. But I might be
wrong. Just have a go and see what happens. It should go in there and the result should be

Benjamin Venditti wrote:
> re: Uprading struts2 extensions to struts 2.1.6
> Hi Rainer,
> thanks for your response and hints. For the first issue (ItemListTag)
> your suggestion looks like the right solution (i also found the
> comments in the source).
> However for the second issue (LinkTag / Anchor) i am not so sure as the
> "href" property already existed before and therefore i think its not
> the appropriate replacement.
> Previous struts APIs referred to 'targets' as list of element ids whose
> content will be updated with the text returned from request
> I couldn't find any similar property that could represent that nature.
> I also do not really understand what that means, afaik "target" can
> have values like "_blank, _parent ...".
> I created a patch that affects 12 files and can easily be apply with
> Eclipse (right click -> team -> Apply Patch ...). After you have
> applied the patch you can find my
> changes and comments by searching the string "* UPGRADE-struts 2.1.6"
> in the source code.
> I'll have to do further testing, but with the patch you can have a
> first look.
> best regards,
>     Benjamin
> -----Ursprüngliche Nachricht-----
> Von: "Rainer Döbele" <>
> Gesendet: 06.07.09 21:01:04
> An: <>
> Betreff: re: Uprading struts2 extensions to struts 2.1.6
> Hi Benni,
> first of all it's certainly a great idea to update our dependencies to
> the latest struts2 release.
> Thanks to Maven changing version is simple, however there seem to be
> quite a few problems of which you must have already solved quite a few.
> Without doing your work again I cannot compile and run the code, hence
> your questions are hard to answer just by looking at the code.
> But since this was my only option I gave it a go and this is my
> conclusion:
> 1. In the class ItemListTag you should replace getId()/setId() by
> getVar()/setVar()
> 2. In the classes LinkTag and AnchorComponent you should replace the
> property "targets" by "href" and use setHref() instead of setTargets()
> respectively.
> That could do the job (as I said this is untested - only concluded from
> reading the struts2 source code).
> But of course you would have to test everything properly.
> When you run the sample it should use this peace of code.
> The next question is how do we get your changes merged with our code?
> How many files did you have to change so far?
> Rainer
> wrote:
> > re: Uprading struts2 extensions to struts 2.1.6
> >
> > Hello EmpireDB developer team,
> >
> > i am currently trying to get the empire-db struts extensions running
> > with struts 2.1.6.
> > Most of the problems could be solved quite easily, but unfortunately
> i
> > have two issues that i can't solve without doubt.
> >
> > 1. Class: *ItemListTag:130*
> >     Previously the the method "getId()" was called from the class
> > "org.apache.struts2.components.Component"
> >     but this method does no longer exist. By making the nested class
> > "ItemIteratorComponent" non static, i could get rid
> >     of the "Cannot make static referenced ..." error, however i am
> not
> > sure if this is a appropriate solution, as thereby the
> >     method "javax.servlet.jsp.tagext.TagSupport.getId()" will be
> > called.
> >
> > 2. Classes: *LinkTag:97, AnchorComponent:101*
> >     The Attribute "targets" as well as the method "setTarges(...)" no
> > longer exists in *org.apache.struts2.components.Anchor*.
> >     My current solution for this issue is to remove all references in
> > all other classes and in the tag library.
> >
> > I could compile the struts2 extensions and ran the sample application
> > on
> > tomcat 6.x with the stated changes (and others).
> > Could you please help me with the two issues. If you like i can send
> > you
> > all the changes i made.
> >
> > Thanks in advance.
> >
> >     Benjamin
> ________________________________________________________________
> Neu: WEB.DE Doppel-FLAT mit Internet-Flatrate + Telefon-Flatrate
> für nur 19,99 Euro/mtl.!*

Neu: WEB.DE Doppel-FLAT mit Internet-Flatrate + Telefon-Flatrate
für nur 19,99 Euro/mtl.!*

View raw message