Rails application on Solaris OS

Hello,

I'm thinking to build an application that will work directly with the
Solaris operating system. It will be consisted of a REST-ful
architecture to provide customization and different interactions with
Solaris OS.
Basically my data source would be the Solaris OS. I'm wondering is it
worth trying to build this in Rails? Since the application is not
database driven i'm starting to question myself if not all the amazing
functionality provided by ROR becomes obsolete like object relations and
all the Active Record design ?
Any suggestions would be more than appreciated. Thank in advance.

Vadim Comanescu

Vadim Comanescu wrote in post #957889:

Hello,

I'm thinking to build an application that will work directly with the
Solaris operating system. It will be consisted of a REST-ful
architecture to provide customization and different interactions with
Solaris OS.
Basically my data source would be the Solaris OS. I'm wondering is it
worth trying to build this in Rails? Since the application is not
database driven i'm starting to question myself if not all the amazing
functionality provided by ROR becomes obsolete like object relations and
all the Active Record design ?

Particularly with Rails 3 (now that ActiveModel's been abstracted), you
don't necessarily need to use a DB to get ActiveRecord-like features.

But I agree that a priori, this seems like a strange use case for Rails.
Sinatra or something else might be more appropriate...

...or why not just use Webmin?

What is this application supposed to do in detail?

Any suggestions would be more than appreciated. Thank in advance.

Vadim Comanescu

Best,

Marnen Laibow-Koser wrote in post #957899:

Vadim Comanescu wrote in post #957889:

Hello,

I'm thinking to build an application that will work directly with the
Solaris operating system. It will be consisted of a REST-ful
architecture to provide customization and different interactions with
Solaris OS.
Basically my data source would be the Solaris OS. I'm wondering is it
worth trying to build this in Rails? Since the application is not
database driven i'm starting to question myself if not all the amazing
functionality provided by ROR becomes obsolete like object relations and
all the Active Record design ?

Particularly with Rails 3 (now that ActiveModel's been abstracted), you
don't necessarily need to use a DB to get ActiveRecord-like features.

But I agree that a priori, this seems like a strange use case for Rails.
Sinatra or something else might be more appropriate...

...or why not just use Webmin?

What is this application supposed to do in detail?

Any suggestions would be more than appreciated. Thank in advance.

Vadim Comanescu

Best,
--
Marnen Laibow-Koser
http://www.marnen.org
marnen@marnen.org

Hi,

The application will be a web based application that will handle the
configuration of an opensolaris system and here it includes :
networking, active directory integration and other solaris
functionality. The data layer will be represented by the system itself.
Then the application will grow toward administrating the native zfs
filesystem and here i talk about managing large diskpools, nfs sharing,
iscsi sharing and integration with virtualization mechanisms as VMware.
What i'm trying to figure out is if Rails can provide me the ORM needed
for this kind of stuff or should am i doomed to build my own from
scratch. From what i see using the Solaris system as an Active Resource
in Rails it does not work considering that is not a REST service. So
this is bassicaly what i need to do and i'm just wondering if Rails is
suited for this kind of business logic.

Thanks for the prompt reply.

Vadim Comanescu wrote in post #957907:
[...]

Hi,

The application will be a web based application that will handle the
configuration of an opensolaris system and here it includes :
networking, active directory integration and other solaris
functionality.

[...]

Don't even bother building anything, then. Just use Webmin or one of
the many similar applications that's already out there.

Best,

Vadim Comanescu wrote in post #957907:
[...]

What i'm trying to figure out is if Rails can provide me the ORM needed
for this kind of stuff or should am i doomed to build my own from
scratch.

There's no R to build an ORM to. The standard Ruby library does provide
a decent filesystem interface, though.

Best,

Marnen Laibow-Koser wrote in post #957911:

Vadim Comanescu wrote in post #957907:
[...]

What i'm trying to figure out is if Rails can provide me the ORM needed
for this kind of stuff or should am i doomed to build my own from
scratch.

There's no R to build an ORM to. The standard Ruby library does provide
a decent filesystem interface, though.

Best,
--
Marnen Laibow-Koser
http://www.marnen.org
marnen@marnen.org

I was thinking of mapping every system resource in an entity (object) in
my application. Also considering that it will have a rich web interface
for configuration im thinking pure scripting just wont do it without a
backend server where the application runs. And it would be really hard
from what i'm guessing now to actually reflect the complex interactions
in the system without a well designed layered architecture for this.
That's why i was wondering about rails considering the MVC architecture
and the implementation of object aggregation like has_a or belongs_to or
any other relationships that might have helped me alot. But i guess
rails for this would be an overkill.

Thanks again.

Vadim Comanescu wrote in post #957914:
[...]

The main reason for which im trying to build this is for the
configuration of the native zfs filesystem on solaris - building
diskpools, handling iscsi sharing, integration with VMware and other
solutions for virtualization. And that is not present in webmin or any
other app that configures unix systems.

Can you do that from a high-level application? I don't know how Solaris
configuration works.

I was thinking of mapping every system resource in an entity (object) in
my application.

That might make sense.

Also considering that it will have a rich web interface
for configuration im thinking pure scripting

What do you mean by "pure scripting"?

just wont do it without a
backend server where the application runs.

Uh, what? Wouldn't the application just run on the box that it was
supposed to configure?

And it would be really hard
from what i'm guessing now to actually reflect the complex interactions
in the system without a well designed layered architecture for this.
That's why i was wondering about rails considering the MVC architecture
and the implementation of object aggregation like has_a or belongs_to or
any other relationships that might have helped me alot.

has_many and belongs_to are only meaningful with a relational database.
Ruby objects aggregate beautifully without these.

Don't be so dazzled by Rails that you forget what core Ruby offers.

But i guess
rails for this would be an overkill.

Well, ActiveRecord would be unnecessary (I think), which *probably*
means that Rails would be overkill...but try it! Start with something
like Sinatra and see how far you get; be prepared to switch to Rails (or
something else entirely) if necessary.

Thanks again.

Best,