Click here to Skip to main content
15,867,923 members
Home / Discussions / C#
   

C#

 
GeneralRe: GetHashCode vs. Equals Pin
scadaguy14-Jan-04 6:26
scadaguy14-Jan-04 6:26 
GeneralRe: GetHashCode vs. Equals Pin
balkanese15-Jan-04 21:46
balkanese15-Jan-04 21:46 
GeneralInternet downloading problem... Pin
profoundwhispers14-Jan-04 4:26
profoundwhispers14-Jan-04 4:26 
GeneralRe: Internet downloading problem... Pin
Heath Stewart14-Jan-04 4:56
protectorHeath Stewart14-Jan-04 4:56 
GeneralRe: Internet downloading problem... Pin
Kentamanos14-Jan-04 6:35
Kentamanos14-Jan-04 6:35 
GeneralRe: Internet downloading problem... Pin
Heath Stewart14-Jan-04 7:45
protectorHeath Stewart14-Jan-04 7:45 
GeneralRe: Internet downloading problem... Pin
Kentamanos14-Jan-04 9:05
Kentamanos14-Jan-04 9:05 
Generalremoting "newbie" questions Pin
Palladino14-Jan-04 2:24
Palladino14-Jan-04 2:24 
Hi,

I am implementing a application that uses remoting that is generating some doubts as to best practices, scalability possibility, round trips on the net and things like this. I would like to know which the "better" form of doing what needed.
(I am afraid of giving a shot in my foot! Wink | ;-) )

Grossly, I have the following assemblies (scenery for questions):

--------------------------

Model.dll - It contains the classes that model tables for classes and lines for collections - Distributed in the client and server.

IRules.dll - Interface for the rules that will be activated in the server (that accesses a DAL, and so, so...) - Distributed in the client and server.

Rules.dll - Implementation of the defined interfaces in IRules - Distributed in the server.

--------------------------

Considering these components, the classes would be something as:

[Serializable()]  
public class ModelCustomer  
{  
    public string Code;  
    public string Name;  
}  
  
public interface IRulesCustomer  
{  
    bool Insert(Model.ModelCustomer customer);  
}  
  
public class RulesCustomer  : MarshalByRefObject, IRules.IRulesCustomer  
{    
    public virtual bool Insert(Model.ModelCustomer customer)  
    {  
        //customer instance validation
        //Call DAL class and outher things
    }    
}  


--------------------------

In the server, my configuration file is it something as:

<configuration>  
   <system.runtime.remoting>  
      <application>  
         <channels>  
            <channel ref="http">  
                <serverProviders>			  
                    <formatter ref="binary" typeFilterLevel="Full"/>  
                </serverProviders>  
            </channel>  
         </channels>  
         <service>  
            <wellknown   
               mode="SingleCall" objectUri="RulesCustomer.rem"  
               type="Rules.RulesCustomer, Rules" />  
	    <activated type="Model.ModelCustomer, Model" />  
         </service>  
      </application>  
   </system.runtime.remoting>  
</configuration>  

--------------------------

In the client, he resembles with:

<configuration>  
  <system.runtime.remoting>  
    <application>  
      <channels>  
         <channel ref="http">  
            <clientProviders>			  
               <formatter ref="binary" />  
            </clientProviders>  
            <serverProviders>			  
                <formatter ref="binary" typeFilterLevel="Full"/>  
            </serverProviders>  
          </channel>  
      </channels>  
      <client>  
            <wellknown type="IRules.IRulesCustomer, IRules"  
                url="http://server:80/App/RulesCustomer.rem"   
            />  
      </client>  
      <client url="http://server:80/App">  
	<activated type="Model.ModelCustomer, Model" />  
      </client>  
    </application>  
  </system.runtime.remoting>  
</configuration>  

--------------------------

Finally, what happens following: I am activating the model object in the "client" (it will receive yours state of UI/UserProcess) and the rules object in the "server". After passing the values of UI for properties of model object, I call the method insert of rule object passing the model object as parameter.

The doubts can be summarized like this:

1 - Will it be that to activate the model object in the client it harms the scalability of the application?
2 - Will it be that to activate the model object in the client it will force more round trip trips to the server of the one what the necessary (or advisable)?
3 - Will it be that a collection to come back (CollectionBase) for one of the methods of the class of rules it is viable?
4 - Will it be that I should activate everything in the server?


Thank you in advance and excuse me for the VERY long question,




Marcelo Palladino
Brazil
GeneralRe: remoting &quot;newbie&quot; questions Pin
LongRange.Shooter14-Jan-04 3:07
LongRange.Shooter14-Jan-04 3:07 
GeneralRe: remoting &quot;newbie&quot; questions Pin
LongRange.Shooter14-Jan-04 3:23
LongRange.Shooter14-Jan-04 3:23 
GeneralRe: remoting &quot;newbie&quot; questions Pin
Palladino14-Jan-04 8:13
Palladino14-Jan-04 8:13 
GeneralRe: remoting &quot;newbie&quot; questions Pin
LongRange.Shooter14-Jan-04 10:46
LongRange.Shooter14-Jan-04 10:46 
GeneralRe: remoting &quot;newbie&quot; questions Pin
Palladino15-Jan-04 1:36
Palladino15-Jan-04 1:36 
GeneralRe: remoting &quot;newbie&quot; questions Pin
LongRange.Shooter15-Jan-04 2:55
LongRange.Shooter15-Jan-04 2:55 
GeneralRe: remoting &quot;newbie&quot; questions Pin
LongRange.Shooter15-Jan-04 3:24
LongRange.Shooter15-Jan-04 3:24 
GeneralRe: remoting &quot;newbie&quot; questions Pin
Palladino15-Jan-04 5:43
Palladino15-Jan-04 5:43 
GeneralDebugging Pin
jyoti doiphode13-Jan-04 23:58
jyoti doiphode13-Jan-04 23:58 
GeneralRe: Debugging Pin
Heath Stewart14-Jan-04 4:41
protectorHeath Stewart14-Jan-04 4:41 
GeneralFinding names of local user accounts Pin
EnkelIk13-Jan-04 23:46
EnkelIk13-Jan-04 23:46 
GeneralRe: Finding names of local user accounts Pin
Mazdak14-Jan-04 2:51
Mazdak14-Jan-04 2:51 
GeneralRe: Finding names of local user accounts Pin
EnkelIk14-Jan-04 4:54
EnkelIk14-Jan-04 4:54 
GeneralRe: Finding names of local user accounts Pin
Mazdak14-Jan-04 8:20
Mazdak14-Jan-04 8:20 
GeneralReversible Frames on Windows Forms Pin
occcy13-Jan-04 22:22
occcy13-Jan-04 22:22 
GeneralRe: Reversible Frames on Windows Forms Pin
Heath Stewart14-Jan-04 4:14
protectorHeath Stewart14-Jan-04 4:14 
QuestionHow use Ms treeView In asp.net Pin
Old Gun13-Jan-04 22:03
Old Gun13-Jan-04 22:03 

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.