Personal Career Portfolio Schema Design

Hello, all. I am a recent graduate of a web development program at a local college. I am working on building my personal career portfolio, and have decided to use MongoDB for my database (Overall, I plan on using MERN stack to build my portfolio). I have been trying to figure out how to model my data, but I have run into a bit of a problem.

I have different types of data where some of them contain (and will only ever contain) one item, but others that can include any number of items. I was wondering how to handle modeling data where the number of items in some sets of data may be capped, but other sets may not be capped.

The different types of data I have are:

  • Personal Summary
  • Skills Summary
  • Education
  • Work Experiences
  • Work Samples
  • Work Sample Categories

The personal summary and the skills summary are two types of data that are capped at one item only.

I have include below a script with some testing data as an example of how my schema is currently designed.

//Setting up the summaries collection.
db.summaries.drop();
db.summaries.insertOne({
    "personal": "Hello, I am junior web developer. I am currently working for employment."
    "skills": [
        {
            "label": "Programming",
            "skillStatements": [
                {
                    "statement": "Designed and develop dynamic web applications, and with friendly user interfaces by utilizing JavaScript, HTML, and CSS",
                    "keywords": [
                        "JavaScript",
                        "HTML",
                        "CSS"
                    ]
                },
                {
                    "statement": "Created web servers, learned how to use applications, and learned how to use command lines on Windows and Linux operating systems",
                    "keywords": [
                        "Windows",
                        "Linux"
                    ]
                }
            ]
        },
        {
            "label": "Documentation",
            "skillStatements": [
                {
                    "statement": "Created numerous professional documents for various college assignments and reports by utilizing Microsoft Word, Excel, and Access",
                    "keywords": [
                        "Microsoft",
                        "Word",
                        "Excel",
                        "Access"
                    ]
                },
                {
                    "statement": "Researched and presented numerous, well received presentations.",
                    "keywords": [
                        "presentations"
                    ]
                }
            ]
        }
    ]
});
//Setting up the education collection.
db.education.drop();
db.education.insertMany([
    {
        "programName": "Web Dev",
        "programLevel": "Diploma",
        "insitutionName": "Web College",
        "institutionLocation": "Ottawa, Ontario, Canada",
        "institutionWebsite": "",
        "startYear": 2018,
        "isActive": false,
        "endYear": 2021,
        "description": "I took this program to learn about how to be a programmer/developer, with a focus on web programming/development.",
        "artifacts": [
            {
                "label": "Web Dev Diploma",
                "document": {
                    "fileName": "Web Dev Diploma.pdf",
                    "mimeType": "application/pdf",
                    "alt": "My Web Dev Diploma."
                }
                
            }
        ]
    }
]);
//Setting up the work experiences collection.
db.workExperiences.drop();
db.workExperiences.insertMany([
    {
        "jobTitle": "Junior Programmer (QA Team)",
        "organizationName": "Communications Inc.",
        "organizationLocation": "Ottawa, Ontario, Canada",
        "organizationWebsite": "",
        "startMonth": 11,
        "startYear": 2021,
        "isActive": false,
        "endMonth": 1,
        "endYear": 2022,
        "tasks": [
            "Help to test new features and bug fixes",
            "Submit bug reports when I found bugs"
        ],
        "description": "I worked at Communications Inc. from late 2021 to early 2022 as my first job after graduating from the Web Dev program. I worked with a great team, and was able to put my skills and knowledge into practice, and also learn even more new skills.",
        "artifacts": []
    }
]);
//Setting up the work samples collection.
db.workSamples.drop();
db.workSamples.insertMany([
    {
        "title": "Weather Web App",
        "subtitle": "Learning how to use APIs",
        "sampleImage": {
            "fileName": "Weather Web App Thumbnail.jpeg",
            "mimeType": "image/jpeg",
            "alt": "An image showing my weather web app in action."
        },
        "categories": [
            {
                "name": "Web Dev",
                "description": "This group of work samples are all work samples that I completed during the course of my time in the Web Dev program."
            }
        ],
        "completionMonth": 3,
        "completionYear": 2021,
        "description": "This is a project I completed in my Web Dev program when learning how to develop client side apps. This work sample makes use of the Open Weather Map API (https://openweathermap.org/api).",
        "resources": [
            "HTML",
            "JavaScript",
            "Sass",
            "Node.js"
        ],
        "archive": false,
        "artifacts": [
            {
                "label": "Check my weather web app in action!",
                "link": ""
            }
        ]
    }
]);
//Setting up the work sample categories collection.
db.workSamplesCategories.drop();
db.workSamplesCategories.insertMany([
    {
        "name": "Web Dev",
        "description": "This group of work samples are all work samples that I completed during the course of my time in the Web Dev program."     
    },
    {
        "name": "Web App",
        "description": "This group of work samples are all work samples that are web apps."
    }
]);

I was thinking of having the summaries be included in their own collection, and that collection be limited to read and update actions only.

Another potential solution I thought of was placing everything, except for the work sample categories into a collection called “entries”, and give each a document a type - such as “Education”, or “Personal Summary”. Then I could gather all the documents in my node.js server by their type. However, I was concerned about about if keeping the names for each type as a constant in my server, and finding the documents using them would be considered bad practice or not.

If anyone has any thoughts or advice about my potential solutions, and/or how to approach this problem, I would be very appreciative.