Jonathan Coe
Jonathan Coe

Reputation: 1485

Creating a web service for a system built on nHibernate & stored procedures

I have been asked to build a rather simple form processor application that interacts with an already-existing system that is built on nhibernate & uses stored procedures to manage all the business logic in the system.

My goal is to build a (hopefully) simple web service (json if possible) that I will be able to access from both a web site, and ultimately an iphone & android app down the road.

I've built a couple fairly substantial RESTful api's using other technology (PHP, python, Redis, Mysql, etc) however aside from my basic understand of the overall syntax of C#, i'm pretty green to the whole ASP world. And frankly, the thought of doing anything drag and drop makes me want to stab rusty forks into my eyes ;)

My questions to those with C#/ASP/nHibernate experience:

  1. I have visual C# express 2010 - do I need to purchase visual studio to build this app?
  2. Is it even possible to build a simple JSON api/web service that can handle simple transactions (ie: return a list of dates, and insert a single new entry) with C#? What tools do I need to get started down that path?
  3. Does anyone have any resources or recommendations for a crash course or high level tutorial in C# web service construction?

I've done a fair bit of reading on nHibernate now, and feel i have a loose understanding of how the thing works, i'm just foggy on how to link a few simple classes/stored procedures with the actual web service.

My goal is to completely avoid re-inventing any wheels, and keep this thing as lean as possible... essentially, the web service is only there to pass data back and forth to the database.

Any help would be GREATLY appreciated - I know I can build this thing, I just can't seem to figure out where to start - if I could just sit down and code the thing, I would be fine... but it seems that with microsoft, you can't just sit down and code anything :S

EDIT: I'm working on Windows 7 Professional, I have downloaded nhibernate 3.2.0 and installed visual C# express 2010, I also have a windows 2008 server box with ASP.net 3.0 at my disposal for testing purposes.

EDIT 2: Which express package should I be downloading here? I have C# express, which seems to be the wrong one to start with - http://www.microsoft.com/visualstudio/en-us/products/2010-editions/express

EDIT 3: Thanks for the answers so far... currently downloading visual web developer and will dig into WCF and MVC a bit further.

Upvotes: 0

Views: 845

Answers (1)

Oded
Oded

Reputation: 499172

  1. No need to purchase VS. The license for VS Express allows for commercial applications to be built with it.
  2. Yes, you can build a simple JSON api/web service - use ASP.NET-MVC, not webforms. I have done this a few times.
  3. http://asp.net/mvc and for a working example of an MVC web site http://nerddinner.com

For web work, VS Web Developer Express is what you should be using.

Upvotes: 2

Related Questions