Solved

looking for feedback on developing a WCF Client/server application

Posted on 2014-09-18
8
263 Views
Last Modified: 2014-09-19
Hello,
I am trying to design and develop a simple WFC service which will do the following:

The Server application will wait for messages from the Client containing a Company name & a 10 digit transaction code. The initial company will be 000 and the initial transaction code for all users will be "LOGIN" and when this is received by the server program it will load up the transaction lines associated with Login. The "Login" transaction will send a request back to the client for Username and password.  If a Valid Username and Password entered then the user's company name and user's Initial menu will be retrieved from the Customer master  file (eg "101" and "INITMENU1" ) and this will be passed to the server program for processing. The various options within "InitMenu1" will return other transactions codes which will in turn be processed when selected by the user etc etc...

Company   Transaction
000            LOGIN
101           INITMENU1
101           SFCMENU1
101           PICKLIST01

I am new to C# and client/server applications and would appreciate any feedback/suggestions on the above design concept.  Is there any sample or skeleton WCF applications out there that I can build on ?

regards
Pat
0
Comment
Question by:pclarke7
[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
  • 4
  • 3
8 Comments
 
LVL 25

Expert Comment

by:apeter
ID: 40332687
Basically the requests are disconnected in wcf service. From your scenario, the is a session maintained between the request like a web site.

Wcs is a service and will serve the requests. It will not request a client for something  unless they are duplex wcf service.

Please provide more information on above so that it will be helpful in creating a client.
0
 

Author Comment

by:pclarke7
ID: 40333164
Thanks for the reply,
I understand that both the server and the client run independently of each other but for example on a web site when you take an option ("Search" for example) then the server will process the search request from the client and when the results of that request are complete the client will "React" by displaying the results.

Take a simplified transaction DISPRATE as follows:
Seq Type  command          
1     TAG   Start
2     CON  Set base currency as 'EUR'
3     LOG   retrieve today's exchange rates
4     OUT   Display "Please enter your currency"
5     INP    Input Currency
6     OUT  Display "Your exchange rate is &Rate"
7     LOG  goto start

In this example the client will pass the transaction code DISPRATE to the server program which will load and run the transaction. The transaction has various type of statements, (Tag, Constants,Logic, Decision, Input,Output etc..). When transaction gets to an INPUT statement (INP) then it will exit the Server application passing back the data which it has collected (Such as the Display information which the client should display).  The client is used to gather Input information for the transaction. After the client Inputs the currency then the server will be called again for transaction DISPRATE and will pass the input information to the server application (ie USD ). The server will then resume the transaction at the next line (Seq  6).

Hopefully this explains the concept of what I am trying to achieve. If there is a better way of achieving this other than using WCF, then I am certainly open to suggestions. The only condition is that it has to be a web based solution.

regards
Pat
0
 
LVL 80

Expert Comment

by:David Johnson, CD, MVP
ID: 40333193
your example has them on the same page and by doing a post-back you are seeing the results. there is state here.

one normally uses an api ley for authentication.  and you would use a soap or rest interface between them.
i.e. you would send the request including the api key and the command you want results for, then the service would process the request and return the data.
0
Instantly Create Instructional Tutorials

Contextual Guidance at the moment of need helps your employees adopt to new software or processes instantly. Boost knowledge retention and employee engagement step-by-step with one easy solution.

 

Author Comment

by:pclarke7
ID: 40333501
Hi David,
thanks for your comments.  Unfortunately most of what you have said is unfamiliar to me. At this point i need 3 things.

1. Confirmation that a WCF service is either suitable, or not suitable,  for what I am trying to achieve.
2. A simple example which demonstrates a client making a request of a server, the server processing the request and the client reacting to the completed request.
3. Someone to point me towards relevant documentation that will help me

regards
Pat
0
 
LVL 80

Accepted Solution

by:
David Johnson, CD, MVP earned 500 total points
ID: 40333525
0
 

Author Comment

by:pclarke7
ID: 40333620
Thanks David,
one last question - do you think that WCF is suitable what what I am trying to do ? - or is there something else I should be looking at

regards
Pat
0
 
LVL 80

Expert Comment

by:David Johnson, CD, MVP
ID: 40333632
since I really don't know what you want to do ultimately the choice is yours.. one advantage is that your service can be called via many methods i.e. iphone/android/WP app, Console/Desktop App, WebSite
0
 

Author Closing Comment

by:pclarke7
ID: 40333673
Thanks David
0

Featured Post

PeopleSoft Has Never Been Easier

PeopleSoft Adoption Made Smooth & Simple!

On-The-Job Training Is made Intuitive & Easy With WalkMe's On-Screen Guidance Tool.  Claim Your Free WalkMe Account Now

Question has a verified solution.

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

This article describes a simple method to resize a control at runtime.  It includes ready-to-use source code and a complete sample demonstration application.  We'll also talk about C# Extension Methods. Introduction In one of my applications…
Real-time is more about the business, not the technology. In day-to-day life, to make real-time decisions like buying or investing, business needs the latest information(e.g. Gold Rate/Stock Rate). Unlike traditional days, you need not wait for a fe…
Although Jacob Bernoulli (1654-1705) has been credited as the creator of "Binomial Distribution Table", Gottfried Leibniz (1646-1716) did his dissertation on the subject in 1666; Leibniz you may recall is the co-inventor of "Calculus" and beat Isaac…
Attackers love to prey on accounts that have privileges. Reducing privileged accounts and protecting privileged accounts therefore is paramount. Users, groups, and service accounts need to be protected to help protect the entire Active Directory …

697 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