Sign Up

Sign Up to our social questions and Answers Engine to ask questions, answer people’s questions, and connect with other people.

Have an account? Sign In

Have an account? Sign In Now

Sign In

Login to our social questions & Answers Engine to ask questions answer people’s questions & connect with other people.

Sign Up Here

Forgot Password?

Don't have account, Sign Up Here

Forgot Password

Lost your password? Please enter your email address. You will receive a link and will create a new password via email.

Have an account? Sign In Now

You must login to ask a question.

Forgot Password?

Need An Account, Sign Up Here

Please briefly explain why you feel this question should be reported.

Please briefly explain why you feel this answer should be reported.

Please briefly explain why you feel this user should be reported.

Sign InSign Up

The Archive Base

The Archive Base Logo The Archive Base Logo

The Archive Base Navigation

  • SEARCH
  • Home
  • About Us
  • Blog
  • Contact Us
Search
Ask A Question

Mobile menu

Close
Ask a Question
  • Home
  • Add group
  • Groups page
  • Feed
  • User Profile
  • Communities
  • Questions
    • New Questions
    • Trending Questions
    • Must read Questions
    • Hot Questions
  • Polls
  • Tags
  • Badges
  • Buy Points
  • Users
  • Help
  • Buy Theme
  • SEARCH
Home/ Questions/Q 8346731
In Process

The Archive Base Latest Questions

Editorial Team
  • 0
Editorial Team
Asked: June 9, 20262026-06-09T07:06:53+00:00 2026-06-09T07:06:53+00:00

I am building an online product using MVC4. Currently, I structured the project into

  • 0

I am building an online product using MVC4.

Currently, I structured the project into the obvious xx.Web, xx.Data, xx.Services

Here is the set of questions that I like to get your opinion on:

1- For the data layer, I am going to use the Repository pattern. I have created an .dbml that will host my Database tables. Should I create for each table a class or should should I use the classes generated by the .dbml?
2- Where For the Repository interfaces, where should I place them? in a different project xx.Data.Common or in a folder inside xx.Data?

3- Where does Error logging and Security code goes ? I have created an xx.Web.Common project for that?

Is there any guidelines for a common architecture for an MVC application? I mean I did some research but you get over flooded with tones of extensions like Ninject, etc…

I just want to implement best practices. Thanks

  • 1 1 Answer
  • 0 Views
  • 0 Followers
  • 0
Share
  • Facebook
  • Report

Leave an answer
Cancel reply

You must login to add an answer.

Forgot Password?

Need An Account, Sign Up Here

1 Answer

  • Voted
  • Oldest
  • Recent
  • Random
  1. Editorial Team
    Editorial Team
    2026-06-09T07:06:56+00:00Added an answer on June 9, 2026 at 7:06 am

    1- For the data layer, I am going to use the Repository pattern. I have created an .dbml that will host my Database tables. Should I create for each table a class or should should I use the classes generated by the .dbml?

    If you build your web from beginning, I would suggest you use Code First with Entity Framework because Linq2Sql has not evolved anymore.

    You don’t need to map 1 : 1 from your model with your database table, focus on designning domain model firs, database will be generated automatically. Also, needless to map 1 : 1 from repositoty with table. You need to understand Repository pattern with Aggregate and Aggregate Root

    2- Where For the Repository interfaces, where should I place them? in a different project xx.Data.Common or in a folder inside xx.Data?

    Should have one more dll called: xx.Domain to put your domain models and repositories interface. With this way, xx.Domain is core assembly which does not depend on any other assemblies.

    3- Where does Error logging and Security code goes ? I have created an xx.Web.Common project for that?

    Should have more dll called: xxx.CrossCuttings for logging and security.

    Use IoC container to make loose couple between layers and testability.

    Not common guideline for MVC Architecture, but try to keep your code simple, maintainable and flexible is the key.

    • 0
    • Reply
    • Share
      Share
      • Share on Facebook
      • Share on Twitter
      • Share on LinkedIn
      • Share on WhatsApp
      • Report

Sidebar

Related Questions

I am currently building a gallery web application using php. I am currently developping
I'm building an online store using PHP and MySQL and I ran into a
I'm currently building a new online Feed Reader in PHP. One of the features
Here's the situation I have: I'm building an online system to be used by
I'm building a iPhone application which depends data from an online database. To update
I'm just building an online dictionary English to malayalam, Malayalam to english dictionary. Here
I am building an online hotel booking system.... Using php and mysql.... Users can
I'm building an iOS application which fetches all of it's data from an online
Background to question: We are building an online web application that requires the user
We are building an online map (like Google Maps) and we ran into layout

Explore

  • Home
  • Add group
  • Groups page
  • Communities
  • Questions
    • New Questions
    • Trending Questions
    • Must read Questions
    • Hot Questions
  • Polls
  • Tags
  • Badges
  • Users
  • Help
  • SEARCH

Footer

© 2021 The Archive Base. All Rights Reserved
With Love by The Archive Base

Insert/edit link

Enter the destination URL

Or link to existing content

    No search term specified. Showing recent items. Search or use up and down arrow keys to select an item.