jmx-dev Review: JDK-8003476 Cleanup warnings in com.sun.jmx.snmp code

Stuart Marks stuart.marks at oracle.com
Tue Nov 27 16:52:52 PST 2012


Hi, sorry for the delay, long holiday weekend here in the U.S.

The latest webrev looks good, just a couple comments on indentation. See below. 
No need to reissue a webrev after fixing these up.

I guess you can push this yourself.

Thanks,

s'marks

-------

SnmpMibTable.java, lines 1818, 1832 --

Adjust indentation so that second parameter lines up with open-parenthesis on 
the previous line.

SnmpAdaptorServer.java, lines 1345-1350, 2321 --

Maybe adjust indentation to line up with open-parenthesis, although this may 
make the lines too long. (Not that the code in this area respects any kind of 
width limit.) Use your judgment.

-------


On 11/21/12 6:15 AM, Daniel Fuchs wrote:
> Hi,
>
>
> Here is a revised webrev taking into account Stuart's comments.
>
> http://cr.openjdk.java.net/~dfuchs/JDK-8003476/webrev.01/
>
> I have identified further places where Object or <?> could be
> replaced with more specific types - which allowed me to get
> rid of yet more ugly casts.
>
> best regards,
>
> -- daniel
>
>
> On 11/20/12 11:15 AM, Daniel Fuchs wrote:
>> On 11/20/12 7:51 AM, Stuart Marks wrote:
>>> Well, they may be undocumented, but that doesn't mean that nobody
>>> depends on them. :-/
>>>
>>> I think these changes are all binary compatible, since the erasures of
>>> the new versions are all the same as the raw type.
>>>
>>> Source compatibility is a different issue. Actually it doesn't seem too
>>> bad. The old version returned a raw Enumeration, and the new version
>>> returns either an Enumeration<?> or Enumeration<SnmpMibSubRequest> or
>>> whatever. So callers will get a rawtypes warning when they recompile,
>>> but only if they enable the right -Xlint option.
>>>
>>> Given that the compatibility issues seem quite minor, and our assumption
>>> that it's unlikely that code outside the JDK uses these interfaces,
>>> these changes seem pretty safe.
>>>
>>> Sound reasonable?
>>
>> Yes - I will make the changes!
>>
>> -- daniel
>>
>>
>


More information about the jmx-dev mailing list