|
>
 Friday, March 23, 2007
 |
|
 |
|
|
|
|
|
I just spent the last week at SD West in San Jose...this year the conference was bigger than ever before! Thanks to everone that attended my tutorials and sessions, I really enjoyed the questions and discussions...as I hope you did. As promised, here is a list of all my resources from the conference talks. Enjoy! Intro to Web Services (Tutorial) - Christian Gross and myself presented this one, discussing everything from POX, REST, RSS, SOAP/WSDL, WS* and SOA.
- Code I demonstrated in this tutorial is from the .NET Web Services tutorial next.
.NET Web Services TODAY (Tutorial) Microsoft Technology Avalanche (Tutorial) Top 10 Web Service Standards You Need To Know WCF Contracts and Versioning - Demonstrations in both of these talks are based on WCF code from my book here: http://www.thatindigogirl.com/LearningWCFCode.aspx
- See \Security, \ReliableSessions, \Transactions in particular for the WS* discussion
- See \DataContracts, \AdvancedSerialization, and \ServiceContracts for the contracts discussion
CardSpace - Demonstrations in this talk can be found here:
The Amazing World of Federated Security - This talk was mostly discussion of standards and architectures however the demonstrations I used to illustrate a few points are based on my claims-based samples here:
- And, my STS sample here (NOTE: this sample will be updated shortly with an upcoming article, stay tuned!):
|
|
|
 |
|
 |
 |
|
 |
|
|
|
|
|
I created a presentation in November of last year with the goal of helping folks make sense of the vast number of Microsoft technologies from development tools, language, data, windows, web and SOA development. This blog post holds the latest links to resources and code for each section. System Requirements The links below use the following technology platforms: - Visual Studio 2005 and .NET 2.0
- .NET 3.0
- NET 3.0 Runtime (installed with Vista)
- Windows SDK for .NET 3.0
- Visual Studio 2005 Orcas Extensions for .NET 3.0:
- WCF&WPF (Nov 2006)
- WF (Nov 2006)
- ADO.NET and LINQ CTP for VS 2005 (May 2006)
- LINQ CTP
- ADO.NET vNext CTP
- ADO.NET vNext Entity Data Model Designer Prototype, CTP
- Visual Studio Orcas CTP (March 2007)
Development Tools In this section I reviewed the stack of development tools and explained how to choose between them. Language Enhancements In this section I talked about moving from .NET 1.1 to 2.0, and discussed the key features of 2.0 that folks should be leveraging. Then, I focused on the language enhancements forthcoming with C# 3.0 and VB 9.0. Demos: Data Access In this section I focused on data access technologies, designing the data access tier, and key features of ADO.NET 2.0, vNext and LINQ to give you some idea how to prepare for the next set of innovations. Demos: - When you install ADO.NET vNext and LINQ there are literally 100s of samples that will really help you get up to speed here. I show a selection of these in this presentation.
Windows Development
In this section I review Windows Forms 2.0 innovations, primarily ClickOnce, and then talk about how to prepare for WPF, explaining the various deployment models. I also talk about practical approaches to choosing the right platform for your development efforts. Demos: Web Development
In this section I showed an ASP.NET sample application that illustrates key features of ASP.NET 2.0 and practical application of those features. Then we looked at AJAX and discussed trends on the Web compared to Windows development. Popular AJAX Frameworks: Demos: Distributed System Programming In this section I reviewed the typical use for earlier distributed computing technologies like remoting, enterprise services and ASMX web services with WSE, and compared them with WCF. BPM and Workflow In this section I discussed BPM, BizTalk and workflow and trends for BizTalk vNext. DinnerNow To pull it all together, there is a sample you can download here: www.dinnernow.com that illustrates all of the technologies in a practical example. It includes WCF, WF, WPF, AJAX, Vista gadgets and mobile apps.
|
|
|
 |
|
 |
 Sunday, February 19, 2006
 |
|
 |
|
|
|
|
|
After rebuilding my machine a few weeks ago, once again I find myself running into old problems and trying to remember how to repair them. This time, generating keys to strongly name my asesmblies through the Signing tab in Visual Studio 2005. I thought I would share it this time in case others have seen this problem...and struggled with it...
The Scenario:
For a Windows client application, open the Properties for the project, navigate to the Signing tab, check Sign the assembly and create a new key. In the Create Strong Name Key dialog, provide a new key name, provide a password, and click "OK".
The Problem:
An error message is presented: Create strong name key the operation could not be completed. Access is denied.
The problem repeats itself when I tried to use the strong name utility (sn.exe), with this error: Failed to generate strong name key pair. Access is denied.
The Solution:
I had to give my user account access to the key container in C:\Documents and Settings\All Users\Application Data\Microsoft\Crypto\RSA\MachineKeys. It turns out, even administrator rights were disabled on my machine! I am not sure if this was the default installation (I rebuilt the machine a few weeks ago) or if this is modified when I install WinFX, or if when I granted ASP.NET and NETWORK SERVICE access it somehow lost the inherited permissions that were granted when I installed the OS. In any case, at least it seems predictable, you need access to the key store in order to generate keys, makes sense!
How does it work?
Each container created using sn.exe -i is located in the MachineKeys directory (unless you specify elsewhere). The default key container that is used by sn.exe is also in that location.
In the event you reset your key container to a new one, and forget where it is...you can reset the key container for the strong name utility using sn.exe -c. So, if the account access fix doesn't work, you may be using an alternate key store so a reset may be in order.
I googled this topic a bit before writing this blog, and was surprised that very little has been written on this subject for a solution...furthermore...many people actually rebuilt their machines to solve the problem!!!! I hope this blog entry prevents a few more of those!!!
|
|
|
 |
|
 |
 Monday, September 12, 2005
 |
|
 |
|
|
|
|
|
We put on a 1 day seminar at UCSD Extension on Saturday for those interested in getting up to speed on the upcoming release of .NET 2.0. I'm posting a bunch of 2.0 samples here directly related to the topics we covered at the event.
Dave McCarter gave a great overview of the VS 2005 IDE and its productivity features. No code to share on that one, you have to be there to see it!
I presented a talk on VB.NET and C# language enhancements. Samples include a few new VB.NET samples:
Several C# samples that are posted on the IDesign site:
I also presented a talk on ClickOnce and Smart Clients...the code sample is better seen in “live demo“ but here's the finished product of what I demonstrated:
And to wrap things up, Scott Mitchell gave a great talk on ASP.NET 2.0...he did most of his demos live, but I told him I'd post some of my finished ASP.NET 2.0 samples here that were related to his talk...since I have them handy:
aspnet20samples.zip
For more IDesign samples go here:
http://www.idesign.net/idesign/DesktopDefault.aspx?tabindex=5&tabid=8
Enjoy!
|
|
|
 |
|
 |
 Friday, May 13, 2005
 |
|
 |
|
|
|
|
|
I recently received this question at SearchWebService.com...
How can I call a Web page from my Web service page after extracting an XML file into a dataset? My Web page will display data from a created dataset into a DataGrid control. Can I return data directly into a Web service page using Visual Studio .NET?
Probably because I have had to go through some interesting integration patterns in the past, I answered the question with two flavors...discussions welcome.
Here's my answer:
I think the best way to tackle your question is to review the workflow between client, Web service and Web application (pages). If the client application is the Web application, then the workflow looks something like this:
1. User browses to a page.
2. During the Page.Load event you invoke a Web service to get the dataset, before binding that dataset response to a DataGrid control on the Web page.
3. The page is returned to the browser with the populated DataGrid rendered as HTML.
The call chain looks like this:
Browser->Web Page->Web Service
What may be misleading about your question is the statement “call a Web page from my Web service”. Web services are data centric calls. They do not return HTML that can be displayed in a browser, therefore they should not be responsible for “calling” a Web page. Rather, the Web page should call the Web service to gather data, and present it. The driver behind the activity is the user who navigates to a page that leverages the service.
That said there is another possibility that can be interesting. Consider this workflow:
- User interacts with a Windows client application.
- The application at some point invokes a Web service to gather data from a remote server. The Web service establishes a session for the caller, and allocates the dataset to the session. The Web service returns XML that includes a link to a Web page exposed by the same server.
- The client application retrieves the XML response, which includes a URL to a Web page to navigate to (with session established) and the client application launches a browser (or, has an embedded custom browser) to the URL.
- The requested URL (page) retrieves the dataset from the session object, and displays the page fully populated.
So, the call chain is now:
Windows App->Web Service
Windows App -> Browser -> Web Page
This type of workflow may seem disconnected, however it is one technique whereby a legacy application can integrate with a modern user interface (through the browser) when the legacy app wants to integrate the modern application’s services as part of a user interface workflow, in addition to data exchange. For example, the insurance industry has many legacy agency management system applications, some even DOS-based entry screens, that “work” therefore will not be replaced. These agency management systems hold important data necessary to create certificates of insurance, a service often provided by external, modern applications. These modern vendor applications rely on data from the agency management system to function, therefore a data exchange must be automated as part of the workflow, enabling the modern application interface to pick up where the legacy system left off, and finish the job.
|
|
|
 |
|
 |
 Monday, May 09, 2005
 |
|
 |
|
|
|
|
|
What a great turnout for the .NET conference in Long Beach last Saturday! I was amazed at how many faced I recognized from San Diego, Orange County and LA!!!
Anyhow, my slide deck for the presentation is here as promised:smartclient_ocevent1.zip (412.28 KB)
I'll update this blog post tonight with the code sample. Just cleaning up some things that I had converted for Beta 2. Stay tuned!
Updated 05/09/05 - code sample from demo:ClickOnceDemos.zip (368.13 KB)
|
|
|
 |
|
 |
 Sunday, May 08, 2005
 |
|
 |
|
|
|
|
|
Ok, I noticed a few other little things about the publishing process through Visual Studio 2005, related to Beta 2. So, in an effort to save you all the 45 minutes I wasted on some of these things, here's the list. Luckily, I was somewhat aprised of this before I did my presentation yesterday, however, it still ate up some demo time given that things didn't always work the first time...
1. Publishing will continue even if you can't successfully build (see my previous post), so I recommend you always try to build first and watch your output. I know what you are thinking: “Oh, I'll just publish and check the output window for errors before I run the app”. But, I guarantee you will be sometimes seduced by that little browser window with the “Install” button...and you'll forget...and you'll find a bug...and you'll try to think about what the problem is but really you didn't get the latest assembly (or, worse, the assembly you're referencing never was built).
2. The “Properties” tab doesn't appear to be saved as part of the build step. So, if you make changes they won't be reflected when you publish...another ghost. The problem is, it still increments the published version, so you “think“ you have it.
3. Sometimes, not always, if you don't version your assemblies, the updated code is not deployed with the newly published version. This problem seems strange to me, since the published application version has been incremented...however I haven't had time yet to inspect what the cause of this is, in terms of the server deployment and its files.
If I see any more problems, or find a solution for these issues...I'll update this post. Feel free to comment if you find it before I do, I'm about to bury myself in ASP.NET 2.0 and Indigo for the next few weeks, I won't have much time for ClickOnce...
|
|
|
 |
|
 |
 Friday, May 06, 2005
 |
|
 |
|
|
|
|
|
Ok, so I just had a long discussion with one of the smartest guys I know, my colleague, mentor and friend - Juval. We were talking about strong names, full trust the global assembly cache and .NET assemblies. It started out innocently enough, however as the discussion continued, we both insisted on being right...and as it turns out, we were both right...but I still lost $1 due to my own muddy description of the bet. Perhaps you've been confused by this as well? Read on...
She said:
When you deploy assemblies to the GAC, they get full trust.
He said:
No, you're wrong. The GAC has nothing to do with the assignment of privileges. You want to bet? I can prove it.
She said:
No, I'm sure of this, I do it all the time with my ASP.NET applications when I deploy business objects to the GAC. They get full trust. This is important because it is the only way I can reduce the privileges of the ASP.NET application assemblies (using the <trust> element as I discuss in my article here: http://www.theserverside.net/articles/showarticle.tss?id=SandboxingComponents), and then elevate privileges as needed to invoke assemblies that demand full trust or other permissions. The stack walk would fail, if I were not able to elevate privileges at some point, and assert to circumvent the stalk walk. I certainly don't want ASP.NET application assembly to run with full trust if I can avoid it.
He said:
Ha, I'm right. You see?
So, he demos his client app (EXE), with a dependency on another assembly (DLL) that was deployed to the GAC. He removed full trust for assemblies deployed to local machine. Then he invoked a .NET assembly that required full trust. Sure enough, the permission demand fails.
She said:
Crap. Thinking thinking thinking...Well, wait a minute, you need the policy to at least grant full trust based on the strong name or something like that? Darn it, what is it? I know there is something...ok I didn't describe this right...(fumbling)...I mean...er...I wasn't trying to say GAC = full trust, but that you need to deploy to the GAC, at least with ASP.NET...to get full trust...hmmm...ok, here's your damn dollar.
ABOUT AN HOUR LATER
She said:
Aha! I went and reread my article (above) and it jogged my memory...basically, ASP.NET runtime uses different security policies to assign permissions. Inside the security policies for ASP.NET such as web_lowtrust.config, web_hightrust.config, etc...there is a setting that pulls in full trust for GAC assemblies, automatically.
<CodeGroup
class="UnionCodeGroup"
version="1"
PermissionSetName="FullTrust">
<IMembershipCondition
class="UrlMembershipCondition"
Url="$Gac$/*"
version="1"
/>
If only I could remember these things in the heat of discussion, I would be $1 richer right now.
Ok, you were right...but so was I :) Ego somewhat repaired.
|
|
|
 |
|
 |
 Friday, April 29, 2005
 Monday, April 25, 2005
 Saturday, March 26, 2005
 |
|
 |
|
|
|
|
|
In the short hour we had together on this subject, we looked at many features of Windows and Web localization for .NET 2.0. Big topic, so you’ll want references and code samples to ponder on, and I have collected my globalization resources here:
http://www.dotnetdashboard.net/sessions/globalization.aspx
Code samples I showed in the session are related directly to samples for my articles, but keep an eye on this reference page for updates coming for Beta 2! Also, the articles will help to review things in depth that we had limited time to touch on.
Oh, and stay tuned for more samples in May/June, when I’ll be writing some new articles based on the .NET 2.0 code base. Any requests on solutions you’d like to see added to the resource page? Email me!
|
|
|
 |
|
 |
 |
|
 |
|
|
|
|
|
I delivered not one, but two talks on this subject at the conference in Orlando…the first a fundamentals session, followed by a more advanced session that ended with ClickOnce. I have written some tutorials and articles on the subject that can be found here:
http://www.dotnetdashboard.net/sessions/versiondeploy.aspx
|
|
|
 |
|
 |
 |
|
 |
|
|
|
|
|
In this tutorial I reviewed the issues we revisit with our return to building Windows client (thick client, smart client) applications, including design, deployment and versioning, automatic updates, and ultimately we discussed what ClickOnce brings to the table.
My gui samples were mostly ad-hoc, but I'll be posting more resources on this subject for you soon, for 2.0. In the meantime, the versioning, deployment and security aspects I discussed can be found here, including a full tutorial of the process:
http://www.dotnetdashboard.net/session/versiondeploy.aspx
|
|
|
 |
|
 |
 Monday, March 21, 2005
 |
|
 |
|
|
|
|
|
In this session I walked through some live demos using .NET 2.0 and ClickOnce, to demonstrate how the smart client story is evolving to solve deployment, versioning, automatic updates, offline/online connectivity, and more. Here are some more resources on the subject:
http://www.softinsight.com/bnoyes/
that's my colleague Brian Noyes blog, he writes pleny on ClickOnce, has many reference to other articles he's written on the subject, and is my own personal ClickOnce hero
http://msdn.microsoft.com/library/default.asp?url=/library/en-us/dnreal/html/realworld11022004.asp
a fellow Regional Director, Mauro Sant'Anna, writes fantastic article on ClickOnce, also a must read
And, in addition, resources for .NET 1.1 versioning, deployment, update and security issues at this blog entry:
http://www.dasblonde.net/PermaLink.aspx?guid=544e8515-afa0-46d3-8586-8512e686a911
|
|
|
 |
|
 |
 Wednesday, February 23, 2005
 |
|
 |
|
|
|
|
|
I recently received a question from a J2EE developer, who wanted to know how to get started with a multi-tiered architecture for .NET Web services.
The question:
I have some experience with J2EE and know that one good design is to create a multi-tier architecture. That is to say create control servers that will request processing from business tire | | |