Click here to Skip to main content
15,885,733 members
Please Sign up or sign in to vote.
0.00/5 (No votes)
Hello,
I am currently struggling with this scenario:

I have a solution that consists of three main projects
project 1: The admin center - where I handle things.
project 2: The control center - where my customer handle things.
project 3: The WebAPI - where the customers of my customers get certain things.

Here's the thing. Project 1 obviously has the least to no restrictions, it may know everything. Project 2 knows less, has some restrictions, may not know all obviously.
Project 3 knows almost nothing, gets a few things and sets a few things, obviously shouldn't know anything about the admin panel or control center etc.

I came up with the following solution:
I added another project called 'Common' that consists of the bll, dal and bo layer. Basically the heart of the whole thing. Now I obviously can not reference that by every project due to the fact that only the admin center needs to know everything, the rest dont. I.e. the WepAPI does not need to know how to add or remove users.
So I added another layer, called 'Data Transfer Layer'. Basically 3 more projects - DataTransferAdminarea, DataTransferAppAPI and the DataTransferUsercontrolarea - where I would manage what the three main projects have access to. Now the problem is that all the main projects do not know any of the business objects that are inherited by their representetive Datatransfer projects. I am kind of lost here on what I should do..
Posted
Comments
StM0n 4-Feb-16 0:54am    
Mhm... your first three projects are HOW you would like to communicate with your system... the following project handles the internals. my advice would be, don't try to think all of them as sequential projects. split them as you already did. your first projects are crossconcerning. maybe this could help http://www.infoq.com/articles/crosscutting-feature-design
Sergey Alexandrovich Kryukov 4-Feb-16 2:37am    
It sounds weird that you consider your development parts as 3 different project. Is the whole thing one site? One Web application? Then it's a site, a kind of project (from the standpoint of Visual Studio solution). Other projects could be some libraries, etc...

If you described 3 really isolated applications, you would not need to ask your question. Then it means that what your describe looks rather like 3 different user interfaces over the same data layer. Isn't so? You idea of data transfer layer somehow confirms that...

And then, your problem is not clear, because you again mention "main projects". Perhaps your first step should be: you should not mix up 3 things: projects (they are specific to development artifact and build logic and do not even exist during runtime), architectural layers and tiers.

—SA
StM0n 4-Feb-16 2:39am    
You got me puzzled for a second ;)
Sergey Alexandrovich Kryukov 4-Feb-16 2:57am    
I hope this second already passed by now, so, if you look at your problem this way, we can continue the discussion. :-)
—SA
StM0n 4-Feb-16 3:00am    
second's through :D oh, and it's not my problem... but I'm with your answer ;)

This content, along with any associated source code and files, is licensed under The Code Project Open License (CPOL)



CodeProject, 20 Bay Street, 11th Floor Toronto, Ontario, Canada M5J 2N8 +1 (416) 849-8900