[SERVER-26267] Creating a view named system.indexes causes secondary to fassert Created: 23/Sep/16  Updated: 02/Dec/16  Resolved: 28/Sep/16

Status: Closed
Project: Core Server
Component/s: Querying
Affects Version/s: None
Fix Version/s: 3.4.0-rc0

Type: Bug Priority: Major - P3
Reporter: Eddie Louie Assignee: Kyle Suarez
Resolution: Done Votes: 0
Labels: read-only-views
Remaining Estimate: Not Specified
Time Spent: Not Specified
Original Estimate: Not Specified

Issue Links:
Depends
Documented
is documented by DOCS-9469 Docs for SERVER-26267: Creating a vie... Closed
Backwards Compatibility: Fully Compatible
Operating System: ALL
Steps To Reproduce:

python buildscripts/resmoke.py --executor=jstestfuzz_replication --storageEngine=wiredTiger repro.js

Note: Does not repro with storage engine mmapv1.

repro.js

assert.commandWorked(db.runCommand({"create" : "system.indexes", "viewOn" : "collection", "pipeline" : []}));
assert.commandWorked(db.runCommand({createIndexes : "testAllGeo", indexes: [ {key: {a : "text"}, name : "a_text"}]}));

Sprint: Integration 2016-10-10
Participants:
Linked BF Score: 0

 Description   

Log out from secondary:

[ReplicaSetFixture:job0:secondary] 2016-09-23T01:15:52.803+0000 D -        [repl writer worker 13] User Assertion: 166:applyOps not supported on view: test.system.indexes src/mongo/db/repl/oplog.cpp 698
[ReplicaSetFixture:job0:secondary] 2016-09-23T01:15:52.803+0000 F REPL     [repl writer worker 13] writer worker caught exception: 166 applyOps not supported on view: test.system.indexes on: { ts: Timestamp 1474593351000|6, t: 1, h: 5771349231772129373, v: 2, op: "i", ns: "test.system.indexes", o: { v: 2, key: { _fts: "text", _ftsx: 1 }, name: "a_text", ns: "test.testAllGeo", weights: { a: 1 }, default_language: "english", language_override: "language", textIndexVersion: 3 } }
[ReplicaSetFixture:job0:secondary] 2016-09-23T01:15:52.803+0000 I -        [repl writer worker 13] Fatal assertion 16359 CommandNotSupportedOnView: applyOps not supported on view: test.system.indexes at src/mongo/db/repl/sync_tail.cpp 1042
[ReplicaSetFixture:job0:secondary] 2016-09-23T01:15:52.803+0000 I -        [repl writer worker 13]
[ReplicaSetFixture:job0:secondary] 
[ReplicaSetFixture:job0:secondary] ***aborting after fassert() failure
[ReplicaSetFixture:job0:secondary] 



 Comments   
Comment by Kyle Suarez [ 28/Sep/16 ]

I'm marking documentation changes as possibly "Needed", if it's worth mentioning in the docs that you cannot create a view that starts with "system." (that is, the word "system" followed by a period).

Comment by Githook User [ 28/Sep/16 ]

Author:

{u'username': u'ksuarz', u'name': u'Kyle Suarez', u'email': u'kyle.suarez@mongodb.com'}

Message: SERVER-26267 forbid creating views starting with 'system.'
Branch: master
https://github.com/mongodb/mongo/commit/998343374c0351bc7b903ea704c1ac7bbdd12c46

Generated at Thu Feb 08 04:11:36 UTC 2024 using Jira 9.7.1#970001-sha1:2222b88b221c4928ef0de3161136cc90c8356a66.