[Mifos-developer] False Alarm Build # 830

0 views
Skip to first unread message

Udai Gupta

unread,
Feb 19, 2010, 1:48:39 PM2/19/10
to Developer
Hi Guys,

We got a strange failure at Build # 830, I also saw this test failure
a few times in past and rerunning the build makes it go away. Right
now we might not look what is the reason of this failure. But it will
be good to know what causes this failure to trigger

junit.framework.AssertionFailedError: expected:<1> but was:<0>
       at junit.framework.Assert.fail(Assert.java:47)
       at junit.framework.Assert.failNotEquals(Assert.java:277)
       at junit.framework.Assert.assertEquals(Assert.java:64)
       at junit.framework.Assert.assertEquals(Assert.java:195)
       at junit.framework.Assert.assertEquals(Assert.java:201)
       at org.mifos.application.login.struts.action.LoginActionStrutsTest.testUpdatePassword(LoginActionStrutsTest.java:179)

Just wanted to keep track of this, so that if this occurs again we at
least know when did it happened last time.

Udai

------------------------------------------------------------------------------
Download Intel&#174; Parallel Studio Eval
Try the new software tools for yourself. Speed compiling, find bugs
proactively, and fine-tune applications for parallel performance.
See why Intel Parallel Studio got high marks during beta.
http://p.sf.net/sfu/intel-sw-dev

John Woodlock

unread,
Feb 21, 2010, 8:58:41 PM2/21/10
to Mifos software development
Udai,

I got it too.


The reason didn't spring out at me from the code so I just reran the build.

John

Jakub Sławiński

unread,
Mar 9, 2010, 5:43:29 AM3/9/10
to Mifos software development

Hi,

the reason of this failure is that encryptedPassword from Personnel is
logged in the AuditLog:

org.hibernate.impl.SessionImpl, ?, ?, ?, exception in interceptor
afterTransactionCompletion()
java.lang.RuntimeException:
org.hibernate.exception.GenericJDBCException: could not insert:
[org.mifos.framework.components.audit.business.AuditLogRecord]
...
Caused by: org.hibernate.exception.GenericJDBCException: could not
insert: [org.mifos.framework.components.audit.business.AuditLogRecord]
...
Caused by: java.sql.SQLException: Incorrect string value:
'\xF2\xBB\xAC\x90' for column 'NEW_VALUE' at row 1


I can see at least two solutions:
* do not log this property
* do not log encryptedPassword content as-is (log the change, but use
something like 'xxx' instead real content)

Any preferences?


Yours sincerely,
Jakub.

> Hi Guys,
>
> We got a strange failure at Build # 830, I also saw this test failure
> a few times in past and rerunning the build makes it go away. Right
> now we might not look what is the reason of this failure. But it will
> be good to know what causes this failure to trigger
>
> junit.framework.AssertionFailedError: expected:<1> but was:<0>
> at junit.framework.Assert.fail(Assert.java:47)
> at junit.framework.Assert.failNotEquals(Assert.java:277)
> at junit.framework.Assert.assertEquals(Assert.java:64)
> at junit.framework.Assert.assertEquals(Assert.java:195)
> at junit.framework.Assert.assertEquals(Assert.java:201)
> at org.mifos.application.login.struts.action.LoginActionStrutsTest.testUpdatePassword(LoginActionStrutsTest.java:179)
>
> Just wanted to keep track of this, so that if this occurs again we at
> least know when did it happened last time.
>
> Udai
>
>

--
Jakub Sławiński
SolDevelo
Gdynia, Poland.

John Woodlock

unread,
Mar 9, 2010, 6:13:47 AM3/9/10
to Mifos software development
Hi Jakub,

Glad you found out the reason.

I'd be happy if it wasn't logged. 

Maybe you could do that and if anyone else feels differently they could say what they want.

John 

2010/3/9 Jakub Sławiński <jslaw...@soldevelo.com>

Udai Gupta

unread,
Mar 9, 2010, 8:21:57 AM3/9/10
to Mifos software development
Hey Jakub,

I agree with you and John.

It would be great to see it fixed.

Udai

Van Mittal-Henkle

unread,
Mar 9, 2010, 11:33:30 AM3/9/10
to Mifos software development

My guess is that we would want an audit log entry saying that the password was changed but that we don't want to say what it was changed to.  But this is really a functional question so…

 

Kay, can you confirm what the behavior should be here?

 

--Van

----

Van Mittal-Henkle

Mifos Software Developer

Grameen Foundation

va...@grameenfoundation.org

Kay Chau

unread,
Mar 9, 2010, 12:48:22 PM3/9/10
to Van Mittal-Henkle, Mifos software development

That is right

 

We want to continue logging that the password change happened.  I don’t think there’s a need to save what the password changed to in the change log itself.

 

So this option sounds right to me Jakub:

 

 * do not log encryptedPassword content as-is (log the change, but use
something like 'xxx' instead real content)

 

In the Mifos UI, I want to continue to see the following in the change log

 

Date          Field         OldValue NewValue  User

07/12/2009 Password ******** ********    mifos

 

But in the back end, we can just log the change and not save the password value.

 

Hope I cleared that up J

 

Kay

Jakub Sławiński

unread,
Mar 9, 2010, 3:01:51 PM3/9/10
to Mifos software development

OK,

I have fixed this in r16920.


Yours sincerely,
Jakub.


> That is right
>
>
>
> We want to continue logging that the password change happened. I
> don’t think there’s a need to save what the password changed to in the
> change log itself.
>
>
>
> So this option sounds right to me Jakub:
>
>
>
> * do not log encryptedPassword content as-is (log the change, but use
> something like 'xxx' instead real content)
>
>
>
> In the Mifos UI, I want to continue to see the following in the change
> log
>
>
>

> *Date Field OldValue NewValue User*


>
> 07/12/2009 Password ******** ******** mifos
>
>
>
> But in the back end, we can just log the change and not save the
> password value.
>
>
>
> Hope I cleared that up J
>
>
>
> Kay
>
>
>

> *From:* Van Mittal-Henkle
> *Sent:* Tuesday, March 09, 2010 8:34 AM
> *To:* Mifos software development
> *Cc:* Kay Chau
> *Subject:* RE: [Mifos-developer] False Alarm Build # 830


>
>
>
> My guess is that we would want an audit log entry saying that the
> password was changed but that we don't want to say what it was changed
> to. But this is really a functional question so…
>
>
>
> Kay, can you confirm what the behavior should be here?
>
>
>
> --Van
>
> ----
>
> Van Mittal-Henkle
>
> Mifos Software Developer
>
> Grameen Foundation
>

> va...@grameenfoundation.org <mailto:va...@grameenfoundation.org>
>
>
>
> *From:* John Woodlock [mailto:john.w...@gmail.com]
> *Sent:* Tuesday, March 09, 2010 3:14 AM
> *To:* Mifos software development
> *Subject:* Re: [Mifos-developer] False Alarm Build # 830


>
>
>
> Hi Jakub,
>
>
>
> Glad you found out the reason.
>
>
>
> I'd be happy if it wasn't logged.
>
>
>
> Maybe you could do that and if anyone else feels differently they
> could say what they want.
>
>
>
> John
>
> 2010/3/9 Jakub Sławiński <jslaw...@soldevelo.com

> <mailto:jslaw...@soldevelo.com>>


>
>
> Hi,
>
> the reason of this failure is that encryptedPassword from Personnel is
> logged in the AuditLog:
>
> org.hibernate.impl.SessionImpl, ?, ?, ?, exception in interceptor
> afterTransactionCompletion()
> java.lang.RuntimeException:
> org.hibernate.exception.GenericJDBCException: could not insert:
> [org.mifos.framework.components.audit.business.AuditLogRecord]
> ...
> Caused by: org.hibernate.exception.GenericJDBCException: could not
> insert: [org.mifos.framework.components.audit.business.AuditLogRecord]
> ...
> Caused by: java.sql.SQLException: Incorrect string value:
> '\xF2\xBB\xAC\x90' for column 'NEW_VALUE' at row 1
>
>
> I can see at least two solutions:
> * do not log this property
> * do not log encryptedPassword content as-is (log the change, but use
> something like 'xxx' instead real content)
>
> Any preferences?
>
>
> Yours sincerely,
> Jakub.
>
>
>

> ------------------------------------------------------------------------

Reply all
Reply to author
Forward
0 new messages