camel-issues mailing list archives

Site index · List index
Message view « Date » · « Thread »
Top « Date » · « Thread »
From "Babak Vahdat (Issue Comment Edited) (JIRA)" <j...@apache.org>
Subject [jira] [Issue Comment Edited] (CAMEL-4899) Code Clean-Up (continued)
Date Mon, 16 Jan 2012 00:45:39 GMT

    [ https://issues.apache.org/jira/browse/CAMEL-4899?page=com.atlassian.jira.plugin.system.issuetabpanels:comment-tabpanel&focusedCommentId=13186603#comment-13186603
] 

Babak Vahdat edited comment on CAMEL-4899 at 1/16/12 12:44 AM:
---------------------------------------------------------------

Attached the patch concerning "remove unused" with some extra sugar concerning:

- removal of the deprecated API usages (and corresponding SuppressWarning("deprecated")) in
bunch of the places like:

{code}
replace the deprecated constructor org.apache.camel.component.mock.MockEndpoint() usage with
getMockEndpoint() API
javax.jcr.Node.getIdentifier() usage instead of javax.jcr.Node.getUUID()
javax.jcr.Session.getNodeByIdentifier() usage instead of javax.jcr.Session.getNodeByUUID()
org.jivesoftware.smack.XMPPConnection.addPacketSendingListener() usage instead of org.jivesoftware.smack.XMPPConnection.addPacketWriterListener()
{code}

- still removal of some unnecessary casts
- still removal of some unused imports

Note: at the first glance the change made by

{code}
org.apache.camel.component.mina2.Mina2Consumer
{code}

could seem that as if the removal of the fields

{code}
- noReplyLogger
- acceptorConfig
- sync
{code}

would be "too much" however looking deeply into it I found out that all those member variables
are *unused* or their usage-chain in the class itself were again *unused*.

Note: unfortunately with or without the attached path there're failed unit-tests by:


{code}
- camel-hazelcast
- camel-mina2
{code}

                
      was (Author: bvahdat):
    Attached the patch concerning "remove unused" with some extra sugar concerning:

- removal of the deprecated API usages (and corresponding SuppressWarning("deprecated")) in
bunch of the places like the API's:

{code}
new org.apache.camel.component.mock.MockEndpoint("mock:foo")
getIdentifier() method usage instead of getUUID() by javax.jcr.Node
getNodeByIdentifier() method usage instead of getNodeByUUID() by javax.jcr.Session
{code}

- still removal of some unnecessary casts
- still removal of some unused imports

Note: at the first glance the change made for

{code}
org.apache.camel.component.mina2.Mina2Consumer
{code}

could seem that as if the removal of the fields

{code}
- noReplyLogger
- acceptorConfig
- sync
{code}

would be "too much" however looking deeply into it I found out that all those member variables
are *unused* or their usage-chain in the class itself were again *unused*.
                  
> Code Clean-Up (continued)
> -------------------------
>
>                 Key: CAMEL-4899
>                 URL: https://issues.apache.org/jira/browse/CAMEL-4899
>             Project: Camel
>          Issue Type: Improvement
>    Affects Versions: 2.8.3
>            Reporter: Babak Vahdat
>            Assignee: Babak Vahdat
>             Fix For: 2.9.1, 2.10.0
>
>         Attachments: CAMEL-4899-remove-unused.patch
>
>
> As Hadrian has already proposed by CAMEL-4796 this ticket has been created as it's continuation.
The remaing tasks are therewith
> - Removal of unused private memebers: Types, Constructors, Fields and Methods where applicable
> - Remove the trailing whitespace on all lines, even on the empty ones

--
This message is automatically generated by JIRA.
If you think it was sent incorrectly, please contact your JIRA administrators: https://issues.apache.org/jira/secure/ContactAdministrators!default.jspa
For more information on JIRA, see: http://www.atlassian.com/software/jira

        

Mime
View raw message