473,804 Members | 3,113 Online
Bytes | Software Development & Data Engineering Community
+ Post

Home Posts Topics Members FAQ

remoting and placing DLLs in sub-directory

Hello!

I have a simple client/server plugin based architecture. I place all the
plugins in \plugins sub-directory on both, server and the client. Each DLL
has implemented two interfaces.. on for client side and other for server
side. On the server I dinamically load all the assemblies from that
sub-directory and register the objects that implement IBuddyPluginSer verSide
as SAOs. On the client I do the same for those that implement
IBuddyPluginCli entSide . I also Activate the server side SAO and pass it as
reference to the ClientSide object.

This is my method for registering SAOs on the server:

private void RegisterPlugins ()
{
string dir = "plugins\\" ;

foreach(string file in new FilesEnumerator (dir, "*.dll"))
{
Assembly asm = Assembly.LoadFr om(dir + file);
foreach(Type t in asm.GetTypes())
{
if(MyLib.Tools. ImplementsInter face(t,
typeof(IBuddyPl uginServerSide) ))
{
IBuddyPluginCom mon common =
(IBuddyPluginCo mmon)MyLib.Tool s.InstantiateOb ject(asm,
typeof(IBuddyPl uginCommon));

RemotingConfigu ration.Register WellKnownServic eType(t,
common.GetWellK nownServerName( ),
WellKnownObject Mode.Singleton );
}
}
}
}

All good... but when I make a first call to one of SAOs methods from the
client, I get the "plugin1.dl l" FileNotFound exception on the server. When I
place the dll in server root, it works. So obviously, the server forgets,
that the assembly resides in the sub-directory and on the first call it
wants to find it in root. The server remembers the name of the plugin
though.. but it assumes that it resides in the root. How could I solve this?

And also.. did anyone figure out yet why the server is inaccessible when the
connection to the LAN/WAN drops even if client and server are on the same
machine?
I have the description of the problem/bug here:

http://www.david13.com/cases/DotNet/...Local-Machine/
Thank you very much!!

David
Nov 17 '05 #1
0 1124

This thread has been closed and replies have been disabled. Please start a new discussion.

Similar topics

0
302
by: Trokey | last post by:
Here's my setup: Component A: .NET exe acting as a .NET remoting server. The channel type is tcp. Component B: .NET assembly acting as a .NET remoting client with event handlers for server broadcasts. Also exposes an interface to COM. Component C: C++ out of process COM exe which uses component B via COM. Component D: C++ exe which uses component C via COM. Here's the problem: While A is running, D is started, which starts C, which
0
1490
by: Henrik Nordgren | last post by:
Im trying to build a simple chat app... here is the code: server visual basic code:-------------------------------------------------------------------------------- Public Class ChatServer Public Sub New()
2
2843
by: matthew_glen_evans | last post by:
Hi there, Quick one about interfaces in c#. It seems that it is illegal to declare types within an interface. I was quite used to doing this in VB.net where the interface can define a clients remoting interface and object model. eg..
0
1026
by: Pushpendra | last post by:
Hi, I have created 2 dlls (Irefdata.dll, RefdataServer.dll) and one remoting service RefDataService.exe. Irefdata is ainterface and I have implemented this interface in refdataserver. I have referenced Irefdata & Refdataserver in the service (Refdataservice.exe) so that I can register this service on tcp channel and access the methods of refdataserver. If I reference these dll without deplying these in global assembly cache (means copy...
9
2102
by: Nak | last post by:
Hi there, I have been messing around with remoting in an attempt to create a "shared application" as mentioned in another thread by that name. I have created a singleton object just like the example in the 101 VB.NET examples. It works great, only 1 instance ever gets created and is shared by each client. I have a few questions though, * Can the singleton contain events? In such a way that when the
6
1627
by: AMDRIT | last post by:
Hello folks, I appologize for the cross post, but I really need an answer on this: I do not think that I am seeing the whole picture here. I would like to create a windows service and a management console, using Visual Basic 2003. The windows service part, I think, is easy enough. I am more concerned with the remoting aspect of the project. Below is the general idea of my approach, please correct my where I am wrong.
8
4256
by: sandy82 | last post by:
I coded a simple example in c# In which their is a client and a server using a dll . I am confused on the Point that u have to use the .dll on both sides .Cant we have a solution of having a dll on server side and the client calling the remote service . Also Can any1 tell that whats the Practical use of remoting .How u differentiate btw remoting and Web Services
0
1132
by: Jason | last post by:
Ok, for the life of me, I just don't understand what's going on. I want to use remoting to send messages from a windows service to a windows form app, but I just can't get it to work. So, here's what I have so far. I created a small, remotable object that inherits from MarshalByRefObject. It has a public subroutine that raises an event with a message attached: Public Delegate Sub TestServiceEventHandler(ByVal Message As String) ...
3
1571
by: JB | last post by:
Hi All, I've discovered a strange behaviour with Object parameters passed ByVal via remoting and I'm wondering if anybody could shed some light on this. In a non remoting function call, when a object (as opposed to a value type like Integer, Boolean, etc) is passed as a ByVal parameter, it's content can be modified. This is somehow "strange", but I've lived with that so far.
0
967
by: ShaneN | last post by:
I'm working on a remoting application where the client only references interfaces for all wellknown objects. I currently have an object, Request being exposed: Imports System.Runtime.Remoting Imports System.Runtime.Remoting.Channels Imports System.Runtime.Remoting.Channels.http Imports Central.Remotable Public Class SyncService
0
10578
Oralloy
by: Oralloy | last post by:
Hello folks, I am unable to find appropriate documentation on the type promotion of bit-fields when using the generalised comparison operator "<=>". The problem is that using the GNU compilers, it seems that the internal comparison operator "<=>" tries to promote arguments from unsigned to signed. This is as boiled down as I can make it. Here is my compilation command: g++-12 -std=c++20 -Wnarrowing bit_field.cpp Here is the code in...
0
10332
jinu1996
by: jinu1996 | last post by:
In today's digital age, having a compelling online presence is paramount for businesses aiming to thrive in a competitive landscape. At the heart of this digital strategy lies an intricately woven tapestry of website design and digital marketing. It's not merely about having a website; it's about crafting an immersive digital experience that captivates audiences and drives business growth. The Art of Business Website Design Your website is...
1
10321
by: Hystou | last post by:
Overview: Windows 11 and 10 have less user interface control over operating system update behaviour than previous versions of Windows. In Windows 11 and 10, there is no way to turn off the Windows Update option using the Control Panel or Settings app; it automatically checks for updates and installs any it finds, whether you like it or not. For most users, this new feature is actually very convenient. If you want to control the update process,...
0
9152
agi2029
by: agi2029 | last post by:
Let's talk about the concept of autonomous AI software engineers and no-code agents. These AIs are designed to manage the entire lifecycle of a software development project—planning, coding, testing, and deployment—without human intervention. Imagine an AI that can take a project description, break it down, write the code, debug it, and then launch it, all on its own.... Now, this would greatly impact the work of software developers. The idea...
0
6853
by: conductexam | last post by:
I have .net C# application in which I am extracting data from word file and save it in database particularly. To store word all data as it is I am converting the whole word file firstly in HTML and then checking html paragraph one by one. At the time of converting from word file to html my equations which are in the word document file was convert into image. Globals.ThisAddIn.Application.ActiveDocument.Select();...
0
5522
by: TSSRALBI | last post by:
Hello I'm a network technician in training and I need your help. I am currently learning how to create and manage the different types of VPNs and I have a question about LAN-to-LAN VPNs. The last exercise I practiced was to create a LAN-to-LAN VPN between two Pfsense firewalls, by using IPSEC protocols. I succeeded, with both firewalls in the same network. But I'm wondering if it's possible to do the same thing, with 2 Pfsense firewalls...
0
5651
by: adsilva | last post by:
A Windows Forms form does not have the event Unload, like VB6. What one acts like?
1
4300
by: 6302768590 | last post by:
Hai team i want code for transfer the data from one system to another through IP address by using C# our system has to for every 5mins then we have to update the data what the data is updated we have to send another system
2
3820
muto222
by: muto222 | last post by:
How can i add a mobile payment intergratation into php mysql website.

By using Bytes.com and it's services, you agree to our Privacy Policy and Terms of Use.

To disable or enable advertisements and analytics tracking please visit the manage ads & tracking page.