[jira] [Commented] (GIRAPH-84) Simplify boolean expressions in BspRecordReader

2011-11-25 Thread Claudio Martella (Commented) (JIRA)

[ 
https://issues.apache.org/jira/browse/GIRAPH-84?page=com.atlassian.jira.plugin.system.issuetabpanels:comment-tabpanelfocusedCommentId=13157230#comment-13157230
 ] 

Claudio Martella commented on GIRAPH-84:


ok, thanks :)

 Simplify boolean expressions in BspRecordReader
 ---

 Key: GIRAPH-84
 URL: https://issues.apache.org/jira/browse/GIRAPH-84
 Project: Giraph
  Issue Type: Improvement
Reporter: Jakob Homan
Assignee: Shaunak Kashyap
  Labels: newbie
 Attachments: GIRAPH-84.diff


 Twice in BspRecordReader boolean expressions are evaluated with == and can be 
 simplified to just one liners or variable evaluation.

--
This message is automatically generated by JIRA.
If you think it was sent incorrectly, please contact your JIRA administrators: 
https://issues.apache.org/jira/secure/ContactAdministrators!default.jspa
For more information on JIRA, see: http://www.atlassian.com/software/jira




[jira] [Commented] (GIRAPH-84) Simplify boolean expressions in BspRecordReader

2011-11-25 Thread Claudio Martella (Commented) (JIRA)

[ 
https://issues.apache.org/jira/browse/GIRAPH-84?page=com.atlassian.jira.plugin.system.issuetabpanels:comment-tabpanelfocusedCommentId=13157233#comment-13157233
 ] 

Claudio Martella commented on GIRAPH-84:


+1 and commited. Thanks Shaunak.

 Simplify boolean expressions in BspRecordReader
 ---

 Key: GIRAPH-84
 URL: https://issues.apache.org/jira/browse/GIRAPH-84
 Project: Giraph
  Issue Type: Improvement
Reporter: Jakob Homan
Assignee: Shaunak Kashyap
  Labels: newbie
 Attachments: GIRAPH-84.diff


 Twice in BspRecordReader boolean expressions are evaluated with == and can be 
 simplified to just one liners or variable evaluation.

--
This message is automatically generated by JIRA.
If you think it was sent incorrectly, please contact your JIRA administrators: 
https://issues.apache.org/jira/secure/ContactAdministrators!default.jspa
For more information on JIRA, see: http://www.atlassian.com/software/jira




[jira] [Commented] (GIRAPH-84) Simplify boolean expressions in BspRecordReader

2011-11-25 Thread Hudson (Commented) (JIRA)

[ 
https://issues.apache.org/jira/browse/GIRAPH-84?page=com.atlassian.jira.plugin.system.issuetabpanels:comment-tabpanelfocusedCommentId=13157236#comment-13157236
 ] 

Hudson commented on GIRAPH-84:
--

Integrated in Giraph-trunk-Commit #43 (See 
[https://builds.apache.org/job/Giraph-trunk-Commit/43/])
GIRAPH-84: Simplify boolean expressions in BspRecordReader

claudio : 
http://svn.apache.org/viewcvs.cgi/?root=Apache-SVNview=revrev=1206252
Files : 
* /incubator/giraph/trunk/CHANGELOG
* 
/incubator/giraph/trunk/src/main/java/org/apache/giraph/bsp/BspRecordReader.java


 Simplify boolean expressions in BspRecordReader
 ---

 Key: GIRAPH-84
 URL: https://issues.apache.org/jira/browse/GIRAPH-84
 Project: Giraph
  Issue Type: Improvement
Reporter: Jakob Homan
Assignee: Shaunak Kashyap
  Labels: newbie
 Attachments: GIRAPH-84.diff


 Twice in BspRecordReader boolean expressions are evaluated with == and can be 
 simplified to just one liners or variable evaluation.

--
This message is automatically generated by JIRA.
If you think it was sent incorrectly, please contact your JIRA administrators: 
https://issues.apache.org/jira/secure/ContactAdministrators!default.jspa
For more information on JIRA, see: http://www.atlassian.com/software/jira




[jira] [Commented] (GIRAPH-84) Simplify boolean expressions in BspRecordReader

2011-11-21 Thread Shaunak Kashyap (Commented) (JIRA)

[ 
https://issues.apache.org/jira/browse/GIRAPH-84?page=com.atlassian.jira.plugin.system.issuetabpanels:comment-tabpanelfocusedCommentId=13154279#comment-13154279
 ] 

Shaunak Kashyap commented on GIRAPH-84:
---

Thanks, Claudio and Jakob. I will make the suggested changes and attach a patch 
to the JIRA.

 Simplify boolean expressions in BspRecordReader
 ---

 Key: GIRAPH-84
 URL: https://issues.apache.org/jira/browse/GIRAPH-84
 Project: Giraph
  Issue Type: Improvement
Reporter: Jakob Homan
Assignee: Shaunak Kashyap
  Labels: newbie

 Twice in BspRecordReader boolean expressions are evaluated with == and can be 
 simplified to just one liners or variable evaluation.

--
This message is automatically generated by JIRA.
If you think it was sent incorrectly, please contact your JIRA administrators: 
https://issues.apache.org/jira/secure/ContactAdministrators!default.jspa
For more information on JIRA, see: http://www.atlassian.com/software/jira




[jira] [Commented] (GIRAPH-84) Simplify boolean expressions in BspRecordReader

2011-11-20 Thread jirapos...@reviews.apache.org (Commented) (JIRA)

[ 
https://issues.apache.org/jira/browse/GIRAPH-84?page=com.atlassian.jira.plugin.system.issuetabpanels:comment-tabpanelfocusedCommentId=13153870#comment-13153870
 ] 

jirapos...@reviews.apache.org commented on GIRAPH-84:
-


---
This is an automatically generated e-mail. To reply, visit:
https://reviews.apache.org/r/2885/#review3375
---

Ship it!


Yep, looks good to me. Note to committers: how does it work in these 
situations? Shall I just commit this or should I +1 and wait for another one?

- Claudio


On 2011-11-20 02:40:35, shaunak wrote:
bq.  
bq.  ---
bq.  This is an automatically generated e-mail. To reply, visit:
bq.  https://reviews.apache.org/r/2885/
bq.  ---
bq.  
bq.  (Updated 2011-11-20 02:40:35)
bq.  
bq.  
bq.  Review request for giraph.
bq.  
bq.  
bq.  Summary
bq.  ---
bq.  
bq.  Simplifying boolean expression using ternary operation.
bq.  
bq.  
bq.  This addresses bug GIRAPH-84.
bq.  https://issues.apache.org/jira/browse/GIRAPH-84
bq.  
bq.  
bq.  Diffs
bq.  -
bq.  
bq.
http://svn.apache.org/repos/asf/incubator/giraph/trunk/src/main/java/org/apache/giraph/bsp/BspRecordReader.java
 1204113 
bq.  
bq.  Diff: https://reviews.apache.org/r/2885/diff
bq.  
bq.  
bq.  Testing
bq.  ---
bq.  
bq.  $ mvn test
bq.  
bq.  
bq.  Thanks,
bq.  
bq.  shaunak
bq.  
bq.



 Simplify boolean expressions in BspRecordReader
 ---

 Key: GIRAPH-84
 URL: https://issues.apache.org/jira/browse/GIRAPH-84
 Project: Giraph
  Issue Type: Improvement
Reporter: Jakob Homan
Assignee: Shaunak Kashyap
  Labels: newbie

 Twice in BspRecordReader boolean expressions are evaluated with == and can be 
 simplified to just one liners or variable evaluation.

--
This message is automatically generated by JIRA.
If you think it was sent incorrectly, please contact your JIRA administrators: 
https://issues.apache.org/jira/secure/ContactAdministrators!default.jspa
For more information on JIRA, see: http://www.atlassian.com/software/jira




[jira] [Commented] (GIRAPH-84) Simplify boolean expressions in BspRecordReader

2011-11-20 Thread Claudio Martella (Commented) (JIRA)

[ 
https://issues.apache.org/jira/browse/GIRAPH-84?page=com.atlassian.jira.plugin.system.issuetabpanels:comment-tabpanelfocusedCommentId=13153873#comment-13153873
 ] 

Claudio Martella commented on GIRAPH-84:


One more thing, the descriptions mentions two places where the expression could 
be simplified, you're missing the nextKeyValue() method. You may want to 
express it with something like:

return (seenRecord == false ? seenRecord = true : false);

Also, what about using a static final Text ONLY_KEY = Text(only key)? instead 
of creating multiple objects?

 Simplify boolean expressions in BspRecordReader
 ---

 Key: GIRAPH-84
 URL: https://issues.apache.org/jira/browse/GIRAPH-84
 Project: Giraph
  Issue Type: Improvement
Reporter: Jakob Homan
Assignee: Shaunak Kashyap
  Labels: newbie

 Twice in BspRecordReader boolean expressions are evaluated with == and can be 
 simplified to just one liners or variable evaluation.

--
This message is automatically generated by JIRA.
If you think it was sent incorrectly, please contact your JIRA administrators: 
https://issues.apache.org/jira/secure/ContactAdministrators!default.jspa
For more information on JIRA, see: http://www.atlassian.com/software/jira




[jira] [Commented] (GIRAPH-84) Simplify boolean expressions in BspRecordReader

2011-11-20 Thread Avery Ching (Commented) (JIRA)

[ 
https://issues.apache.org/jira/browse/GIRAPH-84?page=com.atlassian.jira.plugin.system.issuetabpanels:comment-tabpanelfocusedCommentId=13153927#comment-13153927
 ] 

Avery Ching commented on GIRAPH-84:
---

Claudio, once a committer +1's something they can commit it can commit on 
behalf of the submitter.  If it's another committer that submits, then 
typically, after the +1, the submitter will commit.

 Simplify boolean expressions in BspRecordReader
 ---

 Key: GIRAPH-84
 URL: https://issues.apache.org/jira/browse/GIRAPH-84
 Project: Giraph
  Issue Type: Improvement
Reporter: Jakob Homan
Assignee: Shaunak Kashyap
  Labels: newbie

 Twice in BspRecordReader boolean expressions are evaluated with == and can be 
 simplified to just one liners or variable evaluation.

--
This message is automatically generated by JIRA.
If you think it was sent incorrectly, please contact your JIRA administrators: 
https://issues.apache.org/jira/secure/ContactAdministrators!default.jspa
For more information on JIRA, see: http://www.atlassian.com/software/jira




Re: [jira] [Commented] (GIRAPH-84) Simplify boolean expressions in BspRecordReader

2011-11-20 Thread Claudio Martella
Ok.

What if the committer +1 (and commits it) to a submitter for a JIRA
filed by another committer?
I.e., is it politically incorrect to step into this JIRA opened by Jakob? :)

I know this is mind-twisting, but I prefer to ask than to finish up with dibs!




On Mon, Nov 21, 2011 at 1:55 AM, Avery Ching (Commented) (JIRA)
j...@apache.org wrote:

    [ 
 https://issues.apache.org/jira/browse/GIRAPH-84?page=com.atlassian.jira.plugin.system.issuetabpanels:comment-tabpanelfocusedCommentId=13153927#comment-13153927
  ]

 Avery Ching commented on GIRAPH-84:
 ---

 Claudio, once a committer +1's something they can commit it can commit on 
 behalf of the submitter.  If it's another committer that submits, then 
 typically, after the +1, the submitter will commit.

 Simplify boolean expressions in BspRecordReader
 ---

                 Key: GIRAPH-84
                 URL: https://issues.apache.org/jira/browse/GIRAPH-84
             Project: Giraph
          Issue Type: Improvement
            Reporter: Jakob Homan
            Assignee: Shaunak Kashyap
              Labels: newbie

 Twice in BspRecordReader boolean expressions are evaluated with == and can 
 be simplified to just one liners or variable evaluation.

 --
 This message is automatically generated by JIRA.
 If you think it was sent incorrectly, please contact your JIRA 
 administrators: 
 https://issues.apache.org/jira/secure/ContactAdministrators!default.jspa
 For more information on JIRA, see: http://www.atlassian.com/software/jira






-- 
   Claudio Martella
   claudio.marte...@gmail.com


[jira] [Commented] (GIRAPH-84) Simplify boolean expressions in BspRecordReader

2011-11-20 Thread Jakob Homan (Commented) (JIRA)

[ 
https://issues.apache.org/jira/browse/GIRAPH-84?page=com.atlassian.jira.plugin.system.issuetabpanels:comment-tabpanelfocusedCommentId=13153951#comment-13153951
 ] 

Jakob Homan commented on GIRAPH-84:
---

The patch *must* be attached to the JIRA.  We need the little icon that says 
the contributor has given it to Apache.  Reviewboard is optional; the patch 
should always be attached to the JIRA first.

 Simplify boolean expressions in BspRecordReader
 ---

 Key: GIRAPH-84
 URL: https://issues.apache.org/jira/browse/GIRAPH-84
 Project: Giraph
  Issue Type: Improvement
Reporter: Jakob Homan
Assignee: Shaunak Kashyap
  Labels: newbie

 Twice in BspRecordReader boolean expressions are evaluated with == and can be 
 simplified to just one liners or variable evaluation.

--
This message is automatically generated by JIRA.
If you think it was sent incorrectly, please contact your JIRA administrators: 
https://issues.apache.org/jira/secure/ContactAdministrators!default.jspa
For more information on JIRA, see: http://www.atlassian.com/software/jira




[jira] [Commented] (GIRAPH-84) Simplify boolean expressions in BspRecordReader

2011-11-19 Thread jirapos...@reviews.apache.org (Commented) (JIRA)

[ 
https://issues.apache.org/jira/browse/GIRAPH-84?page=com.atlassian.jira.plugin.system.issuetabpanels:comment-tabpanelfocusedCommentId=13153646#comment-13153646
 ] 

jirapos...@reviews.apache.org commented on GIRAPH-84:
-


---
This is an automatically generated e-mail. To reply, visit:
https://reviews.apache.org/r/2885/
---

Review request for giraph.


Summary
---

Simplifying boolean expression using ternary operation.


This addresses bug GIRAPH-84.
https://issues.apache.org/jira/browse/GIRAPH-84


Diffs
-

  
http://svn.apache.org/repos/asf/incubator/giraph/trunk/src/main/java/org/apache/giraph/bsp/BspRecordReader.java
 1204113 

Diff: https://reviews.apache.org/r/2885/diff


Testing
---

$ mvn test


Thanks,

shaunak



 Simplify boolean expressions in BspRecordReader
 ---

 Key: GIRAPH-84
 URL: https://issues.apache.org/jira/browse/GIRAPH-84
 Project: Giraph
  Issue Type: Improvement
Reporter: Jakob Homan
Assignee: Shaunak Kashyap
  Labels: newbie

 Twice in BspRecordReader boolean expressions are evaluated with == and can be 
 simplified to just one liners or variable evaluation.

--
This message is automatically generated by JIRA.
If you think it was sent incorrectly, please contact your JIRA administrators: 
https://issues.apache.org/jira/secure/ContactAdministrators!default.jspa
For more information on JIRA, see: http://www.atlassian.com/software/jira




[jira] [Commented] (GIRAPH-84) Simplify boolean expressions in BspRecordReader

2011-11-18 Thread Attila Csordas (Commented) (JIRA)

[ 
https://issues.apache.org/jira/browse/GIRAPH-84?page=com.atlassian.jira.plugin.system.issuetabpanels:comment-tabpanelfocusedCommentId=13153099#comment-13153099
 ] 

Attila Csordas commented on GIRAPH-84:
--

I reassigned the issue to Shaunak then, although I'm not sure what the 
convention is in these cases. Was good to learn on the ternary operator.

 Simplify boolean expressions in BspRecordReader
 ---

 Key: GIRAPH-84
 URL: https://issues.apache.org/jira/browse/GIRAPH-84
 Project: Giraph
  Issue Type: Improvement
Reporter: Jakob Homan
Assignee: Shaunak Kashyap
  Labels: newbie

 Twice in BspRecordReader boolean expressions are evaluated with == and can be 
 simplified to just one liners or variable evaluation.

--
This message is automatically generated by JIRA.
If you think it was sent incorrectly, please contact your JIRA administrators: 
https://issues.apache.org/jira/secure/ContactAdministrators!default.jspa
For more information on JIRA, see: http://www.atlassian.com/software/jira




[jira] [Commented] (GIRAPH-84) Simplify boolean expressions in BspRecordReader

2011-11-17 Thread Shaunak Kashyap (Commented) (JIRA)

[ 
https://issues.apache.org/jira/browse/GIRAPH-84?page=com.atlassian.jira.plugin.system.issuetabpanels:comment-tabpanelfocusedCommentId=13152469#comment-13152469
 ] 

Shaunak Kashyap commented on GIRAPH-84:
---

I believe that style goes against the coding conventions for this project (see 
http://svn.apache.org/repos/asf/incubator/giraph/trunk/CODE_CONVENTIONS).

I wonder if using the ternary operator like so is acceptable:

{code}
return (seenRecord ? 1f : 0f);
{code}

 Simplify boolean expressions in BspRecordReader
 ---

 Key: GIRAPH-84
 URL: https://issues.apache.org/jira/browse/GIRAPH-84
 Project: Giraph
  Issue Type: Improvement
Reporter: Jakob Homan
Assignee: Attila Csordas
  Labels: newbie

 Twice in BspRecordReader boolean expressions are evaluated with == and can be 
 simplified to just one liners or variable evaluation.

--
This message is automatically generated by JIRA.
If you think it was sent incorrectly, please contact your JIRA administrators: 
https://issues.apache.org/jira/secure/ContactAdministrators!default.jspa
For more information on JIRA, see: http://www.atlassian.com/software/jira




[jira] [Commented] (GIRAPH-84) Simplify boolean expressions in BspRecordReader

2011-11-17 Thread Avery Ching (Commented) (JIRA)

[ 
https://issues.apache.org/jira/browse/GIRAPH-84?page=com.atlassian.jira.plugin.system.issuetabpanels:comment-tabpanelfocusedCommentId=13152488#comment-13152488
 ] 

Avery Ching commented on GIRAPH-84:
---

ternary is fine with me.  I think we use it in the codebase.  We should 
probably add it to the coding conventions...unless someone objects.

 Simplify boolean expressions in BspRecordReader
 ---

 Key: GIRAPH-84
 URL: https://issues.apache.org/jira/browse/GIRAPH-84
 Project: Giraph
  Issue Type: Improvement
Reporter: Jakob Homan
Assignee: Attila Csordas
  Labels: newbie

 Twice in BspRecordReader boolean expressions are evaluated with == and can be 
 simplified to just one liners or variable evaluation.

--
This message is automatically generated by JIRA.
If you think it was sent incorrectly, please contact your JIRA administrators: 
https://issues.apache.org/jira/secure/ContactAdministrators!default.jspa
For more information on JIRA, see: http://www.atlassian.com/software/jira