[SERVER-12009] Broken Replication errors for getLastError Created: 09/Dec/13  Updated: 10/Dec/14  Resolved: 09/Dec/13

Status: Closed
Project: Core Server
Component/s: None
Affects Version/s: None
Fix Version/s: None

Type: Bug Priority: Major - P3
Reporter: Christian Amor Kvalheim Assignee: Unassigned
Resolution: Done Votes: 0
Labels: None
Remaining Estimate: Not Specified
Time Spent: Not Specified
Original Estimate: Not Specified
Environment:

single mongod --nojournal


Issue Links:
Related
is related to SERVER-12012 apply semantic write concern checks b... Closed
is related to SERVER-12184 Write Commands not behaving like new ... Closed
Operating System: ALL
Participants:

 Description   

In 2.4.3 and 2.5.4 a getLastError with

{j:true}

on a single mongod with nojournal produces.

{  n: 0,
  connectionId: 7,
  jnote: 'journaling not enabled on this server',
  err: 'nojournal',
  ok: 1 }

But on 2.5.5 nightly it produces

{  n: 0,
  connectionId: 7,
  writtenTo: null,
  err: 'nojournal',
  ok: 0,
  errmsg: 'journaling not enabled',
  code: 2 }



 Comments   
Comment by Eliot Horowitz (Inactive) [ 09/Dec/13 ]

No, the current behavior is correct.
This is not a WriteConcernError
This is different.

Comment by Christian Amor Kvalheim [ 09/Dec/13 ]

On ordered updates a replication error is not considered a failure to write just a failed write concern. Ordered bulks will continue until there is a non-replication error. For legacy ops we use jnote, wnote and wtimeout to recognize an error as being a write concern error and not an op error.

I think we are ok if the code is just changed to 64 instead of 2

Comment by Eliot Horowitz (Inactive) [ 09/Dec/13 ]

I do not see how this has anything at all to do with bulk api.

Comment by Christian Amor Kvalheim [ 09/Dec/13 ]

this will break the legacy support for bulk api

Comment by Eric Milkie [ 09/Dec/13 ]

This was changed as part of SERVER-11665. One of the server unit tests broke due to this change but I asked Eliot and the breaking change is intentional.

Comment by Eliot Horowitz (Inactive) [ 09/Dec/13 ]

See SERVER-11665 for a list of changes

Generated at Thu Feb 08 03:27:20 UTC 2024 using Jira 9.7.1#970001-sha1:2222b88b221c4928ef0de3161136cc90c8356a66.