Solved

Web Service Debugging

Posted on 2014-11-17
5
343 Views
Last Modified: 2014-11-18
Hi Experts,

I am working in web service in my asp.net project and i want to debug the webservice. How can i do this?

Please guide me.

Thanks in advance
0
Comment
Question by:Jatin Nahar
[X]
Welcome to Experts Exchange

Add your voice to the tech community where 5M+ people just like you are talking about what matters.

  • Help others & share knowledge
  • Earn cash & points
  • Learn & ask questions
5 Comments
 
LVL 11

Expert Comment

by:LordWabbit
ID: 40447209
Right click the solution, select Debug, start new instance.
0
 
LVL 36

Expert Comment

by:Miguel Oz
ID: 40448584
If your project is already in debug configuration and it is selected a start up project, press F5.

Note: 1) or debug mode: Open configuration manager and check that active solution configuration is set to debug
2) Selected a start up project: Right click project and  click "Set as startUp project" menu item.
0
 
LVL 18

Accepted Solution

by:
Richard Lee earned 500 total points
ID: 40449528
To effectively test a web service to ensure that you logic is correct and to work out the kinks and bugs I find it best to use a layered architecture.

It is important to think of your web service and a View or a point of access  for your users. In this case users can be another application whether internal or external. When you thought processes are aligned in this manner you will then need to abstract your business logic into another layer and simple call the operations from your web service.

Users  ---> Web Service ---> Business Layer/Domain Layer

This is a tried and tested principle of N-Layer architecture, however with this approach you can now unit test your code directly against the business layer and not have to worry about the web service complexities.

Unit Tests ---> Business Layer

Now do I hear you asking what about the logic that occurs in your web service method? How do you test that? My answer to your question is simple. Your business layer should implement the Facade Pattern to satisfy the operations performed by the web service thus ensuring that your web service operations only contains a single line of code.

Web Service ---> Business Layer (Facade [Compound Operation] --uses--> Business/Domain Objects)

Now I hear another question. What is the point of having a web service operation with just one line of code? A web service is just another View remember. It is simple here to expose your business functionality another way to other applications or users. It is not hear to re-write functionality!

Hope this helps.
0
 

Author Closing Comment

by:Jatin Nahar
ID: 40449712
good solution
0
 
LVL 18

Expert Comment

by:Richard Lee
ID: 40449733
Your welcome. Always glad to help.
0

Featured Post

SharePoint Admin?

Enable Your Employees To Focus On The Core With Intuitive Onscreen Guidance That is With You At The Moment of Need.

Question has a verified solution.

If you are experiencing a similar issue, please ask a related question

These instructions are based on installing Owncloud on your new raspberry pi connected with a usb HDD. What do you need Part A? A Raspberry Pi, model B. A boot SD card for the Raspberry Pi. A usb HDD An Ethernet cable to connect to the lo…
It was really hard time for me to get the understanding of Delegates in C#. I went through many websites and articles but I found them very clumsy. After going through those sites, I noted down the points in a easy way so here I am sharing that unde…
The purpose of this video is to demonstrate how to set up the WordPress backend so that each page automatically generates a Mailchimp signup form in the sidebar. This will be demonstrated using a Windows 8 PC. Tools Used are Photoshop, Awesome…
Come and listen to Percona CEO Peter Zaitsev discuss what’s new in Percona open source software, including Percona Server for MySQL (https://www.percona.com/software/mysql-database/percona-server) and MongoDB (https://www.percona.com/software/mongo-…

728 members asked questions and received personalized solutions in the past 7 days.

Join the community of 500,000 technology professionals and ask your questions.

Join & Ask a Question