views:

147

answers:

2

Hello everyone,

I am developing on SharePoint Service 3.0/SharePoint Server 2007. I always read document says create an application or create a site (collection). The term application and site always make me confused. Could anyone help to clarify what is the relationship between a SharePoint application and a site (collection)?

For example, here is one of the case when I am confused,

http://weblog.vb-tech.com/nick/archive/2006/06/14/1617.aspx

"1, Create a new site – go to Office Server Central Administration -> Application Management -> Create or Extend Web Application -> Create a new Web Application Enter the settings to create a new SharePoint site." -- mixing site and application make me confused.

"Once the Application has been created choose to ‘Create a new Windows SharePoint Services site collection’." -- seems application has 1:1 relationship with site collection?

thanks in advance, George

+1  A: 

In real development terms - A SharePoint Application is an IIS site with nothing configured, while the site collection is the initial base configuration of the IIS App, sites in the site collections can be thought of as virtual directories.

This is not entirely accurate, but its a good way to generate a mental picture.

And you're right to be confused, welcome to the world of MOSS! Its gets even better.

JL
1. Can I understand SharePoint Application as an empty web site with nothing (no content) and until we create site collection on the application, no users could access it? 2. Application and site collection has 1:1 relationship or 1:many?
George2
Yes to point 1 and 1:many for point 2 - a sharepoint farm can have many site collections. A lot have only one site collection but a good reason to have many site collections is to divide the data between different content databases (a site collection must be entirely in the one content database so to keep the content databases manageable you may need to split your sharepoint sites among different site collections).
Chris Latta
I understand for a sharepoint farm, there could be of multiple site collections. My confusion is for a specific application, could there be more than one site collection belong to this application? I am confused as you said 1:many relationship, since I think as you said in your original reply, an application is an empty framework of a IIS web site, and site collection is its real root web site directory content. Since IIS web site could have only one root web site directory, so I think for an application (IIS web site), there could only 1 site collection (web site root directory).
George2
If I am wrong, could you show me how to create multiple site collection under the same SharePoint application?
George2
The web applications simply server SharePoint content (sites) via IIS. They will all be the same as they are automatically kept in sync by the farm so they all have the same software loaded (called solutions or features) and they server the same content. To have multiple site collections, you set up managed paths and create the site collections on these managed paths. So yes, there is one root web site but the other site collections appear as if they are sub-sites of the main site. My sharepoint intranet has about 100,000 site collections - yes, really
Chris Latta
Thanks Chris, 1. I have understood SharePoint application maps to IIS web site object, and site maps to IIS virtual directory object, but what IIS object does site collection maps to? 2. "Managed Path" you mean exactly which configuration item in MOSS Central Administration?
George2
+2  A: 

Yes, that's a bit confusing. In the first instance he is using the term "site" to mean preparing the SharePoint installation to serve content, basically enabling it to become a web site; in the second instance he is talking about creating actual sites within SharePoint.

There are basically four different levels to think about in SharePoint:

  • Farm - all the SharePoint servers (even the database server) taken as a whole. This is what you interact with via Central Administration
  • Web Application - the software that serves SharePoint content via IIS
  • site collection - a hierarchical collection of sites
  • site - the actual site that the user interacts with within a site collection

If you find that confusing, wait until you program against it where you'll find a site is called SPWeb and a site collection is SPSite...

Chris Latta
Thanks. Could I simply understand (from administration GUI and not MOSS programming object model perspective) Application means an empty web site, and site collection means the actual content of the web site. So application and site collection has 1:1 relationship? i.e. an application can not have more than one site collections?
George2
See my comment in @JL's answer but basically a web application is an IIS server that is ready to serve content from Sharepoint. However, there needs to be at least one site collection with at least one site in it to be able to serve some content. However, there may be several site collections. For instance, each department may have their own site collection for their sites.
Chris Latta
Thanks Chris, could you let me know how to create multiple site collection from MOSS Central Administration please? In my past experience, I have wrong understanding and do not know how to configure multiple site collection under one SharePoint application. I am very interested to follow your advice to try new things.
George2
Your definition of a Web Application implies that there can be only one per front-end server, while there can really be many.
Chris Farmer
Edited, although in practice I'm not sure why you would have multiple web applications on the one server
Chris Latta
How about both central administration and your "regular" site?
Chris Farmer
Chris, sorry I have not made myself understood. My question is, for one application in SharePoint, how could we establish multiple site collections? Is it possible, if possible, how?
George2
When you create a site collection you are forced to either choose an existing web application or create a new one. A web application can contain one or more site collection, it is not a 1:1 relationship. Think of a web application as the container which houses site collections.
OedipusPrime
Oedipus is correct. I wasn't trying to make any practical claim to help the original poster in my previous comments. I just meant to clarify that multiple web applications almost certainly do already exist on every SharePoint server.
Chris Farmer