You are viewing a plain text version of this content. The canonical link for it is here.
Posted to dev@velocity.apache.org by "Antonio Petrelli (JIRA)" <de...@velocity.apache.org> on 2010/11/29 14:55:37 UTC

[jira] Created: (VELOCITY-789) Reorganize dependencies in Velocity Engine Core

Reorganize dependencies in Velocity Engine Core
-----------------------------------------------

                 Key: VELOCITY-789
                 URL: https://issues.apache.org/jira/browse/VELOCITY-789
             Project: Velocity
          Issue Type: Bug
            Reporter: Antonio Petrelli
            Assignee: Antonio Petrelli


Currently Velocity Engine core depends on:
Commons Lang
Commons Collections
Avalon LogKit
Apache Jakarta ORO

LogKit and ORO should be removed, as they are obsolete. Commons Lang and Collections should be replaced or shaded.

-- 
This message is automatically generated by JIRA.
-
You can reply to this email to add a comment to the issue online.


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


[jira] Updated: (VELOCITY-789) Reorganize dependencies in Velocity Engine Core

Posted by "Antonio Petrelli (JIRA)" <de...@velocity.apache.org>.
     [ https://issues.apache.org/jira/browse/VELOCITY-789?page=com.atlassian.jira.plugin.system.issuetabpanels:all-tabpanel ]

Antonio Petrelli updated VELOCITY-789:
--------------------------------------

          Component/s: Engine
    Affects Version/s: 2.0
        Fix Version/s: 2.0

> Reorganize dependencies in Velocity Engine Core
> -----------------------------------------------
>
>                 Key: VELOCITY-789
>                 URL: https://issues.apache.org/jira/browse/VELOCITY-789
>             Project: Velocity
>          Issue Type: Bug
>          Components: Engine
>    Affects Versions: 2.0
>            Reporter: Antonio Petrelli
>            Assignee: Antonio Petrelli
>             Fix For: 2.0
>
>
> Currently Velocity Engine core depends on:
> Commons Lang
> Commons Collections
> Avalon LogKit
> Apache Jakarta ORO
> LogKit and ORO should be removed, as they are obsolete. Commons Lang and Collections should be replaced or shaded.

-- 
This message is automatically generated by JIRA.
-
You can reply to this email to add a comment to the issue online.


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


[jira] Commented: (VELOCITY-789) Reorganize dependencies in Velocity Engine Core

Posted by "Antonio Petrelli (JIRA)" <de...@velocity.apache.org>.
    [ https://issues.apache.org/jira/browse/VELOCITY-789?page=com.atlassian.jira.plugin.system.issuetabpanels:comment-tabpanel&focusedCommentId=12966932#action_12966932 ] 

Antonio Petrelli commented on VELOCITY-789:
-------------------------------------------

Just an update.
I decided not to shade dependencies, but to copy the code and edit them a bit.
In fact, all dependencies are from Apache products, so we can use it as it was ours (we are, after all, the Apache Software Foundation :-) ).

> Reorganize dependencies in Velocity Engine Core
> -----------------------------------------------
>
>                 Key: VELOCITY-789
>                 URL: https://issues.apache.org/jira/browse/VELOCITY-789
>             Project: Velocity
>          Issue Type: Bug
>            Reporter: Antonio Petrelli
>            Assignee: Antonio Petrelli
>
> Currently Velocity Engine core depends on:
> Commons Lang
> Commons Collections
> Avalon LogKit
> Apache Jakarta ORO
> LogKit and ORO should be removed, as they are obsolete. Commons Lang and Collections should be replaced or shaded.

-- 
This message is automatically generated by JIRA.
-
You can reply to this email to add a comment to the issue online.


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


[jira] Commented: (VELOCITY-789) Reorganize dependencies in Velocity Engine Core

Posted by "Adrian Tarau (JIRA)" <de...@velocity.apache.org>.
    [ https://issues.apache.org/jira/browse/VELOCITY-789?page=com.atlassian.jira.plugin.system.issuetabpanels:comment-tabpanel&focusedCommentId=12966980#action_12966980 ] 

Adrian Tarau commented on VELOCITY-789:
---------------------------------------

I'm pro-shading since you are linked to their released versions(get fixes). If some modifications are need it(third-party API doesn't allow the integration without changing the code) that means Velocity doesn't need that library and it's best to implement something internal.

> Reorganize dependencies in Velocity Engine Core
> -----------------------------------------------
>
>                 Key: VELOCITY-789
>                 URL: https://issues.apache.org/jira/browse/VELOCITY-789
>             Project: Velocity
>          Issue Type: Bug
>            Reporter: Antonio Petrelli
>            Assignee: Antonio Petrelli
>
> Currently Velocity Engine core depends on:
> Commons Lang
> Commons Collections
> Avalon LogKit
> Apache Jakarta ORO
> LogKit and ORO should be removed, as they are obsolete. Commons Lang and Collections should be replaced or shaded.

-- 
This message is automatically generated by JIRA.
-
You can reply to this email to add a comment to the issue online.


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


[jira] Closed: (VELOCITY-789) Reorganize dependencies in Velocity Engine Core

Posted by "Antonio Petrelli (JIRA)" <de...@velocity.apache.org>.
     [ https://issues.apache.org/jira/browse/VELOCITY-789?page=com.atlassian.jira.plugin.system.issuetabpanels:all-tabpanel ]

Antonio Petrelli closed VELOCITY-789.
-------------------------------------

    Resolution: Fixed

Commons Lang and Commons Collections have been shaded.
Original artifact: 380,182 bytes
Shaded artifact: 441.062
Not too bad :-)

> Reorganize dependencies in Velocity Engine Core
> -----------------------------------------------
>
>                 Key: VELOCITY-789
>                 URL: https://issues.apache.org/jira/browse/VELOCITY-789
>             Project: Velocity
>          Issue Type: Bug
>          Components: Engine
>    Affects Versions: 2.0
>            Reporter: Antonio Petrelli
>            Assignee: Antonio Petrelli
>             Fix For: 2.0
>
>
> Currently Velocity Engine core depends on:
> Commons Lang
> Commons Collections
> Avalon LogKit
> Apache Jakarta ORO
> LogKit and ORO should be removed, as they are obsolete. Commons Lang and Collections should be replaced or shaded.

-- 
This message is automatically generated by JIRA.
-
You can reply to this email to add a comment to the issue online.


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


[jira] Commented: (VELOCITY-789) Reorganize dependencies in Velocity Engine Core

Posted by "Adrian Tarau (JIRA)" <de...@velocity.apache.org>.
    [ https://issues.apache.org/jira/browse/VELOCITY-789?page=com.atlassian.jira.plugin.system.issuetabpanels:comment-tabpanel&focusedCommentId=12966891#action_12966891 ] 

Adrian Tarau commented on VELOCITY-789:
---------------------------------------

For a library that has ~500kb bringing another 500kb for a few classes it's just ... not optimal. Don't get me wrong I am not against using great code in Velocity  but this days  it is very common to shade libraries to reduce the size and avoid version conflicts(include only what you use).

Since Velocity is moving to Maven, Maven Shade Plugin( http://maven.apache.org/plugins/maven-shade-plugin) can be used to include(and relocate) any class dependencies.

The only disadvantage I would see is to get bug reports for classes that are not Velocity specific(but since those classes will be relocated under org.apache.velocity it will look like they are developed as part of Velocity project), but I think this would not happen to often.

> Reorganize dependencies in Velocity Engine Core
> -----------------------------------------------
>
>                 Key: VELOCITY-789
>                 URL: https://issues.apache.org/jira/browse/VELOCITY-789
>             Project: Velocity
>          Issue Type: Bug
>            Reporter: Antonio Petrelli
>            Assignee: Antonio Petrelli
>
> Currently Velocity Engine core depends on:
> Commons Lang
> Commons Collections
> Avalon LogKit
> Apache Jakarta ORO
> LogKit and ORO should be removed, as they are obsolete. Commons Lang and Collections should be replaced or shaded.

-- 
This message is automatically generated by JIRA.
-
You can reply to this email to add a comment to the issue online.


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


[jira] Commented: (VELOCITY-789) Reorganize dependencies in Velocity Engine Core

Posted by "Nathan Bubna (JIRA)" <de...@velocity.apache.org>.
    [ https://issues.apache.org/jira/browse/VELOCITY-789?page=com.atlassian.jira.plugin.system.issuetabpanels:comment-tabpanel&focusedCommentId=12966977#action_12966977 ] 

Nathan Bubna commented on VELOCITY-789:
---------------------------------------

Why not shade?  At least with shading we can get updates and pass off bug reports more easily, right?

> Reorganize dependencies in Velocity Engine Core
> -----------------------------------------------
>
>                 Key: VELOCITY-789
>                 URL: https://issues.apache.org/jira/browse/VELOCITY-789
>             Project: Velocity
>          Issue Type: Bug
>            Reporter: Antonio Petrelli
>            Assignee: Antonio Petrelli
>
> Currently Velocity Engine core depends on:
> Commons Lang
> Commons Collections
> Avalon LogKit
> Apache Jakarta ORO
> LogKit and ORO should be removed, as they are obsolete. Commons Lang and Collections should be replaced or shaded.

-- 
This message is automatically generated by JIRA.
-
You can reply to this email to add a comment to the issue online.


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


[jira] Commented: (VELOCITY-789) Reorganize dependencies in Velocity Engine Core

Posted by "Adrian Tarau (JIRA)" <de...@velocity.apache.org>.
    [ https://issues.apache.org/jira/browse/VELOCITY-789?page=com.atlassian.jira.plugin.system.issuetabpanels:comment-tabpanel&focusedCommentId=12967095#action_12967095 ] 

Adrian Tarau commented on VELOCITY-789:
---------------------------------------

Shading :) I'm thinking to add a dependency to BeanUtils's converters package :)  for type conversion in Configuration. This will add 47kb in compressed byte code but I think it's worth it...if not approved I will go with a simpler type conversion.

http://commons.apache.org/beanutils/v1.8.3/apidocs/index.html?org/apache/commons/beanutils/converters/package-summary.html

> Reorganize dependencies in Velocity Engine Core
> -----------------------------------------------
>
>                 Key: VELOCITY-789
>                 URL: https://issues.apache.org/jira/browse/VELOCITY-789
>             Project: Velocity
>          Issue Type: Bug
>            Reporter: Antonio Petrelli
>            Assignee: Antonio Petrelli
>
> Currently Velocity Engine core depends on:
> Commons Lang
> Commons Collections
> Avalon LogKit
> Apache Jakarta ORO
> LogKit and ORO should be removed, as they are obsolete. Commons Lang and Collections should be replaced or shaded.

-- 
This message is automatically generated by JIRA.
-
You can reply to this email to add a comment to the issue online.


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


[jira] Commented: (VELOCITY-789) Reorganize dependencies in Velocity Engine Core

Posted by "Antonio Petrelli (JIRA)" <de...@velocity.apache.org>.
    [ https://issues.apache.org/jira/browse/VELOCITY-789?page=com.atlassian.jira.plugin.system.issuetabpanels:comment-tabpanel&focusedCommentId=12967122#action_12967122 ] 

Antonio Petrelli commented on VELOCITY-789:
-------------------------------------------

Adrian, go on with it, I think that a common conversion utility, already stable and mature (just like StringEscapeUtils is mature) is better than any copied code.
You know, people change their minds sometimes :-D

> Reorganize dependencies in Velocity Engine Core
> -----------------------------------------------
>
>                 Key: VELOCITY-789
>                 URL: https://issues.apache.org/jira/browse/VELOCITY-789
>             Project: Velocity
>          Issue Type: Bug
>          Components: Engine
>    Affects Versions: 2.0
>            Reporter: Antonio Petrelli
>            Assignee: Antonio Petrelli
>             Fix For: 2.0
>
>
> Currently Velocity Engine core depends on:
> Commons Lang
> Commons Collections
> Avalon LogKit
> Apache Jakarta ORO
> LogKit and ORO should be removed, as they are obsolete. Commons Lang and Collections should be replaced or shaded.

-- 
This message is automatically generated by JIRA.
-
You can reply to this email to add a comment to the issue online.


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


[jira] Commented: (VELOCITY-789) Reorganize dependencies in Velocity Engine Core

Posted by "Antonio Petrelli (JIRA)" <de...@velocity.apache.org>.
    [ https://issues.apache.org/jira/browse/VELOCITY-789?page=com.atlassian.jira.plugin.system.issuetabpanels:comment-tabpanel&focusedCommentId=12966997#action_12966997 ] 

Antonio Petrelli commented on VELOCITY-789:
-------------------------------------------

The problem is only Commons Lang, because Commons Collections is not useful anymore, because I think Adrian will remove the only class really used: ExtendedProperties.

About Commons Lang, at a first glance I noticed that the really needed classes are StringEscapeUtils and StringUtils.
But, about StringUtils, we need only "lame" methods (isEmpty, isNotEmpty, equals) that can be easily copied into the original StringUtils inside Velocity itself.

Now it's time of StringEscapeUtils. It is really useful, with the exception of escapeSql, that is pretty lame too (it replaces quotes with two quotes, nothing more). This method is problematic since it uses StringUtils.replace, that works differently to String.replaceAll (no regex allowed).

So I can try to shade StringEscapeUtils, Entities and UnhandledException, and let's see what happens :-)

> Reorganize dependencies in Velocity Engine Core
> -----------------------------------------------
>
>                 Key: VELOCITY-789
>                 URL: https://issues.apache.org/jira/browse/VELOCITY-789
>             Project: Velocity
>          Issue Type: Bug
>            Reporter: Antonio Petrelli
>            Assignee: Antonio Petrelli
>
> Currently Velocity Engine core depends on:
> Commons Lang
> Commons Collections
> Avalon LogKit
> Apache Jakarta ORO
> LogKit and ORO should be removed, as they are obsolete. Commons Lang and Collections should be replaced or shaded.

-- 
This message is automatically generated by JIRA.
-
You can reply to this email to add a comment to the issue online.


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


[jira] Commented: (VELOCITY-789) Reorganize dependencies in Velocity Engine Core

Posted by "Jarkko Viinamäki (JIRA)" <de...@velocity.apache.org>.
    [ https://issues.apache.org/jira/browse/VELOCITY-789?page=com.atlassian.jira.plugin.system.issuetabpanels:comment-tabpanel&focusedCommentId=12966852#action_12966852 ] 

Jarkko Viinamäki commented on VELOCITY-789:
-------------------------------------------

"Commons Lang and Collections should be replaced or shaded."

Why?

> Reorganize dependencies in Velocity Engine Core
> -----------------------------------------------
>
>                 Key: VELOCITY-789
>                 URL: https://issues.apache.org/jira/browse/VELOCITY-789
>             Project: Velocity
>          Issue Type: Bug
>            Reporter: Antonio Petrelli
>            Assignee: Antonio Petrelli
>
> Currently Velocity Engine core depends on:
> Commons Lang
> Commons Collections
> Avalon LogKit
> Apache Jakarta ORO
> LogKit and ORO should be removed, as they are obsolete. Commons Lang and Collections should be replaced or shaded.

-- 
This message is automatically generated by JIRA.
-
You can reply to this email to add a comment to the issue online.


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