文章

Restlet2.1.6发布,修正ObjectRepresentation的构造函数问题

OneCoder在Restlet 2.1.4中 匪夷所思的ObjectRepresentation的构造函数中,提到过在使用2.1.4的时候遇到的异常

Exception in thread "main" java.lang.IllegalArgumentException : The serialized representation must have this media type: application/x-java-serialized-object or this one: application/x-java-serialized-object+xml
          at org.restlet.representation.ObjectRepresentation.<init>(ObjectRepresentation.java:203)
     at org.restlet.representation.ObjectRepresentation.<init>(ObjectRepresentation.java:114)

当时结果阅读代码,认为是Restlet的一个bug,并提交给Restlet。得到回复确认,称将在2.1.6版本中修复:

Hello,

thansk a lot for reporting this issue which is clearly a regression. I've added a ticket for that point: https://github.com/restlet/restlet-framework-java/issues/809
The fix will be part of the 2.1.6 release, available in a few minutes.

Best regards,
Thierry Boileau
 

今天想起,登录了一下Restlet的官方,发现最新版已经是2.1.6了。查看了一些change log,发现该问题确实已经解决。

===========
Changes log  
===========

- 2.1.6 (12/05/2013)
    - Bug fixed
       - Fixed issue #809 regression introduced when handling issues #774 and #778.

不过OneCoder还没有升级测试。大家可以测试一下。

 

本文由作者按照 CC BY 4.0 进行授权