Beggars the question why?
(I’m assuming you already have a legacy .NET/NHibernate back-end you
want to use otherwise this looks like a fine can of worms to open. Why
complicate matters with multiple environments when RoR (and .NET
actually but not as fast or fun) will do it all for you?)
We were thinking that compiled dll’s and .net will be faster than
interpreted RoR \ Ruby and also we have much more experience of C# than
Ruby \ RoR.
We dont like asp.net and the .net code behind style of web development.
Do you really think that Ruby can compete with C# in terms of speed and
breadth of functionality when used to write busines classes.
I am in the process of redesigning a VB6 windows app with 150 tables
500k LOC into a modern n-tier browser based app.
BOb
ntollervey wrote:
Beggars the question why?
(I’m assuming you already have a legacy .NET/NHibernate back-end you
want to use otherwise this looks like a fine can of worms to open. Why
complicate matters with multiple environments when RoR (and .NET
actually but not as fast or fun) will do it all for you?)
When run in production mode using apache etc… your rails application
will be started as several threads at a point like the Application_Start
event in .NET. Only in development and testing mode is the Rails
application continuously re-interpreted for each request. There are lots
of good blog posts and articles about RoR performance and enhancements
thereof (caching being the first thing to come to mind) floating around
the Internet.
With regard to business-classes, you already have a head start with
Active-Record. Extend these classes to include whatever “additional”
functionality you require. But, as is usually the case with RoR, someone
has thought of this already and there are all sorts of mix-ins and built
in methods that will let you extend active-record to suit your
requirements. As a professional C# dev (by day, RoR by night ) I’d
say active-record beats faffing about with ADO (nice though ADO is) and
really does save time.
access and business processes, but is there a better way ?
If you find a better way, I’d be interested in hearing about it. I
currently have
an app running like this:
RoR --SOAP--> C# --Proprietary Assembly--> Proprietary Data Store
I briefly looked at embedding Mono as a Ruby extension so I could try to
load the assembly and talk directly to the data store; but, didn’t think
it
was worth the effort since I don’t know how to use the proprietary API
anyways.
The setup as is works pretty well from the RoR end of things; I had to
do more work on my model, since I lose ActiveRecord’s magic. But, it
was actually much easier than I anticipated to do so. I mimicked
ActiveRecord’s methods in my SOAP model and was able to hook my
view and controller up to a MySQL model to make it easier for testing
and development and then back to the SOAP model for production.
(Actually production is currently running on the MySQL backend
because,) The only problem so far is that the webservice was very
slow once it actually had more than a few records. Next week we should
have an updated web service deployed that, I’m told, is orders of
magnitude faster.
I haven’t done this with .NET, but you might investigate lightweight
technologies like JSON, Hessian, Burlap, etc. as alternatives to SOAP
for communicating between the layers.