[DOCS-14691] Detailed schema validation errors on v5: missing configuration details for local clusters Created: 28/Jul/21 Updated: 30/Oct/23 Resolved: 02/Aug/21 |
|
| Status: | Closed |
| Project: | Documentation |
| Component/s: | manual, Server |
| Affects Version/s: | 5.0.1 |
| Fix Version/s: | Server_Docs_20231030 |
| Type: | Improvement | Priority: | Major - P3 |
| Reporter: | Tomas Romero | Assignee: | Jeffrey Allen |
| Resolution: | Cannot Reproduce | Votes: | 0 |
| Labels: | None | ||
| Remaining Estimate: | Not Specified | ||
| Time Spent: | Not Specified | ||
| Original Estimate: | Not Specified | ||
| Attachments: |
|
| Participants: | |
| Days since reply: | 2 years, 27 weeks, 2 days ago |
| Epic Link: | DOCSP-15042 |
| Description |
|
The documentation is missing the required configuration for a local cluster with a default setup (.mongo.conf) to provide detailed schema validation errors. This is preventing us from using it on our local environments for development. We are trying to leverage MongoDB v5's detailed validation messages for schemas (as per described at https://docs.mongodb.com/manual/core/schema-validation/#behavior). To test it out, we are just copy/pasting the example on the cited link. And while it works on our Atlas cluster, it doesn't show the error details on our local development servers (using the same version of `mongod` and `mongosh`, 5.0.1 and 1.0.1 respectively). |
| Comments |
| Comment by Jeffrey Allen [ 02/Aug/21 ] | |||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||
|
Thanks for following up tomas@sulvo.com. I'm going to close this ticket as "Cannot Reproduce" given we can't reliably reproduce this issue. Cheers. | |||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||
| Comment by Tomas Romero [ 30/Jul/21 ] | |||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||
|
I got it working after cleaning up some old dependencies I had and re-installing v5 from scratch (I also deleted /var/lib/mongodb and /var/lib/mongodb before re-installing, just in case). This is a screenshot of the cleanup:
I was using v5 in my previous tests though, as shown in my previously shared screenshot: So it looks like some other old dependency of file was messing up just with this feature, while allowing normal operation in the rest. Thanks for the help! | |||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||
| Comment by Tomas Romero [ 30/Jul/21 ] | |||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||
|
Yes v4.4 (not sure about the patch number, but probably v4.4.6). | |||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||
| Comment by Jeffrey Allen [ 29/Jul/21 ] | |||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||
|
tomas@sulvo.com do you know what specific version of v4 you upgraded from? Was it v4.4? | |||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||
| Comment by Tomas Romero [ 29/Jul/21 ] | |||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||
|
Thanks again for the reply. After that I checked with 2 other devs and it works for them. I'm a bit puzzled. Could you ask if there is any possible misconfiguration when coming from v4? Both of us that have problems getting the correct output did upgrade from v4 to v5. Thanks! | |||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||
| Comment by Jeffrey Allen [ 29/Jul/21 ] | |||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||
|
This is... surprising. I'm running a local deployment on macOS Big Sur 11.3.1 with MongoDB 5.0.1, mongosh 1.0.3 and am unable to reproduce (I see the full validation explanation as expected). I'll attach a screenshot of what I observe. I can poke another team to help look into this because I'm not sure what's going on here. | |||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||
| Comment by Tomas Romero [ 29/Jul/21 ] | |||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||
|
Hi, thanks for the quick response. I didn't overlook any of the output: Just in case, a screenshot of the versions I'm using:
Something interesting is that both when using our Atlas cluster or a Docker image this works:
But it fails to work when using the 5.0.1 binary downloaded from https://www.mongodb.com/try/download/enterprise. I tested it on Ubuntu 20.04 and another dev on Mac Catalina 10.15.7. For both of us it works correctly when using the Atlas cluster with the same mongo version (5.0.1). | |||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||
| Comment by Jeffrey Allen [ 29/Jul/21 ] | |||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||
|
Hi tomas@sulvo.com , the examples on the page based on our testing work on both local clusters and Atlas. It's possible that the confusion is happening because when you are running the following commands in order: 1.
2.
3.
The last piece of the output is:
However, looking at the entire output, the shell shows:
If it would be clearer to see the output of each update command separately, we can consider update the documentation accordingly if you think it would be helpful. |