You are viewing a plain text version of this content. The canonical link for it is here.
Posted to dev@turbine.apache.org by jm...@apache.org on 2004/01/13 06:13:48 UTC

cvs commit: jakarta-turbine-fulcrum/src/java/org/apache/fulcrum/template TemplateEmail.java

jmcnally    2004/01/12 21:13:48

  Modified:    src/java/org/apache/fulcrum/template Tag: PRE_AVALON_BRANCH
                        TemplateEmail.java
  Log:
  Modified addTo and addCc to use the charset if given.
  Modified sendMultiple to set the charset before calling the above methods.
  Patch by Ed Korthof.
  
  Revision  Changes    Path
  No                   revision
  No                   revision
  1.4.2.4   +21 -7     jakarta-turbine-fulcrum/src/java/org/apache/fulcrum/template/TemplateEmail.java
  
  Index: TemplateEmail.java
  ===================================================================
  RCS file: /home/cvs/jakarta-turbine-fulcrum/src/java/org/apache/fulcrum/template/TemplateEmail.java,v
  retrieving revision 1.4.2.3
  retrieving revision 1.4.2.4
  diff -u -r1.4.2.3 -r1.4.2.4
  --- TemplateEmail.java	24 Nov 2003 14:15:01 -0000	1.4.2.3
  +++ TemplateEmail.java	13 Jan 2004 05:13:48 -0000	1.4.2.4
  @@ -288,7 +288,14 @@
                   name = email;
               }
   
  -            getToList().add(new InternetAddress(email, name));
  +            if (getCharSet() != null) 
  +            {
  +                getToList().add(new InternetAddress(email, name, getCharSet()));
  +            }
  +            else
  +            {
  +                getToList().add(new InternetAddress(email, name));
  +            }
           }
           catch (Exception e)
           {
  @@ -312,7 +319,14 @@
                   name = email;
               }
   
  -            getCCList().add(new InternetAddress(email, name));
  +            if (getCharSet() != null) 
  +            {
  +                getCCList().add(new InternetAddress(email, name, getCharSet()));
  +            }
  +            else
  +            {
  +                getCCList().add(new InternetAddress(email, name));
  +            }
           }
           catch (Exception e)
           {
  @@ -530,6 +544,10 @@
           }
   
           SimpleEmail se = new SimpleEmail();
  +        if (getCharSet() != null) 
  +        {
  +            se.setCharset(getCharSet());            
  +        }
           se.setFrom(getFromEmail(), getFromName());
           se.setTo(getToList());
           if (getCCList() != null && !getCCList().isEmpty())
  @@ -537,10 +555,6 @@
               se.setCc(getCCList());
           }
           addReplyTo(se);
  -        if (getCharSet() != null) 
  -        {
  -            se.setCharset(getCharSet());            
  -        }
           se.setSubject(getSubject());
           se.setMsg(body);
   
  
  
  

---------------------------------------------------------------------
To unsubscribe, e-mail: turbine-dev-unsubscribe@jakarta.apache.org
For additional commands, e-mail: turbine-dev-help@jakarta.apache.org


RE: Bug in VelocityHtmlEmail class ???

Posted by Eric Pugh <ep...@upstate.com>.
Yes, that is always a problem in Open source stuff, what version do you use!
I am not big on backporting every bugfix into the old code, so the 2.3.1 has
most of the fixes, but not all.  If a bug was fixed by looking at 2.3.1,
then 2.3.1 has the fix.  If the bug was fixed in 2.4, then probably not.  I
am more focused on getting 2.4 out the door.

As far as bug trackers go, Jakarta is switching to Jira, however we haven't
followed up on what to do to get turbine up on that yet...

Eric

> -----Original Message-----
> From: oron ogdan [mailto:oron.ogdan@netada.co.uk]
> Sent: Thursday, January 22, 2004 11:13 AM
> To: 'Turbine Developers List'; epugh@upstate.com
> Subject: RE: Bug in VelocityHtmlEmail class ???
>
>
> Thank you Eric
>
> This brings me to some more questions which you might be able
> to help me
> with
>
> -- what's the best place to report bugs (is it the scarab
> tool at nagoya ?)
>
> -- what's the best approach for me as a user of turbine in
> terms of interim
> release usage ?, I know release early and often is the key to
> the success of
> such projects. And I am interested in working with the latest
> and greatest
> as long as it does not break my app. I was running until last
> night on T2.3
> when I discovered this bug and decided to go through the
> maven build route
> recompile T2.3.1, which seems to work and didn't break any of
> my current
> code. However you say this specific bug has been fixed in
> 2.4, so from this
> I understand 2.3.1-dev does not have all the latest bug fixes
> in there.
>
> Oron
>
> -----Original Message-----
> From: Eric Pugh [mailto:epugh@upstate.com]
> Sent: Thursday, January 22, 2004 9:55 AM
> To: 'Turbine Developers List'; oron.ogdan@netada.co.uk
> Subject: RE: Bug in VelocityHtmlEmail class ???
>
>
> I think this bug was fixed in 2.4..   I checked it, and it looks good
> there..
>
> Eric
>
> > -----Original Message-----
> > From: oron ogdan [mailto:oron.ogdan@netada.co.uk]
> > Sent: Thursday, January 22, 2004 12:08 AM
> > To: 'Turbine Developers List'
> > Subject: Bug in VelocityHtmlEmail class ???
> >
> >
> > Hi
> >
> > Not sure how to officially report bugs to turbine as I
> didn't find an
> > 'apache bug database' entry for it.
> > Anyway, here is my little contribution to this top quality project
> >
> > seems like someone forgot to populate the hashmap for the
> cid entries
> >
> > BR
> >
> > Oron
> >
> > http://netada.co.uk
> >
> > patch follows :
> >
> > ---
> > D:\dev\jakarta-turbine-2.3.1-dev-20031124\src\java\org\apache\
> > turbine\util\v
> > elocity\VelocityHtmlEmail.java	2004-01-21
> > 22:57:50.000000000 -0000
> > +++
> > D:\dev\jakarta-turbine-2.3.1-dev-20031124\src\java\org\apache\
> > turbine\util\v
> > elocity\VelocityHtmlEmail.java.bak	2004-01-21
> > 22:58:03.000000000 -0000
> > @@ -280,13 +280,12 @@
> >      {
> >          String cid = "";
> >          try
> >          {
> >              URL url = new URL(surl);
> >              cid = embed(url, name);
> > -            embmap.put(name, cid);
> >          }
> >          catch (Exception e)
> >          {
> >              log.error("cannot embed " + surl + ": ", e);
> >          }
> >          return cid;
> >
> >
> >
> ---------------------------------------------------------------------
> > To unsubscribe, e-mail: turbine-dev-unsubscribe@jakarta.apache.org
> > For additional commands, e-mail: turbine-dev-help@jakarta.apache.org
>
>
> ---------------------------------------------------------------------
> To unsubscribe, e-mail: turbine-dev-unsubscribe@jakarta.apache.org
> For additional commands, e-mail: turbine-dev-help@jakarta.apache.org
>
>
> ---------------------------------------------------------------------
> To unsubscribe, e-mail: turbine-dev-unsubscribe@jakarta.apache.org
> For additional commands, e-mail: turbine-dev-help@jakarta.apache.org


---------------------------------------------------------------------
To unsubscribe, e-mail: turbine-dev-unsubscribe@jakarta.apache.org
For additional commands, e-mail: turbine-dev-help@jakarta.apache.org


RE: Bug in VelocityHtmlEmail class ???

Posted by oron ogdan <or...@netada.co.uk>.
Thank you Eric

This brings me to some more questions which you might be able to help me
with

-- what's the best place to report bugs (is it the scarab tool at nagoya ?)

-- what's the best approach for me as a user of turbine in terms of interim
release usage ?, I know release early and often is the key to the success of
such projects. And I am interested in working with the latest and greatest
as long as it does not break my app. I was running until last night on T2.3
when I discovered this bug and decided to go through the maven build route
recompile T2.3.1, which seems to work and didn't break any of my current
code. However you say this specific bug has been fixed in 2.4, so from this
I understand 2.3.1-dev does not have all the latest bug fixes in there.

Oron

-----Original Message-----
From: Eric Pugh [mailto:epugh@upstate.com]
Sent: Thursday, January 22, 2004 9:55 AM
To: 'Turbine Developers List'; oron.ogdan@netada.co.uk
Subject: RE: Bug in VelocityHtmlEmail class ???


I think this bug was fixed in 2.4..   I checked it, and it looks good
there..

Eric

> -----Original Message-----
> From: oron ogdan [mailto:oron.ogdan@netada.co.uk]
> Sent: Thursday, January 22, 2004 12:08 AM
> To: 'Turbine Developers List'
> Subject: Bug in VelocityHtmlEmail class ???
>
>
> Hi
>
> Not sure how to officially report bugs to turbine as I didn't find an
> 'apache bug database' entry for it.
> Anyway, here is my little contribution to this top quality project
>
> seems like someone forgot to populate the hashmap for the cid entries
>
> BR
>
> Oron
>
> http://netada.co.uk
>
> patch follows :
>
> ---
> D:\dev\jakarta-turbine-2.3.1-dev-20031124\src\java\org\apache\
> turbine\util\v
> elocity\VelocityHtmlEmail.java	2004-01-21
> 22:57:50.000000000 -0000
> +++
> D:\dev\jakarta-turbine-2.3.1-dev-20031124\src\java\org\apache\
> turbine\util\v
> elocity\VelocityHtmlEmail.java.bak	2004-01-21
> 22:58:03.000000000 -0000
> @@ -280,13 +280,12 @@
>      {
>          String cid = "";
>          try
>          {
>              URL url = new URL(surl);
>              cid = embed(url, name);
> -            embmap.put(name, cid);
>          }
>          catch (Exception e)
>          {
>              log.error("cannot embed " + surl + ": ", e);
>          }
>          return cid;
>
>
> ---------------------------------------------------------------------
> To unsubscribe, e-mail: turbine-dev-unsubscribe@jakarta.apache.org
> For additional commands, e-mail: turbine-dev-help@jakarta.apache.org


---------------------------------------------------------------------
To unsubscribe, e-mail: turbine-dev-unsubscribe@jakarta.apache.org
For additional commands, e-mail: turbine-dev-help@jakarta.apache.org


---------------------------------------------------------------------
To unsubscribe, e-mail: turbine-dev-unsubscribe@jakarta.apache.org
For additional commands, e-mail: turbine-dev-help@jakarta.apache.org


RE: Bug in VelocityHtmlEmail class ???

Posted by Eric Pugh <ep...@upstate.com>.
I think this bug was fixed in 2.4..   I checked it, and it looks good
there..

Eric

> -----Original Message-----
> From: oron ogdan [mailto:oron.ogdan@netada.co.uk]
> Sent: Thursday, January 22, 2004 12:08 AM
> To: 'Turbine Developers List'
> Subject: Bug in VelocityHtmlEmail class ???
>
>
> Hi
>
> Not sure how to officially report bugs to turbine as I didn't find an
> 'apache bug database' entry for it.
> Anyway, here is my little contribution to this top quality project
>
> seems like someone forgot to populate the hashmap for the cid entries
>
> BR
>
> Oron
>
> http://netada.co.uk
>
> patch follows :
>
> ---
> D:\dev\jakarta-turbine-2.3.1-dev-20031124\src\java\org\apache\
> turbine\util\v
> elocity\VelocityHtmlEmail.java	2004-01-21
> 22:57:50.000000000 -0000
> +++
> D:\dev\jakarta-turbine-2.3.1-dev-20031124\src\java\org\apache\
> turbine\util\v
> elocity\VelocityHtmlEmail.java.bak	2004-01-21
> 22:58:03.000000000 -0000
> @@ -280,13 +280,12 @@
>      {
>          String cid = "";
>          try
>          {
>              URL url = new URL(surl);
>              cid = embed(url, name);
> -            embmap.put(name, cid);
>          }
>          catch (Exception e)
>          {
>              log.error("cannot embed " + surl + ": ", e);
>          }
>          return cid;
>
>
> ---------------------------------------------------------------------
> To unsubscribe, e-mail: turbine-dev-unsubscribe@jakarta.apache.org
> For additional commands, e-mail: turbine-dev-help@jakarta.apache.org


---------------------------------------------------------------------
To unsubscribe, e-mail: turbine-dev-unsubscribe@jakarta.apache.org
For additional commands, e-mail: turbine-dev-help@jakarta.apache.org


Bug in VelocityHtmlEmail class ???

Posted by oron ogdan <or...@netada.co.uk>.
Hi

Not sure how to officially report bugs to turbine as I didn't find an
'apache bug database' entry for it.
Anyway, here is my little contribution to this top quality project

seems like someone forgot to populate the hashmap for the cid entries

BR

Oron

http://netada.co.uk

patch follows :

---
D:\dev\jakarta-turbine-2.3.1-dev-20031124\src\java\org\apache\turbine\util\v
elocity\VelocityHtmlEmail.java	2004-01-21 22:57:50.000000000 -0000
+++
D:\dev\jakarta-turbine-2.3.1-dev-20031124\src\java\org\apache\turbine\util\v
elocity\VelocityHtmlEmail.java.bak	2004-01-21 22:58:03.000000000 -0000
@@ -280,13 +280,12 @@
     {
         String cid = "";
         try
         {
             URL url = new URL(surl);
             cid = embed(url, name);
-            embmap.put(name, cid);
         }
         catch (Exception e)
         {
             log.error("cannot embed " + surl + ": ", e);
         }
         return cid;


---------------------------------------------------------------------
To unsubscribe, e-mail: turbine-dev-unsubscribe@jakarta.apache.org
For additional commands, e-mail: turbine-dev-help@jakarta.apache.org


RE: missing dependency propertyset-1.3-1Oct03.jar

Posted by Eric Pugh <ep...@upstate.com>.
John,

Sorry about that..  That missing dependency has been there for a while, I
guess you are the first one to hit it though..  It is required by a couple
different projects.

I have just uploaded it to
http://jakarta.apache.org/turbine/repo/opensymphony/jars/.  It should now
automatically pull it down when you do the build.  If you run into any
others, please let me know.  I know how frustrating missing dependencies can
be...

Eric

> -----Original Message-----
> From: John McNally [mailto:jmcnally@collab.net]
> Sent: Tuesday, January 13, 2004 6:20 AM
> To: Turbine Developers List
> Subject: missing dependency propertyset-1.3-1Oct03.jar
>
>
> I was going to apply the following patch to HEAD but could not get a
> complete build due to the following dependency which I could not
> satisfy:
>
> propertyset-1.3-1Oct03.jar
>
> It is unrelated to the patch below, but how am I supposed to get the
> above jar, am I expected to build from CVS?  Maven did not
> supply a url.
>
> john mcnally
>
> On Mon, 2004-01-12 at 21:13, jmcnally@apache.org wrote:
> > jmcnally    2004/01/12 21:13:48
> >
> >   Modified:    src/java/org/apache/fulcrum/template Tag:
> PRE_AVALON_BRANCH
> >                         TemplateEmail.java
> >   Log:
> >   Modified addTo and addCc to use the charset if given.
> >   Modified sendMultiple to set the charset before calling
> the above methods.
> >   Patch by Ed Korthof.
> >
> >   Revision  Changes    Path
> >   No                   revision
> >   No                   revision
> >   1.4.2.4   +21 -7
> jakarta-turbine-fulcrum/src/java/org/apache/fulcrum/template/T
> emplateEmail.java
> >
> >   Index: TemplateEmail.java
> >
> ===================================================================
> >   RCS file:
> /home/cvs/jakarta-turbine-fulcrum/src/java/org/apache/fulcrum/
> template/TemplateEmail.java,v
> >   retrieving revision 1.4.2.3
> >   retrieving revision 1.4.2.4
> >   diff -u -r1.4.2.3 -r1.4.2.4
> >   --- TemplateEmail.java	24 Nov 2003 14:15:01 -0000	1.4.2.3
> >   +++ TemplateEmail.java	13 Jan 2004 05:13:48 -0000	1.4.2.4
> >   @@ -288,7 +288,14 @@
> >                    name = email;
> >                }
> >
> >   -            getToList().add(new InternetAddress(email, name));
> >   +            if (getCharSet() != null)
> >   +            {
> >   +                getToList().add(new
> InternetAddress(email, name, getCharSet()));
> >   +            }
> >   +            else
> >   +            {
> >   +                getToList().add(new
> InternetAddress(email, name));
> >   +            }
> >            }
> >            catch (Exception e)
> >            {
> >   @@ -312,7 +319,14 @@
> >                    name = email;
> >                }
> >
> >   -            getCCList().add(new InternetAddress(email, name));
> >   +            if (getCharSet() != null)
> >   +            {
> >   +                getCCList().add(new
> InternetAddress(email, name, getCharSet()));
> >   +            }
> >   +            else
> >   +            {
> >   +                getCCList().add(new
> InternetAddress(email, name));
> >   +            }
> >            }
> >            catch (Exception e)
> >            {
> >   @@ -530,6 +544,10 @@
> >            }
> >
> >            SimpleEmail se = new SimpleEmail();
> >   +        if (getCharSet() != null)
> >   +        {
> >   +            se.setCharset(getCharSet());
> >   +        }
> >            se.setFrom(getFromEmail(), getFromName());
> >            se.setTo(getToList());
> >            if (getCCList() != null && !getCCList().isEmpty())
> >   @@ -537,10 +555,6 @@
> >                se.setCc(getCCList());
> >            }
> >            addReplyTo(se);
> >   -        if (getCharSet() != null)
> >   -        {
> >   -            se.setCharset(getCharSet());
> >   -        }
> >            se.setSubject(getSubject());
> >            se.setMsg(body);
> >
> >
> >
> >
> >
> >
> ---------------------------------------------------------------------
> > To unsubscribe, e-mail: turbine-dev-unsubscribe@jakarta.apache.org
> > For additional commands, e-mail: turbine-dev-help@jakarta.apache.org
>
>
> ---------------------------------------------------------------------
> To unsubscribe, e-mail: turbine-dev-unsubscribe@jakarta.apache.org
> For additional commands, e-mail: turbine-dev-help@jakarta.apache.org


---------------------------------------------------------------------
To unsubscribe, e-mail: turbine-dev-unsubscribe@jakarta.apache.org
For additional commands, e-mail: turbine-dev-help@jakarta.apache.org


missing dependency propertyset-1.3-1Oct03.jar

Posted by John McNally <jm...@collab.net>.
I was going to apply the following patch to HEAD but could not get a
complete build due to the following dependency which I could not
satisfy:

propertyset-1.3-1Oct03.jar

It is unrelated to the patch below, but how am I supposed to get the
above jar, am I expected to build from CVS?  Maven did not supply a url.

john mcnally

On Mon, 2004-01-12 at 21:13, jmcnally@apache.org wrote:
> jmcnally    2004/01/12 21:13:48
> 
>   Modified:    src/java/org/apache/fulcrum/template Tag: PRE_AVALON_BRANCH
>                         TemplateEmail.java
>   Log:
>   Modified addTo and addCc to use the charset if given.
>   Modified sendMultiple to set the charset before calling the above methods.
>   Patch by Ed Korthof.
>   
>   Revision  Changes    Path
>   No                   revision
>   No                   revision
>   1.4.2.4   +21 -7     jakarta-turbine-fulcrum/src/java/org/apache/fulcrum/template/TemplateEmail.java
>   
>   Index: TemplateEmail.java
>   ===================================================================
>   RCS file: /home/cvs/jakarta-turbine-fulcrum/src/java/org/apache/fulcrum/template/TemplateEmail.java,v
>   retrieving revision 1.4.2.3
>   retrieving revision 1.4.2.4
>   diff -u -r1.4.2.3 -r1.4.2.4
>   --- TemplateEmail.java	24 Nov 2003 14:15:01 -0000	1.4.2.3
>   +++ TemplateEmail.java	13 Jan 2004 05:13:48 -0000	1.4.2.4
>   @@ -288,7 +288,14 @@
>                    name = email;
>                }
>    
>   -            getToList().add(new InternetAddress(email, name));
>   +            if (getCharSet() != null) 
>   +            {
>   +                getToList().add(new InternetAddress(email, name, getCharSet()));
>   +            }
>   +            else
>   +            {
>   +                getToList().add(new InternetAddress(email, name));
>   +            }
>            }
>            catch (Exception e)
>            {
>   @@ -312,7 +319,14 @@
>                    name = email;
>                }
>    
>   -            getCCList().add(new InternetAddress(email, name));
>   +            if (getCharSet() != null) 
>   +            {
>   +                getCCList().add(new InternetAddress(email, name, getCharSet()));
>   +            }
>   +            else
>   +            {
>   +                getCCList().add(new InternetAddress(email, name));
>   +            }
>            }
>            catch (Exception e)
>            {
>   @@ -530,6 +544,10 @@
>            }
>    
>            SimpleEmail se = new SimpleEmail();
>   +        if (getCharSet() != null) 
>   +        {
>   +            se.setCharset(getCharSet());            
>   +        }
>            se.setFrom(getFromEmail(), getFromName());
>            se.setTo(getToList());
>            if (getCCList() != null && !getCCList().isEmpty())
>   @@ -537,10 +555,6 @@
>                se.setCc(getCCList());
>            }
>            addReplyTo(se);
>   -        if (getCharSet() != null) 
>   -        {
>   -            se.setCharset(getCharSet());            
>   -        }
>            se.setSubject(getSubject());
>            se.setMsg(body);
>    
>   
>   
>   
> 
> ---------------------------------------------------------------------
> To unsubscribe, e-mail: turbine-dev-unsubscribe@jakarta.apache.org
> For additional commands, e-mail: turbine-dev-help@jakarta.apache.org


---------------------------------------------------------------------
To unsubscribe, e-mail: turbine-dev-unsubscribe@jakarta.apache.org
For additional commands, e-mail: turbine-dev-help@jakarta.apache.org