Click here to Skip to main content
15,898,374 members
Home / Discussions / Web Development
   

Web Development

 
GeneralGuys pls suggest me a good project definition using .NET Pin
paresh_sarjani31-Mar-08 18:05
paresh_sarjani31-Mar-08 18:05 
GeneralRe: Guys pls suggest me a good project definition using .NET Pin
Bradml31-Mar-08 21:00
Bradml31-Mar-08 21:00 
GeneralRe: Guys pls suggest me a good project definition using .NET Pin
Ali Rashid2-Apr-08 17:49
Ali Rashid2-Apr-08 17:49 
GeneralE-commerce Standards Pin
Edmundisme31-Mar-08 10:07
Edmundisme31-Mar-08 10:07 
GeneralRe: E-commerce Standards Pin
Bradml31-Mar-08 12:27
Bradml31-Mar-08 12:27 
GeneralRe: E-commerce Standards Pin
Edmundisme31-Mar-08 12:41
Edmundisme31-Mar-08 12:41 
GeneralRe: E-commerce Standards Pin
Bradml31-Mar-08 12:58
Bradml31-Mar-08 12:58 
QuestionGetting web service server URL at runtime... Pin
matmus30-Mar-08 3:11
matmus30-Mar-08 3:11 
Hi,
I am currently developing a distributed application, which uses web services to perform communication.

In the simple case there's a main engine and external engine (on separate machines / servers).
Main engine part is written in C# and its communication part runs under IIS (currently clients are also running under IIS, but target environment will be Tomcat/Ajax probably).
What I am trying to do, is to implement bidirectional communication between both engines (using WS, to avoid further migration problems etc.)

I've assumed, that the two sides both: serve and consume a WS. Ie. MainEngine serves ServiceMain, and ExtEngine server ServiceExt

The communication scheme is as follows:
1) MainEngine executes
ExtEngine.connectMainEngine(mainEngineURL); //ExtEngine.Url is provided by user
providing the client with URL to ServiceMain WSDL. Here ExtEngine is a WS proxy class generated automatically by VS.NET from WSDL file
2) From now on bidirectional communication is possible, by executing services from ServiceMain in ExtEngine and from ServiceExt in MainEngine respectively

The problem is: mainEngineURL is hard-coded (at my development platform it's something like: http://localhost:2758/ServiceMain.asmx). I'd like to get this URL (or at least the "localhost:2758" part) at runtime. I've tried using both: this.Server.UrlPathEncode(); and this.Server.MachineName from within class ServiceMain which inherits from System.Web.Services.WebService, but it's not quite it Smile | :)

In brief: how to get web service URL at runtime (in a WS server)?

OT: Is there a simpler way to implement bidirectional communication than providing two separate web services (some kind of callback)? The thing is - as far as I know (even with async WSs) - server can't explicitly call a method in client (comm. must be always initiated by client). Am I wrong? In this scenario what I'll be willing to do is:
client executes ServiceMain.RegisterExternalEngine(clientCallbackFunction) and from now on server can asynchronously send data to client (running this callback function - some kind of RPC Wink | ;) ), and client can communicate with server using its web service forontend. This approach wouldn't require second servlet container/server on client side...


Regards,
MB
GeneralRe: Getting web service server URL at runtime... Pin
led mike31-Mar-08 4:46
led mike31-Mar-08 4:46 
GeneralRe: Getting web service server URL at runtime... Pin
matmus31-Mar-08 7:05
matmus31-Mar-08 7:05 
GeneralRe: Getting web service server URL at runtime... Pin
led mike31-Mar-08 7:28
led mike31-Mar-08 7:28 
QuestionWebServices Question.. Pin
som.nitk29-Mar-08 3:25
som.nitk29-Mar-08 3:25 
GeneralRe: WebServices Question.. Pin
Guffa31-Mar-08 1:24
Guffa31-Mar-08 1:24 
GeneralRe: WebServices Question.. Pin
som.nitk31-Mar-08 7:54
som.nitk31-Mar-08 7:54 
GeneralRe: WebServices Question.. Pin
Guffa31-Mar-08 15:04
Guffa31-Mar-08 15:04 
QuestionRe: WebServices Question.. Pin
ptr2void1-Apr-08 1:11
ptr2void1-Apr-08 1:11 
GeneralRe: WebServices Question.. Pin
Guffa1-Apr-08 9:18
Guffa1-Apr-08 9:18 
GeneralCan't load proxy class created via "Add Web Reference..." Pin
bwilhite28-Mar-08 10:36
bwilhite28-Mar-08 10:36 
GeneralRe: Can't load proxy class created via "Add Web Reference..." Pin
Shog928-Mar-08 15:29
sitebuilderShog928-Mar-08 15:29 
GeneralRe: Can't load proxy class created via "Add Web Reference..." Pin
bwilhite29-Mar-08 1:54
bwilhite29-Mar-08 1:54 
GeneralInquiry about program Pin
ibrahim123456789028-Mar-08 9:47
ibrahim123456789028-Mar-08 9:47 
GeneralRe: Inquiry about program Pin
Bradml28-Mar-08 12:59
Bradml28-Mar-08 12:59 
GeneralRe: Inquiry about program Pin
Eytukan30-Mar-08 5:48
Eytukan30-Mar-08 5:48 
GeneralRe: Inquiry about program Pin
Bradml30-Mar-08 20:52
Bradml30-Mar-08 20:52 
QuestionCould you Inspire Me? Pin
sa3sa327-Mar-08 21:13
sa3sa327-Mar-08 21:13 

General General    News News    Suggestion Suggestion    Question Question    Bug Bug    Answer Answer    Joke Joke    Praise Praise    Rant Rant    Admin Admin   

Use Ctrl+Left/Right to switch messages, Ctrl+Up/Down to switch threads, Ctrl+Shift+Left/Right to switch pages.