Return-Path: Delivered-To: apmail-ws-axis-dev-archive@www.apache.org Received: (qmail 71486 invoked from network); 18 Jun 2009 05:25:19 -0000 Received: from hermes.apache.org (HELO mail.apache.org) (140.211.11.3) by minotaur.apache.org with SMTP; 18 Jun 2009 05:25:19 -0000 Received: (qmail 3419 invoked by uid 500); 18 Jun 2009 05:25:29 -0000 Delivered-To: apmail-ws-axis-dev-archive@ws.apache.org Received: (qmail 3341 invoked by uid 500); 18 Jun 2009 05:25:29 -0000 Mailing-List: contact axis-dev-help@ws.apache.org; run by ezmlm Precedence: bulk Reply-To: axis-dev@ws.apache.org list-help: list-unsubscribe: List-Post: List-Id: Delivered-To: mailing list axis-dev@ws.apache.org Received: (qmail 3332 invoked by uid 99); 18 Jun 2009 05:25:29 -0000 Received: from athena.apache.org (HELO athena.apache.org) (140.211.11.136) by apache.org (qpsmtpd/0.29) with ESMTP; Thu, 18 Jun 2009 05:25:29 +0000 X-ASF-Spam-Status: No, hits=-2000.0 required=10.0 tests=ALL_TRUSTED X-Spam-Check-By: apache.org Received: from [140.211.11.140] (HELO brutus.apache.org) (140.211.11.140) by apache.org (qpsmtpd/0.29) with ESMTP; Thu, 18 Jun 2009 05:25:27 +0000 Received: from brutus (localhost [127.0.0.1]) by brutus.apache.org (Postfix) with ESMTP id 58B53234C051 for ; Wed, 17 Jun 2009 22:25:07 -0700 (PDT) Message-ID: <1921287528.1245302707362.JavaMail.jira@brutus> Date: Wed, 17 Jun 2009 22:25:07 -0700 (PDT) From: "Amila Chinthaka Suriarachchi (JIRA)" To: axis-dev@ws.apache.org Subject: [jira] Commented: (AXIS2-4099) ConverterUtil.convertToDateTime() is to lenient In-Reply-To: <818506625.1225109324282.JavaMail.jira@brutus> MIME-Version: 1.0 Content-Type: text/plain; charset=utf-8 Content-Transfer-Encoding: 7bit X-JIRA-FingerPrint: 30527f35849b9dde25b450d4833f0394 X-Virus-Checked: Checked by ClamAV on apache.org [ https://issues.apache.org/jira/browse/AXIS2-4099?page=com.atlassian.jira.plugin.system.issuetabpanels:comment-tabpanel&focusedCommentId=12721071#action_12721071 ] Amila Chinthaka Suriarachchi commented on AXIS2-4099: ----------------------------------------------------- public static void main(String[] args) { System.out.println("date ==> " + ConverterUtil.convertToDate("2009-06-17-05:00")); System.out.println("date ==> " + ConverterUtil.convertToDate("2009-06-17-06:00")); } I ran with the above code and which worked fine with my jvm. java version "1.6.0_13" Java(TM) SE Runtime Environment (build 1.6.0_13-b03) Java HotSpot(TM) 64-Bit Server VM (build 11.3-b02, mixed mode) > ConverterUtil.convertToDateTime() is to lenient > ----------------------------------------------- > > Key: AXIS2-4099 > URL: https://issues.apache.org/jira/browse/AXIS2-4099 > Project: Axis 2.0 (Axis2) > Issue Type: Bug > Components: adb > Affects Versions: 1.4.1, 1.4, 1.3 > Reporter: Marcel Ammerlaan > Priority: Minor > Attachments: DateTimeBug.java > > > When parsing an invalid date (as specified by the XSD Schema specification), Axis relies on the java.util.Calendar leniency to parse. E.g. 2008-02-31 (31st of februari) is invalid according to http://www.w3.org/TR/xmlschema-2/#dateTime. convertToDateTime() returns the 2nd of march instead. > This can be easily solved by setting the Calender leniency to false (setLenient(false)). -- This message is automatically generated by JIRA. - You can reply to this email to add a comment to the issue online.