6 Jun 2011

My Development Environment to Develop SharePoint 2010 Solutions

Well, I don’t know if this tips would help much for you. But this is my best Development Environment when I want to create SharePoint 2010 Solutions. And I’m about to share to you all, so I hope it helps.

My Development Environment (DE) is using Windows 2008 R2. But I’m adding some UI feature for extra comfort usability, and more like Windows 7, and of course, Kung Fu Panda 2 themes, downloaded from Microsoft’s theme pack website Smile with tongue out. And not only that! I want my development environment works faster, faster to deploy (well, at the first deploy, you can’t refuse if it slower, but better on next deployment), faster to install DLL, and recycle IIS, and faster to debug IIS processes.

image

Important shortcuts pinned to Start Menu for best performance.
image

An additional configuration to Windows Server 2008 R2, some important roles in my OS Confused smile.
image

After all roles installed, then I install the SQL Server 2008 R2 and SharePoint 2010. Configure it based on Microsoft’s best practice, and etc…etc….

Then I added Microsoft Loopback Adapter. You might want to ask, what for?

Well, I’m some kind of crazy and stupid guy who wants to simulate my development (at every small aspect of it) very similar to the production server. So, I would like to add DNS Server, and when I want to access any web of my development environment, I could access it with not only my server name, but the DNS Name. Ex: brox-dev.contoso.com, or max-payne.pick.com at my environment. So, I don’t need to add port at the end of address. It’s more convenient to me.

After that, the DNS Service needs the server in “static IP” condition at any time, whether you connect it to another LAN, or WLAN, or connect to your modem to your internet. “Why must use Microsoft Loopback Adapter, not the LAN Adapter itself?”. Well, the answer is another question, “How’d you want to connect production server, connect to the internet, or connect to your LAN?”. My DE needs an adapter which always stated as connected whether connected to LAN, Wireless, internet using modem, or not connected at all, but the DNS always works. I choose Microsoft Loopback Adapter. I’ve already installed it from the list of built-in Network Adapters in Windows Driver.
image

image

image

image

So, this is my screenshot of my network configurations. It’s connected to Local Area Network (to connect to my production server), and at the same time, connected to internet using my modem, and using Loopback to resolve all of internal DNS records.
image

And set to static IP to my Loopback Adapter,
image

It’s a bitter work, but I’m enjoying it.

Next, install Microsoft Visual Studio 2010, bla…bla…bla…. After all the process, I’ve added some functionalities to my VS 2010 IDE.
image

TGGL BP = Toggle Breakpoint
D3L BP = Delete All Breakpoints
RBLD = Rebuild Solutions (Rebuild Solution is always build ALL code, while with Build Solution is always build CHANGED code)
GAC DPL0Y = Added external command, using DOS Batch file. The process is deploy the new DLL into the Global Assembly Cache (GAC), and then using MS-DOS, recycle the IIS Application Pool. You can look at my older post on recycleiis.exe I’ve created it myself.
And here’s the screenshots after clicking GAC DPL0Y,
image
4TCH W3WP = Attach W3WP Process after deploy DLL to GAC, to debug your solutions from W3WP Processes. This is a VS 2010 macro codes, you can also download this bunch of code in this link. Inside the macros, added specific functionality to attach only development application pool.
4TCH OWSTimer = Attach to OWSTIMER.exe process. This is a macro code too.
DPL0Y = the real Deploy Solution command menu in Visual Studio 2010, to deploy all solutions.

Why am I using GAC Deploy, Attach W3WP, and Attach OWS Timer?
The answer is simple, SAVE TIME. When you doing Deploy Solution, Visual Studio 2010 actually recycle the application pool, retract the solutions, checking all stuffs after retraction, and then add solution to server, install features, activate features, and then done. Too much time, and I could sleep for a while just waiting this process getting done Smile with tongue out. Oh.. and one more thing, this kind of processes like GAC Deploy, Attach W3WP or Attach OWS Timer, can only be done AFTER you firstly doing Deploy Solution. As long as you don’t retract your solution, you can use this kind of processes to save your time.

That’s it. I’m done, and tired enough to write. It’s time to back to work again… Sleepy smile. Comments if you want another detailed steps. Hope it helps.

Tidak ada komentar:

Posting Komentar

[give me your ideas, hopes, comments and compliments below...]
[aaand...... +1 if you need to....]