»
S
I
D
E
B
A
R
«
Evejob Project Management Part #2: Design goals
Nov 30th, 2009 by evereq

Small list of main design goals and principles in Evejob Project

1. Support of “Open Standards”

2. Support for I18N

Evejob Projects will support Internationalization (I18N) and allow users to select site language in addition to auto detect browser features. Major requirement in I18N – support of right to left languages and page designs in addition to left to right (this will allow to made Hebrew sites powered by Evejob, for example).

3. Cloud hosting support

There will be additional projects (EvejobDJG, EvejobAzNET, EvejobRoRG, EvejobGoGG) that will be specially designed to be hosted in various clouds like Google App Engine or Azure
… work in progress under this post …

Google “Go” become “issue 9″
Nov 19th, 2009 by evereq

Today I get a talk with my friend regarding new programming language emerged by Google with “interesting” name  “Go”.

Actually we both agree that we don’t see any reason to invent another “low level” / “middle” level compiled programming language… with Nothing NEW inside (see notes at the end of the post)! Just reuse of best practices, but with a LOT of limitations compared with C++ for example  (just take a look here for some comparison information – most impressive that Google decide: “Go does not have classes with constructors or destructors. Instead of class methods, a class inheritance hierarchy, and virtual functions, Go provides interfaces, which are discussed in more detail below. Interfaces are also used where C++ uses templates.”… very strange for me… I can agree with C# approach for such details, but seems Google approach is too much!!! I note sure is it really OOP  or not if you have only interfaces in hands…. when I do everyday development in C#, at least few times per day I not happy that I don’t have true multiple inheritance, what developers will say about “Go” if they start use it everyday??? )!

Personally I think that if Google want invent some “own” programming language (and only in case if they really want OWN…) they need to take a look into high (or very high) level multi paradigm languages like  F# or Scala (or at least on Groovy with his meta programming features for example) and does not invent another “c/c++” or “Python” inspired language !

But what is most interesting and curious is that Google give the name for new language exactly same like another person name his language few years ago!  To be more concrete, go to the issue 9 page in google issues tracking page for new language:

“Issue 9: I have already used the name for *MY* programming language”

Amazing! Just read comments! Ha ha ha! Never see something like this before regarding programming languages! Google took this name and even not “google” for it ;-) ! Amazing stupid mistake! Yes, even companies like Google with best and talented people made such stupid mistakes! Actually, I not sure that name “Go” anyway is a good name for such language (and not only me think this way – read comments to issue 9 to get many examples!)…

Even for me, with average (or even low) level of English it looks strange that something that they promote as “fast” have the name “Go” (as we all know most of things that “Go” is slow by default)… Why they not name it “Run” , if they want that this language actually “run” ?! Or like many people suggest “Goo” (from Google) ?

Anyway, it looks really curious…….. :)

Hope this will just “push” Google to develop BETTER OWN language (it MUST be HIGH level or VERY HIGH level language for sure!!!) and probably select for it BETTER name!

Notes:
1) in this post I follow latest definitions for  “low level” and “high level” languages… Sure long time ago, “low level” was assembler and C was “high level” language! But currently, it looks like languages like C become really “low level” also! You can check for example following Wikipedia article to get more information).  After reading most of information on Go language website, I still not sure can we call this language “Object Oriented” for example… In most areas approach of Google looks minimum “strange”… Except maybe how they implement concurrency… Maybe I just need to try to code something on it to get  better understanding?)
2) Please note that I DON’T describe “Go” language as “bad” language. Instead I just put it to “low level” or “middle level” where it looks perfectly!  Sure Google will found A LOT of ways how to use this language (and I think maybe already found such ways – for example to embed it in Chrome – read more here) and will “push” usage of  this language inside Google and sure outside! And Google really have resources to do this! And some people will probably LIKE new simple but speed language! What I just NOT happy is that this language is NOT really high level language (NO Generics for example, at least by now!). Sure it’s just first release, maybe Google will improve it… but  Google likes “minimalism” style, so….. Anyway, let’s just wait a little! Maybe they change language name and Universe! ;-)

Amazon AWS Big News for developers
Nov 13th, 2009 by evereq

Because I build Evejob multi-platform project with support of Cloud deployment scenarios (currently for Google App Engine and Microsoft Azure) and I am sure that best Web software must be ready to be deployed in Cloud(s), it was very interesting to read latest announcement from Amazon: “… AWS Software Development Kit (SDK) for .NET Now Available… “.

Sure it’s just a beginning for Amazon in development of real .NET SDK, but even with this version we can quickly build .NET applications that tap into AWS Cloud.   Yes,  even before developers have good libraries to build such applications, but now looks like we have first “standard” API from Amazon and this fact is very important!

For example, for Ruby there is no such official SDK (or Ruby gem), and developers can choice from few available gems (right_aws, amazon-ec2 or AWS:S3 to name just few).  The same situation for Java - available a lot of “community” libraries, but no official SDK… (ok, ok, for Java we have at least official AWS Toolkit for Eclipse, but Toolkit it is not SDK!!!).

But why it is important to have official “language specific” SDK?

Well, first of all, now because Amazon have few BIG rivals, like Google App Engine (and we know that Google DO have official SDKs, more so, for both Python and Java!) and Microsoft Azure (sure Microsoft always have SDKs – it a BIG plus for Microsoft!).

Also it is important for developers, so they know that if they take some library and put this library as “base” for communications with a Cloud, they will not need to dial with changes in API in case of library author decide to drop development! It is important to have SDK that will be up to date with company services (Amazon in our case), just because we developers want to be SAFE! Sure it is good if there are a lot of open source libraries that EXTEND SDK some way, but it’s just “add-ons” and can’t replace real official SDK!

So it is really BIG day for Amazon and .NET developers – first official “language specific” SDK, and for .NET!!! What will be answer from Microsoft Azure that is still in “Beta”? ;-)

Note: in this post I mean “language specific” SDK, not just common SDK that list API for Web Services  with samples how to use them for example, etc… Because most of they time developers dial with some specific language, it is important for services like AWS to provide language specific SDKs so developers can really quickly and “safely” create applications using such “language specific” SDKs! Hope you understand what I mean ;-)

Evejob Project Hostings
Oct 31st, 2009 by evereq
Evejob Development Environment Installation Part #5: Ruby, JRuby and Rails + AppEngine Installation
Oct 28th, 2009 by evereq

Ruby installation

Let’s start from Ruby installation. We can download Windows One-Click Installer from http://rubyforge.org/frs/?group_id=167, for example ruby186-27_rc2.exe

During installation, make sure that you select at least “Enable RubyGems” option:

RubyInstallation

You can leave default installation folder (C:\Ruby).

Ones you finish installation, you can run both “ruby” and “gem”  from withing your command line.

So it’s time to install Rails, just type in command prompt:

gem install rails

and wait few minutes to finish installation.

JRuby installation

Download installation package from http://jruby.org/download. We will need binary Windows version, for example JRuby 1.4.0RC1 Binary .zip. Extract folder content to C:\JRuby folder and add path to the JRuby to your PATH variable:

JRubyPath

Let’s test installation:

JRubyTestInstallation

Now both Ruby and JRuby installed.

The problems starts when we will try to simultaneously use them (side by side)… First of all, make sure that you delete RUBYOPT environment variable (because it seems like JRuby gems did not work correctly if this variable setup). Now you can invoke each “gem” using following commands:

For Ruby:   ruby -S gem

For JRuby:  jruby -S gem

For example this is what I get on my machine:

GemSideBySide

Note: it is actually not a big problem that I had 2 different versions of Gem on my machine – both versions (1.3.1 and 1.3.5 works well for me… update of gem 1.3.1 fails for some reasons on my machine, so I decide to leave this for now…)

One small thing to do: it is possible that you have old version 1.3.1 of RubyGems like me (in the moment when I write this, latest version is 1.3.5 like was installed for JRuby). If we leave it, we can face some problems in future with IDEA etc, so let’s just update it:

UpdateRubyGems

Also, let’s install jruby-openssl (IDEA generate Error if this gem not installed):

OpenSSLforJRuby

Rails Installation

Next step is installation of Rails – just type following commands (it is better to just install Rails twice than to share same installation for both Ruby and JRuby):

ruby -S gem install rails
jruby -S gem install rails

EvejobRoR and EvejobRoRG Project

We going to create 2 separate projects now:

EvejobRoR – will use Rails build in ActiveRecord + MySQL database

EvejobRoRG – will use App Engine hosting, datastore and Google Accounts for user authentication APIs

Let’s start from more simple EvejobRoR:

cd c:\evejob
rails EvejobRoR -d mysql

Now let’s open this “template” project in IDEA:

File -> New Project -> Create project from scratch:

CreateRubyProjectInIDEA

Change here “Project files location” to the “C:\evejob\EvejobRoR”, select “Ruby Module” and press next (see screenshot above)

Now you need to specify the Ruby SDK (current version of IDEA can’t detect SDK locations from environment variables). Press “Configure…” button and press “+” button in “Configure JDK” window:

AddRubySDK

Select “Ruby SDK” in popup and than select Ruby interpreter path:

SetRubyPath

I Hope you will get something like this:

RubySDKAddedToIDEA

If so, just press “OK” and continue IDEA project creation Wizard:

ContinueRubyProjectCreationWizardInIDEA

Select “Ruby on Rails” on next screen and press “More…”  for Rails Facet configuration:

SelectRubyOnRailsTechnology

RailsFacetSettings

Make sure that you select “Use existing Rails application” and “Preconfigure for selected database” to “mysql” like (see picture above)

Now fill free to finish project creation Wizard. Done! We get EvejobRoR project loaded into IDEA.

Same steps we need to made for EvejobRoRG project, with small difference that this time we need to add JRuby SDK, instead of Ruby SDK like before and that we don’t want to support mysql as we are going to use Google App Engine API instead.

So, first type:

cd c:\evejob
rails EvejobRoRG

Then same like before, create new project in IDEA, put here “C:\evejob\EvejobRoRG” path and in “Specify the Ruby SDK” press “Configure…” and add JRuby SDK:

JRubySDKInIDEA

After made same steps like was done for EvejobRoR project, just make sure that you unselect “Preconfigure for selected database” check box in Rails Facet Settings dialog and process steps like before to finish Wizard.

Hopefully you get EvejobRoRG project opened in IDEA!

Prepare JRuby / Rails for Google App Engine

Google App Engine runs Java applications, so we need to make sure that we can assemble our JRails applications into a Java Web Archive (.war). To do such tasks easy, let’s first install “warbler” gem:

jruby -S gem install warbler

Now it is time to check that you add Java JDK path to windows PATH environment variable (because “warbler” gem use JDK):

JDKPathToPATHVariable

Next step, to run following commands from application root folder (c:\evejob\EvejobRoRG):

jruby -S warble pluginize
jruby -S warble config

(make sure you type “warble”, not “warbler” that is just Gem name)

Now you can just check that “Warbler” works:

jruby -S warble

As result you must see EvejobRoRG.war file generated in application root folder (c:\evejob\EvejobRoRG)

We can’t use this .war file directly for Google App Engine for few reasons, but at least we see that we can get some .war file :)

I specially not use all appengine-jruby project gems for few reasons:

  • google-appengine gem install own “tuned” version of JRuby that we want to avoid for reasons, for example for quick updates as we don’t want to depend on this special version of JRuby etc (means that project must be installed using Ruby, not JRuby! And only after installation it download and install customized, ‘frozen’ version of JRuby)
  • google-appengine helps to run JRuby on Google App Engine, but not to run Rails on Google App Engine ! :) All problems related to Rails on App Engine are still exists (read more at http://code.google.com/p/appengine-jruby/wiki/RunningRails)

But what I do use is one of the gems from appengine-ruby project – “appengine-apis”, so let’s install it:

jruby -S gem install appengine-apis

Read this for now to get more information about Rails and Google App Engine specific things:

http://olabini.com/blog/2009/04/jruby-on-rails-on-google-app-engine/

http://www.railshacks.com/2009/4/25/run-your-ruby-on-rails-app-on-google-app-engine

We will get back to this later…

»  Substance: WordPress   »  Style: Ahren Ahimsa
© Copyright 2008–2009 EvereQ.com All rights reserved.