[jira] [Updated] (RATIS-394) Remove the assertion while setting the exception in TransactionContextImpl

2018-11-06 Thread Tsz Wo Nicholas Sze (JIRA)


 [ 
https://issues.apache.org/jira/browse/RATIS-394?page=com.atlassian.jira.plugin.system.issuetabpanels:all-tabpanel
 ]

Tsz Wo Nicholas Sze updated RATIS-394:
--
Component/s: server
 Issue Type: Bug  (was: Improvement)

+1 the patch looks good.

> Remove the assertion while setting the exception in TransactionContextImpl
> --
>
> Key: RATIS-394
> URL: https://issues.apache.org/jira/browse/RATIS-394
> Project: Ratis
>  Issue Type: Bug
>  Components: server
>Reporter: Shashikant Banerjee
>Assignee: Shashikant Banerjee
>Priority: Major
> Fix For: 0.3.0
>
> Attachments: RATIS-394.000.patch
>
>
> In the below code in TransactionContextImpl,
> {code:java}
> @Override
> public TransactionContext setException(Exception ioe) {
>   assert exception != null;
>   this.exception = ioe;
>   return this;
> }
> {code}
> While setting the exception it asserts based on the exception maintained in 
> the object is not null or not. While setting the exception first time, it 
> will be null always and hence asserts. We should relax the check here.



--
This message was sent by Atlassian JIRA
(v7.6.3#76005)


[jira] [Updated] (RATIS-394) Remove the assertion while setting the exception in TransactionContextImpl

2018-11-06 Thread Shashikant Banerjee (JIRA)


 [ 
https://issues.apache.org/jira/browse/RATIS-394?page=com.atlassian.jira.plugin.system.issuetabpanels:all-tabpanel
 ]

Shashikant Banerjee updated RATIS-394:
--
Description: 
In the below code in TransactionContextImpl,
{code:java}
@Override
public TransactionContext setException(Exception ioe) {
  assert exception != null;
  this.exception = ioe;
  return this;
}
{code}
While setting the exception it asserts based on the exception maintained in the 
object is not null or not. While setting the exception first time, it will be 
null always and hence asserts. We should relax the check here.

  was:
In the below code in TransactionContextImpl,
{code:java}
@Override
public TransactionContext setException(Exception ioe) {
  assert exception != null;
  this.exception = ioe;
  return this;
}
{code}
While setting the exception it asserts the exception maintained in the object 
is not null or not. While setting the exception first time, it will be null 
always and hence asserts. We should relax the check here.


> Remove the assertion while setting the exception in TransactionContextImpl
> --
>
> Key: RATIS-394
> URL: https://issues.apache.org/jira/browse/RATIS-394
> Project: Ratis
>  Issue Type: Improvement
>Reporter: Shashikant Banerjee
>Assignee: Shashikant Banerjee
>Priority: Major
> Fix For: 0.3.0
>
> Attachments: RATIS-394.000.patch
>
>
> In the below code in TransactionContextImpl,
> {code:java}
> @Override
> public TransactionContext setException(Exception ioe) {
>   assert exception != null;
>   this.exception = ioe;
>   return this;
> }
> {code}
> While setting the exception it asserts based on the exception maintained in 
> the object is not null or not. While setting the exception first time, it 
> will be null always and hence asserts. We should relax the check here.



--
This message was sent by Atlassian JIRA
(v7.6.3#76005)


[jira] [Updated] (RATIS-394) Remove the assertion while setting the exception in TransactionContextImpl

2018-11-06 Thread Shashikant Banerjee (JIRA)


 [ 
https://issues.apache.org/jira/browse/RATIS-394?page=com.atlassian.jira.plugin.system.issuetabpanels:all-tabpanel
 ]

Shashikant Banerjee updated RATIS-394:
--
Attachment: RATIS-394.000.patch

> Remove the assertion while setting the exception in TransactionContextImpl
> --
>
> Key: RATIS-394
> URL: https://issues.apache.org/jira/browse/RATIS-394
> Project: Ratis
>  Issue Type: Improvement
>Reporter: Shashikant Banerjee
>Assignee: Shashikant Banerjee
>Priority: Major
> Fix For: 0.3.0
>
> Attachments: RATIS-394.000.patch
>
>
> In the below code in TransactionContextImpl,
> {code:java}
> @Override
> public TransactionContext setException(Exception ioe) {
>   assert exception != null;
>   this.exception = ioe;
>   return this;
> }
> {code}
> While setting the exception it asserts the exception maintained in the object 
> is not null or not. While setting the exception first time, it will be null 
> always and hence asserts. We should relax the check here.



--
This message was sent by Atlassian JIRA
(v7.6.3#76005)


[jira] [Updated] (RATIS-394) Remove the assertion while setting the exception in TransactionContextImpl

2018-11-06 Thread Shashikant Banerjee (JIRA)


 [ 
https://issues.apache.org/jira/browse/RATIS-394?page=com.atlassian.jira.plugin.system.issuetabpanels:all-tabpanel
 ]

Shashikant Banerjee updated RATIS-394:
--
Description: 
In the below code in TransactionContextImpl,
{code:java}
@Override
public TransactionContext setException(Exception ioe) {
  assert exception != null;
  this.exception = ioe;
  return this;
}
{code}
While setting the exception it asserts the exception maintained in the object 
is not null or not. While setting the exception first time, it will be null 
always and hence asserts. We should relax the check here.

  was:
In the below code in TransactionContaextImpl,
{code:java}
@Override
public TransactionContext setException(Exception ioe) {
  assert exception != null;
  this.exception = ioe;
  return this;
}
{code}
While setting the exception it asserts the exception maintained in the object 
is not null or not. While setting the exception first time, it will be null 
always and hence asserts. We should relax the check here.


> Remove the assertion while setting the exception in TransactionContextImpl
> --
>
> Key: RATIS-394
> URL: https://issues.apache.org/jira/browse/RATIS-394
> Project: Ratis
>  Issue Type: Improvement
>Reporter: Shashikant Banerjee
>Assignee: Shashikant Banerjee
>Priority: Major
> Fix For: 0.3.0
>
>
> In the below code in TransactionContextImpl,
> {code:java}
> @Override
> public TransactionContext setException(Exception ioe) {
>   assert exception != null;
>   this.exception = ioe;
>   return this;
> }
> {code}
> While setting the exception it asserts the exception maintained in the object 
> is not null or not. While setting the exception first time, it will be null 
> always and hence asserts. We should relax the check here.



--
This message was sent by Atlassian JIRA
(v7.6.3#76005)