Monday June 30, 2008
Substruct on GlassFish v3 - Ruby-on-Rails E-Commerce Application
![]() |
Substruct is an open-source E-Commerce project written using Ruby-on-Rails framework. It provides a simple e-commerce platform, content management system and customer response system - all in one. |
| ~/samples/jruby
>gunzip -c
substruct_rel_1-0-a3.tar.gz | tar xvf - substruct_rel_1-0-a3/ substruct_rel_1-0-a3/app/ substruct_rel_1-0-a3/app/controllers/ substruct_rel_1-0-a3/app/controllers/application.rb . . . substruct_rel_1-0-a3/vendor/rails/railties/test/rails_info_test.rb substruct_rel_1-0-a3/vendor/rails/railties/test/secret_key_generation_test.rb substruct_rel_1-0-a3/vendor/rails/Rakefile substruct_rel_1-0-a3/vendor/rails/release.rb |
| ~/samples/jruby
>~/testbed/jruby-1.1.2/bin/jruby
-S gem install RedCloth fastercsv mime-types mini_magick ezcrypto
jruby-openssl
--no-ri --no-rdoc JRuby limited openssl loaded. gem install jruby-openssl for full support. http://wiki.jruby.org/wiki/JRuby_Builtin_OpenSSL Bulk updating Gem source index for: http://gems.rubyforge.org/ Successfully installed RedCloth-3.0.4 Successfully installed fastercsv-1.2.3 Successfully installed mime-types-1.15 Successfully installed rubyforge-1.0.0 Successfully installed hoe-1.5.3 Successfully installed mini_magick-1.2.3 Successfully installed ezcrypto-0.7 Successfully installed jruby-openssl-0.2.3 8 gems installed |
| ~/samples/jruby/substruct_rel_1-0-a3
>~/testbed/jruby-1.1.2/bin/jruby
-S rake db:create (in /Users/arungupta/samples/jruby/substruct_rel_1-0-a3) [SUBSTRUCT WARNING] Mail server settings have not been initialized. Check to make sure they've been set in the admin panel. |
| ~/samples/jruby/substruct_rel_1-0-a3
>~/tesbted/jruby-1.1.2/bin/jruby
-S rake substruct:db:bootstrap (in /Users/arungupta/samples/jruby/substruct_rel_1-0-a3) Checking requirements... Initializing database... [SUBSTRUCT WARNING] Mail server settings have not been initialized. Check to make sure they've been set in the admin panel. -- create_table("content_nodes", {:force=>true}) -> 0.3020s -- add_index("content_nodes", ["name"], {:name=>"name"}) -> 0.0140s -- add_index("content_nodes", ["type", "id"], {:name=>"type"}) . . . -- initialize_schema_information() -> 0.0200s -- columns("schema_info") -> 0.0650s Clearing previous data... Removing all sessions... Loading default data... ...done. ================================================================================ Thanks for trying Substruct 1.0.a3 Now you can start the application with 'script/server' visit: http://localhost:3000/admin, and log in with admin / admin. For help, visit the following: Official Substruct Sites - http://substruct.subimage.com - http://code.google.com/p/substruct/ Substruct Google Group - http://groups.google.com/group/substruct - Subimage LLC - http://www.subimage.com |
| ~/samples/jruby
>~/testbed/jruby-1.1.2/bin/jruby
-S glassfish_rails substruct_rel_1-0-a3 May 28, 2008 1:47:46 PM com.sun.enterprise.glassfish.bootstrap.ASMain main INFO: Launching GlassFish on HK2 platform May 28, 2008 1:47:46 PM com.sun.enterprise.glassfish.bootstrap.ASMainHK2 findDerbyClient INFO: Cannot find javadb client jar file, jdbc driver not available May 28, 2008 1:47:47 PM com.sun.enterprise.v3.services.impl.GrizzlyProxy start INFO: Listening on port 3000 May 28, 2008 1:47:47 PM com.sun.enterprise.v3.services.impl.GrizzlyEmbeddedHttpConfigurator configureSSL WARNING: pewebcontainer.all_ssl_protocols_disabled May 28, 2008 1:47:47 PM com.sun.enterprise.v3.services.impl.GrizzlyEmbeddedHttpConfigurator configureSSL WARNING: pewebcontainer.all_ssl_ciphers_disabled May 28, 2008 1:47:47 PM com.sun.enterprise.v3.services.impl.GrizzlyProxy start INFO: Listening on port 3131 May 28, 2008 1:47:47 PM com.sun.enterprise.v3.services.impl.GrizzlyProxy start INFO: Listening on port 3838 May 28, 2008 1:47:48 PM com.sun.enterprise.v3.admin.adapter.AdminConsoleAdapter setContextRoot INFO: Admin Console Adapter: context root: /admin May 28, 2008 1:47:48 PM com.sun.enterprise.rails.RailsDeployer registerAdapter INFO: Loading application substruct_rel_1-0-a3 at / May 28, 2008 1:47:48 PM INFO: Starting Rails instances May 28, 2008 1:47:56 PM com.sun.grizzly.jruby.RubyObjectPool$1 run INFO: Rails instance instantiation took : 8800ms May 28, 2008 1:47:56 PM com.sun.enterprise.v3.server.AppServerStartup run INFO: Glassfish v3 started in 10403 ms |

| <a href="http://glassfish.org"><%= image_tag('/images/glassfish-logo.gif', :alt => 'GlassFish') %></a> |


Posted by Arun Gupta in web2.0 | Comments[5]
|
|
|
|
|
Friday June 27, 2008
![]() |
Eclipse
Ganymede is the annual release of Eclipse projects; this year
including 23 projects. Screencast
#WS6 showed how GlassFish v2 can be easily registered and
started within an earlier version of Eclipse (3.3 specifically). Eclipse is now 3.4 (as part of Ganymede) and GlassFish v3 is blazing the community with it's modular, embeddable and extensible architecture. |

















Posted by Arun Gupta in General | Comments[51]
|
|
|
|
|
Thursday June 26, 2008
TOTD #36: Deploy OSGi bundles in GlassFish using maven-bundle-plugin
GlassFish v3
is a modular (OSGi
compliant), embeddable (runs in-VM) and extensible (supports non-Java
apps) Application Server.
The extensible part is demonstrated
by deployment of Rails and Grails applications. An example of
embeddability is an in-VM
Servlet. This blog demonstrates how a simple OSGi bundle
can be easily created using Maven
Bundle Plugin and deployed on v3 trunk.
| ~/samples/v3 >mvn
archetype:create -DarchetypeGroupId=org.apache.maven.archetypes
-DgroupId=org.glassfish.samples.osgi.helloworld -DartifactId=helloworld [INFO] Scanning for projects... [INFO] Searching repository for plugin with prefix: 'archetype'. [INFO] Ignoring available plugin update: 2.0-alpha-3 as it requires Maven version 2.0.7 [INFO] Ignoring available plugin update: 2.0-alpha-2 as it requires Maven version 2.0.7 [INFO] Ignoring available plugin update: 2.0-alpha-1 as it requires Maven version 2.0.7 [INFO] ---------------------------------------------------------------------------- [INFO] Building Maven Default Project [INFO] task-segment: [archetype:create] (aggregator-style) [INFO] ---------------------------------------------------------------------------- [INFO] Setting property: classpath.resource.loader.class => 'org.codehaus.plexus.velocity.ContextClassLoaderResourceLoader'. [INFO] Setting property: velocimacro.messages.on => 'false'. [INFO] Setting property: resource.loader => 'classpath'. [INFO] Setting property: resource.manager.logwhenfound => 'false'. [INFO] ************************************************************** [INFO] Starting Jakarta Velocity v1.4 [INFO] RuntimeInstance initializing. [INFO] Default Properties File: org/apache/velocity/runtime/defaults/velocity.properties [INFO] Default ResourceManager initializing. (class org.apache.velocity.runtime.resource.ResourceManagerImpl) [INFO] Resource Loader Instantiated: org.codehaus.plexus.velocity.ContextClassLoaderResourceLoader [INFO] ClasspathResourceLoader : initialization starting. [INFO] ClasspathResourceLoader : initialization complete. [INFO] ResourceCache : initialized. (class org.apache.velocity.runtime.resource.ResourceCacheImpl) [INFO] Default ResourceManager initialization complete. [INFO] Loaded System Directive: org.apache.velocity.runtime.directive.Literal [INFO] Loaded System Directive: org.apache.velocity.runtime.directive.Macro [INFO] Loaded System Directive: org.apache.velocity.runtime.directive.Parse [INFO] Loaded System Directive: org.apache.velocity.runtime.directive.Include [INFO] Loaded System Directive: org.apache.velocity.runtime.directive.Foreach [INFO] Created: 20 parsers. [INFO] Velocimacro : initialization starting. [INFO] Velocimacro : adding VMs from VM library template : VM_global_library.vm [ERROR] ResourceManager : unable to find resource 'VM_global_library.vm' in any resource loader. [INFO] Velocimacro : error using VM library template VM_global_library.vm : org.apache.velocity.exception.ResourceNotFoundException: Unable to find resource 'VM_global_library.vm' [INFO] Velocimacro : VM library template macro registration complete. [INFO] Velocimacro : allowInline = true : VMs can be defined inline in templates [INFO] Velocimacro : allowInlineToOverride = false : VMs defined inline may NOT replace previous VM definitions [INFO] Velocimacro : allowInlineLocal = false : VMs defined inline will be global in scope if allowed. [INFO] Velocimacro : initialization complete. [INFO] Velocity successfully started. [INFO] [archetype:create] [INFO] Defaulting package to group ID: org.glassfish.samples.osgi.helloworld [INFO] ---------------------------------------------------------------------------- [INFO] Using following parameters for creating Archetype: maven-archetype-quickstart:RELEASE [INFO] ---------------------------------------------------------------------------- [INFO] Parameter: groupId, Value: org.glassfish.samples.osgi.helloworld [INFO] Parameter: packageName, Value: org.glassfish.samples.osgi.helloworld [INFO] Parameter: basedir, Value: /Users/arungupta/samples/v3 [INFO] Parameter: package, Value: org.glassfish.samples.osgi.helloworld [INFO] Parameter: version, Value: 1.0-SNAPSHOT [INFO] Parameter: artifactId, Value: helloworld [INFO] ********************* End of debug info from resources from generated POM *********************** [INFO] Archetype created in dir: /Users/arungupta/samples/v3/helloworld [INFO] ------------------------------------------------------------------------ [INFO] BUILD SUCCESSFUL [INFO] ------------------------------------------------------------------------ [INFO] Total time: 1 second [INFO] Finished at: Wed Jun 25 10:07:27 PDT 2008 [INFO] Final Memory: 5M/10M [INFO] ------------------------------------------------------------------------ |
| package
org.glassfish.samples.osgi.helloworld; import org.osgi.framework.BundleActivator; import org.osgi.framework.BundleContext; /** * Hello world! * */ public class App implements BundleActivator { public void start(BundleContext context) throws Exception { System.out.println("Hey!"); } public void stop(BundleContext context) throws Exception { System.out.println("Bye!"); } } |
| <project
xmlns="http://maven.apache.org/POM/4.0.0"
xmlns:xsi="http://www.w3.org/2001/XMLSchema-instance" xsi:schemaLocation="http://maven.apache.org/POM/4.0.0 http://maven.apache.org/maven-v4_0_0.xsd"> <modelVersion>4.0.0</modelVersion> <groupId>org.glassfish.samples.osgi.helloworld</groupId> <artifactId>helloworld</artifactId> <packaging>bundle</packaging> <version>1.0-SNAPSHOT</version> <name>helloworld</name> <url>http://maven.apache.org</url> <dependencies> <dependency> <groupId>junit</groupId> <artifactId>junit</artifactId> <version>3.8.1</version> <scope>test</scope> </dependency> <dependency> <groupId>org.apache.felix</groupId> <artifactId>org.osgi.core</artifactId> <version>1.0.0</version> </dependency> </dependencies> <build> <plugins> <plugin> <groupId>org.apache.felix</groupId> <artifactId>maven-bundle-plugin</artifactId> <extensions>true</extensions> <configuration> <instructions> <Export-Package>${pom.groupId}</Export-Package> <Bundle-SymbolicName>${pom.artifactId}</Bundle-SymbolicName> <Bundle-Activator>${pom.groupId}.App</Bundle-Activator> </instructions> </configuration> </plugin> </plugins> </build> </project> |
| ~/samples/v3/helloworld
>mvn
install [INFO] Scanning for projects... [INFO] ---------------------------------------------------------------------------- [INFO] Building helloworld [INFO] task-segment: [install] [INFO] ---------------------------------------------------------------------------- [INFO] [resources:resources] [INFO] Using default encoding to copy filtered resources. [INFO] [compiler:compile] [INFO] Compiling 1 source file to /Users/arungupta/samples/v3/helloworld/target/classes [INFO] [resources:testResources] [INFO] Using default encoding to copy filtered resources. [INFO] [compiler:testCompile] [INFO] Compiling 1 source file to /Users/arungupta/samples/v3/helloworld/target/test-classes [INFO] [surefire:test] [INFO] Surefire report directory: /Users/arungupta/samples/v3/helloworld/target/surefire-reports ------------------------------------------------------- T E S T S ------------------------------------------------------- Running org.glassfish.samples.osgi.helloworld.AppTest Tests run: 1, Failures: 0, Errors: 0, Skipped: 0, Time elapsed: 0.022 sec Results : Tests run: 1, Failures: 0, Errors: 0, Skipped: 0 [INFO] [bundle:bundle] [INFO] [install:install] [INFO] Installing /Users/arungupta/samples/v3/helloworld/target/helloworld-1.0-SNAPSHOT.jar to /Users/arungupta/.m2/repository/org/glassfish/samples/osgi/helloworld/helloworld/1.0-SNAPSHOT/helloworld-1.0-SNAPSHOT.jar [INFO] [bundle:install] [INFO] Parsing file:/Users/arungupta/.m2/repository/repository.xml [INFO] Installing org/glassfish/samples/osgi/helloworld/helloworld/1.0-SNAPSHOT/helloworld-1.0-SNAPSHOT.jar [INFO] Writing OBR metadata [INFO] ------------------------------------------------------------------------ [INFO] BUILD SUCCESSFUL [INFO] ------------------------------------------------------------------------ [INFO] Total time: 4 seconds [INFO] Finished at: Wed Jun 25 10:20:27 PDT 2008 [INFO] Final Memory: 22M/54M [INFO] ------------------------------------------------------------------------ |
| META-INF/MANIFEST.MF META-INF/ META-INF/maven/ META-INF/maven/org.glassfish.samples.osgi.helloworld/ META-INF/maven/org.glassfish.samples.osgi.helloworld/helloworld/ META-INF/maven/org.glassfish.samples.osgi.helloworld/helloworld/pom.properties META-INF/maven/org.glassfish.samples.osgi.helloworld/helloworld/pom.xml org/ org/glassfish/ org/glassfish/samples/ org/glassfish/samples/osgi/ org/glassfish/samples/osgi/helloworld/ org/glassfish/samples/osgi/helloworld/App.class |
| Manifest-Version: 1.0 Export-Package: org.glassfish.samples.osgi.helloworld;uses:="org.osgi. framework" Built-By: arungupta Tool: Bnd-0.0.255 Bundle-Name: helloworld Created-By: Apache Maven Bundle Plugin Bundle-Version: 1.0.0.SNAPSHOT Build-Jdk: 1.6.0_05 Bnd-LastModified: 1214414426851 Bundle-ManifestVersion: 2 Bundle-Activator: org.glassfish.samples.osgi.helloworld.App Import-Package: org.glassfish.samples.osgi.helloworld,org.osgi.framewo rk;version="1.3" Bundle-SymbolicName: helloworld |
| ~/testbed/glassfish/v3/snapshot/glassfish
>java -jar modules/glassfish-10.0-SNAPSHOT.jar Jun 25, 2008 4:09:19 PM com.sun.enterprise.glassfish.bootstrap.ASMain main INFO: Launching GlassFish on Apache Felix OSGi platform Jun 25, 2008 4:09:19 PM com.sun.enterprise.glassfish.bootstrap.ASMainOSGi getSharedRepos INFO: /Users/arungupta/testbed/glassfish/v3/snapshot/glassfish/domains/domain1/lib does not exist Welcome to Felix. ================= Jun 25, 2008 4:09:20 PM HK2Main start INFO: contextRootDir = /Users/arungupta/testbed/glassfish/v3/snapshot/glassfish/modules Jun 25, 2008 4:09:20 PM OSGiFactoryImpl initialize INFO: Singleton already initialized as com.sun.enterprise.module.impl.HK2Factory@3d44d0c6 Jun 25, 2008 4:09:20 PM OSGiModuleImpl loadClass INFO: Started bundle org.glassfish.common.glassfish-mbeanserver [19] Jun 25, 2008 4:09:20 PM OSGiModuleImpl loadClass INFO: Started bundle org.glassfish.core.kernel [51] Jun 25, 2008 4:09:21 PM OSGiModuleImpl loadClass INFO: Started bundle org.glassfish.common.glassfish-naming [8] Jun 25, 2008 4:09:21 PM OSGiModuleImpl loadClass INFO: Started bundle org.glassfish.admin.config-api [43] Jun 25, 2008 4:09:21 PM OSGiModuleImpl loadClass INFO: Started bundle org.glassfish.common.internal-api [33] Jun 25, 2008 4:09:21 PM OSGiModuleImpl loadClass INFO: Started bundle org.glassfish.deployment.deployment-common [10] Jun 25, 2008 4:09:21 PM INFO: JMXMP connector server URL = service:jmx:jmxmp://localhost:8888 Jun 25, 2008 4:09:21 PM com.sun.enterprise.v3.services.impl.GrizzlyProxy start INFO: Listening on port 8080 Jun 25, 2008 4:09:21 PM com.sun.enterprise.v3.services.impl.GrizzlyProxy start INFO: Listening on port 8181 Jun 25, 2008 4:09:21 PM com.sun.enterprise.v3.services.impl.GrizzlyProxy start INFO: Listening on port 4848 Jun 25, 2008 4:09:21 PM OSGiModuleImpl loadClass INFO: Started bundle org.glassfish.common.container-common [21] Jun 25, 2008 4:09:22 PM com.sun.enterprise.v3.admin.adapter.AdminConsoleAdapter setContextRoot INFO: Admin Console Adapter: context root: /admin Jun 25, 2008 4:09:22 PM com.sun.enterprise.v3.server.AppServerStartup run INFO: Glassfish v3 started in 1789 ms Jun 25, 2008 4:09:22 PM INFO: -> Jun 25, 2008 4:09:22 PM com.sun.enterprise.glassfish.bootstrap.ASMainFelix launchOSGiFW INFO: Framework successfully started |
| install
file:///Users/arungupta/samples/v3/helloworld/target/helloworld-1.0-SNAPSHOT.jar
Jun 25, 2008 4:10:19 PM INFO: Bundle ID: 75 Jun 25, 2008 4:10:19 PM INFO: -> |
| ps
Jun 25, 2008 4:10:27 PM INFO: START LEVEL 1 Jun 25, 2008 4:10:27 PM INFO: ID State Level Name Jun 25, 2008 4:10:27 PM INFO: [ 0] [Active ] [ 0] System Bundle (1.0.4) Jun 25, 2008 4:10:27 PM INFO: [ 1] [Active ] [ 1] org.jvnet.tiger-types repackaged as module (0.3.2) Jun 25, 2008 4:10:27 PM . . . INFO: [ 71] [Installed ] [ 1] Web module command line interface (10.0.0.SNAPSHOT) Jun 25, 2008 4:10:27 PM INFO: [ 72] [Installed ] [ 1] Admin GUI Web Container Plugin (10.0.0.SNAPSHOT) Jun 25, 2008 4:10:27 PM INFO: [ 75] [Installed ] [ 1] helloworld (1.0.0.SNAPSHOT) Jun 25, 2008 4:10:27 PM INFO: -> |
| start 75 Jun 25, 2008 4:10:32 PM INFO: Hey! Jun 25, 2008 4:10:32 PM INFO: -> |
| stop 75 Jun 25, 2008 4:10:35 PM INFO: Bye! Jun 25, 2008 4:10:35 PM INFO: -> |
| uninstall 75 Jun 25, 2008 4:10:42 PM INFO: -> |
Posted by Arun Gupta in General | Comments[5]
|
|
|
|
|
Wednesday June 25, 2008
Rails GlassFish Gem 0.3.1 now available
Vivek released
0.3.0 version of GlassFish Gem for Rails (a total of 11 issues fixed
and resolved - RubyForge
& GlassFish
Issue Tracker) earlier. But that caused a regression
on #4228.
And so matching the agility expected by Rails developers, he quickly released
0.3.1. And a wee bit smaller too - 2.68MB for 0.3.1
instead of 2.69MB for 0.3.0.
If you have an existing version of the gem, then you just need to
update it:
| ~/testbed/jruby-1.1 >bin/jruby -S gem update glassfish
-r JRuby limited openssl loaded. gem install jruby-openssl for full support. http://wiki.jruby.org/wiki/JRuby_Builtin_OpenSSL Updating installed gems... Bulk updating Gem source index for: http://gems.rubyforge.org Attempting remote update of glassfish Successfully installed glassfish-0.3.1-universal-java 1 gem installed Gems updated: glassfish |
| ~/testbed/jruby-1.1.2
>bin/jruby -S gem
install glassfish JRuby limited openssl loaded. gem install jruby-openssl for full support. http://wiki.jruby.org/wiki/JRuby_Builtin_OpenSSL Successfully installed glassfish-0.3.1-universal-java 1 gem installed |

| ~/testbed/jruby-1.1.2/samples/rails
>../../bin/jruby -S glassfish_rails runner Jun 24, 2008 11:04:51 PM com.sun.enterprise.glassfish.bootstrap.ASMain main INFO: Launching GlassFish on HK2 platform Jun 24, 2008 11:04:51 PM com.sun.enterprise.glassfish.bootstrap.ASMainHK2 findDerbyClient INFO: Cannot find javadb client jar file, jdbc driver not available Jun 24, 2008 11:04:52 PM com.sun.enterprise.v3.services.impl.GrizzlyProxy start INFO: Listening on port 3000 Jun 24, 2008 11:04:52 PM com.sun.enterprise.v3.services.impl.GrizzlyEmbeddedHttpConfigurator configureSSL WARNING: pewebcontainer.all_ssl_protocols_disabled Jun 24, 2008 11:04:52 PM com.sun.enterprise.v3.services.impl.GrizzlyEmbeddedHttpConfigurator configureSSL WARNING: pewebcontainer.all_ssl_ciphers_disabled Jun 24, 2008 11:04:52 PM com.sun.enterprise.v3.services.impl.GrizzlyProxy start INFO: Listening on port 3131 Jun 24, 2008 11:04:52 PM com.sun.enterprise.v3.services.impl.GrizzlyProxy start INFO: Listening on port 3838 Jun 24, 2008 11:04:52 PM com.sun.enterprise.v3.admin.adapter.AdminConsoleAdapter setContextRoot INFO: Admin Console Adapter: context root: /admin Jun 24, 2008 11:04:52 PM com.sun.grizzly.jruby.RailsAdapter startRubyRuntimePool INFO: Starting Rails instances Jun 24, 2008 11:04:58 PM SEVERE: JRuby limited openssl loaded. gem install jruby-openssl for full support. http://wiki.jruby.org/wiki/JRuby_Builtin_OpenSSL Jun 24, 2008 11:04:59 PM com.sun.grizzly.jruby.RubyObjectPool$1 run INFO: JRuby and Rails instance instantiation took : 6600ms Jun 24, 2008 11:04:59 PM org.glassfish.scripting.rails.RailsDeployer load INFO: Loading application runner at / Jun 24, 2008 11:04:59 PM com.sun.enterprise.v3.server.AppServerStartup run INFO: Glassfish v3 started in 7945 ms |
| Jun 24, 2008 11:05:25 PM
com.sun.grizzly.jruby.RailsAdapter$Logger log INFO: Processing DistancesController#index (for 0:0:0:0:0:0:0:1%0 at 2008-06-24 23:05:25) [GET] Jun 24, 2008 11:05:25 PM com.sun.grizzly.jruby.RailsAdapter$Logger log INFO: Session ID: BAh7ByIKZmxhc2hJQzonQWN0aW9uQ29udHJvbGxlcjo6Rmxhc2g6OkZsYXNo SGFzaHsABjoKQHVzZWR7ADoMY3NyZl9pZCIlNTdhMGYxNjkxOTk5ZjI1ZjI4 OGZjODZjZjcxN2QyNzQ=--cbf4578767e5887d4b62bd249e7624dcb7d1cf90 Jun 24, 2008 11:05:25 PM com.sun.grizzly.jruby.RailsAdapter$Logger log INFO: Parameters: {"controller"=>"distances", "action"=>"index"} Jun 24, 2008 11:05:25 PM com.sun.grizzly.jruby.RailsAdapter$Logger log INFO: WARNING: You're using the Ruby-based MySQL library that ships with Rails. This library is not suited for production. Please install the C-based MySQL library instead (gem install mysql). Jun 24, 2008 11:05:25 PM com.sun.grizzly.jruby.RailsAdapter$Logger log INFO: SQL (0.001000) SET NAMES 'utf8' Jun 24, 2008 11:05:25 PM com.sun.grizzly.jruby.RailsAdapter$Logger log INFO: SQL (0.001000) SET SQL_AUTO_IS_NULL=0 Jun 24, 2008 11:05:25 PM com.sun.grizzly.jruby.RailsAdapter$Logger log INFO: Distance Load (0.003000) SELECT * FROM `distances` Jun 24, 2008 11:05:25 PM com.sun.grizzly.jruby.RailsAdapter$Logger log INFO: Rendering template within layouts/distances . . . Jun 24, 2008 11:05:48 PM com.sun.grizzly.jruby.RailsAdapter$Logger log INFO: Parameters: {"authenticity_token"=>"519436f2248515d901051acafe0726dfd88746f0", "distance"=>{"miles"=>"4", "run_at(1i)"=>"2008", "run_at(2i)"=>"6", "run_at(3i)"=>"24", "run_at(4i)"=>"07", "run_at(5i)"=>"00"}, "commit"=>"Create", "controller"=>"distances", "action"=>"create"} Jun 24, 2008 11:05:48 PM com.sun.grizzly.jruby.RailsAdapter$Logger log INFO: Distance Columns (0.009000) SHOW FIELDS FROM `distances` Jun 24, 2008 11:05:48 PM com.sun.grizzly.jruby.RailsAdapter$Logger log INFO: SQL (0.000000) BEGIN Jun 24, 2008 11:05:48 PM com.sun.grizzly.jruby.RailsAdapter$Logger log INFO: Distance Create (0.000000) INSERT INTO `distances` (`miles`, `run_at`, `created_at`, `updated_at`) VALUES(4.0, '2008-06-24 14:00:00', '2008-06-25 06:05:48', '2008-06-25 06:05:48') Jun 24, 2008 11:05:48 PM com.sun.grizzly.jruby.RailsAdapter$Logger log INFO: SQL (0.002000) COMMIT . . . Jun 24, 2008 11:06:09 PM com.sun.grizzly.jruby.RailsAdapter$Logger log INFO: Parameters: {"authenticity_token"=>"519436f2248515d901051acafe0726dfd88746f0", "distance"=>{"miles"=>"3.5", "run_at(1i)"=>"2008", "run_at(2i)"=>"6", "run_at(3i)"=>"23", "run_at(4i)"=>"06", "run_at(5i)"=>"55"}, "commit"=>"Create", "controller"=>"distances", "action"=>"create"} Jun 24, 2008 11:06:09 PM com.sun.grizzly.jruby.RailsAdapter$Logger log INFO: Distance Columns (0.015000) SHOW FIELDS FROM `distances` Jun 24, 2008 11:06:09 PM com.sun.grizzly.jruby.RailsAdapter$Logger log INFO: SQL (0.000000) BEGIN Jun 24, 2008 11:06:09 PM com.sun.grizzly.jruby.RailsAdapter$Logger log INFO: Distance Create (0.000000) INSERT INTO `distances` (`miles`, `run_at`, `created_at`, `updated_at`) VALUES(3.5, '2008-06-23 13:55:00', '2008-06-25 06:06:09', '2008-06-25 06:06:09') Jun 24, 2008 11:06:09 PM com.sun.grizzly.jruby.RailsAdapter$Logger log INFO: SQL (0.001000) COMMIT Jun 24, 2008 11:06:09 PM com.sun.grizzly.jruby.RailsAdapter$Logger log INFO: Redirected to http://localhost:3000/distances/5 . . . Jun 24, 2008 11:06:10 PM com.sun.grizzly.jruby.RailsAdapter$Logger log INFO: Parameters: {"controller"=>"distances", "action"=>"index"} Jun 24, 2008 11:06:10 PM com.sun.grizzly.jruby.RailsAdapter$Logger log INFO: Distance Load (0.003000) SELECT * FROM `distances` Jun 24, 2008 11:06:10 PM com.sun.grizzly.jruby.RailsAdapter$Logger log INFO: Rendering template within layouts/distances Jun 24, 2008 11:06:10 PM com.sun.grizzly.jruby.RailsAdapter$Logger log INFO: Rendering distances/index Jun 24, 2008 11:06:10 PM com.sun.grizzly.jruby.RailsAdapter$Logger log INFO: Distance Columns (0.008000) SHOW FIELDS FROM `distances` Jun 24, 2008 11:06:11 PM com.sun.grizzly.jruby.RailsAdapter$Logger log INFO: Completed in 0.05900 (16 reqs/sec) | Rendering: 0.03200 (54%) | DB: 0.01100 (18%) | 200 OK [http://localhost/distances] |
Posted by Arun Gupta in web2.0 | Comments[6]
|
|
|
|
|
Tuesday June 24, 2008
JRuby-on-Rails and MySQL on GlassFish on OpenSolaris in Virtual Box VM
My primary development machine is Mac OS Leopard
on Intel Core 2 Duo (read osxtips).
But the beauty of virtualization
is that I can run multiple Operating Systems on a single powerful
machine. And what better virtualization product than Virtual Box.
And Open
Solaris has crossed leaps and boundaries making installation
and getting started extremely simple :)
So here is an application stack that I tried:
![]() |
Rails 2.1
+ My
SQL 5.0.51a JRuby 1.1.2 GlassFish v3 TP2 OpenSolaris 2008.05 Virtual Box 1.6.2 Mac OSX Leopard Intel 2.4 G Hz Core 2 Duo |









Posted by Arun Gupta in web2.0 | Comments[4]
|
|
|
|
|
Monday June 23, 2008
New "Community: GlassFish" category for java.net bloggers
If you are a java.net
blogger and blog about GlassFish
then consider using "Community: GlassFish" category for any new entry
as shown below:

All the consolidated blogs can then be read here.
blogs.sun.com
already makes it easy by providing tags, for example you can read all GlassFish
blogs from Sun.
Here are some other related pointers for you:
Posted by Arun Gupta in General | Comments[0]
|
|
|
|
| TOTD #35: Rails Database Connection on Solaris
Are you deploying your JRuby-on-Rails applications
on Solaris
(or any variety of Unix) and not able to connect to the database ?
I experienced it last week so thought of sharing the tip here. Luckily
it's really simple.
Here is the default generated "config/database.yml"
| development: adapter: mysql encoding: utf8 database: runner_development username: root password: socket: /tmp/mysql.sock |
| development: adapter: mysql encoding: utf8 database: runner_development username: root password: socket: /tmp/mysql.sock host: 127.0.01 |
Please leave suggestions on other TOTD (Tip Of The Day) that you'd like to see. A complete archive is available here.
Technorati: totd rubyonrails jruby ruby opensolaris mysqlPosted by Arun Gupta in web2.0 | Comments[3]
|
|
|
|
|
Friday June 20, 2008
TOTD #34: Using Felix Shell with GlassFish
TOTD
#33 explains how to create a GlassFish v3
distribution that uses Apache Felix
(default) as the OSGi R4 Service
Platform runtime. This blog explains how to use Felix
Shell
TUI with that bundle to issue commands to the OSGi framework
and obtain information from it.
To enable Felix Shell with GlassFish v3, add the lines ...
| ${com.sun.aas.installRootURI}/felix/bundle/org.apache.felix.shell.jar
\ ${com.sun.aas.installRootURI}/felix/bundle/org.apache.felix.shell.tui.jar |
| felix.auto.start.1=
\ ${com.sun.aas.installRootURI}/modules/tiger-types-osgi-0.3.2.jar \ ${com.sun.aas.installRootURI}/modules/auto-depends-0.3.2.jar \ ${com.sun.aas.installRootURI}/modules/config-0.3.2.jar \ ${com.sun.aas.installRootURI}/modules/hk2-core-0.3.2.jar \ ${com.sun.aas.installRootURI}/modules/osgi-adapter-0.3.2.jar \ ${com.sun.aas.installRootURI}/felix/bundle/org.apache.felix.shell.jar \ ${com.sun.aas.installRootURI}/felix/bundle/org.apache.felix.shell.tui.jar |
| INFO:
Glassfish v3 started in 1624 ms Jun 16, 2008 7:10:37 PM INFO: -> Jun 16, 2008 7:10:37 PM com.sun.enterprise.glassfish.bootstrap.ASMainFelix launchOSGiFW INFO: Framework successfully started |
| help Jun 16, 2008 7:11:12 PM INFO: bundlelevel <level> <id> ... | <id> - set or get bundle start level. Jun 16, 2008 7:11:12 PM INFO: cd [<base-URL>] - change or display base URL. Jun 16, 2008 7:11:12 PM INFO: headers [<id> ...] - display bundle header properties. Jun 16, 2008 7:11:12 PM INFO: help - display impl commands. Jun 16, 2008 7:11:12 PM INFO: install <URL> [<URL> ...] - install bundle(s). Jun 16, 2008 7:11:12 PM INFO: packages [<id> ...] - list exported packages. Jun 16, 2008 7:11:12 PM INFO: ps [-l | -s | -u] - list installed bundles. Jun 16, 2008 7:11:12 PM INFO: refresh [<id> ...] - refresh packages. Jun 16, 2008 7:11:12 PM INFO: resolve [<id> ...] - attempt to resolve the specified bundles. Jun 16, 2008 7:11:12 PM INFO: services [-u] [-a] [<id> ...] - list registered or used services. Jun 16, 2008 7:11:12 PM INFO: shutdown - shutdown framework. Jun 16, 2008 7:11:12 PM INFO: start <id> [<id> <URL> ...] - start bundle(s). Jun 16, 2008 7:11:12 PM INFO: startlevel [<level>] - get or set framework start level. Jun 16, 2008 7:11:12 PM INFO: stop <id> [<id> ...] - stop bundle(s). Jun 16, 2008 7:11:12 PM INFO: uninstall <id> [<id> ...] - uninstall bundle(s). Jun 16, 2008 7:11:12 PM INFO: update <id> [<URL>] - update bundle. Jun 16, 2008 7:11:12 PM INFO: version - display version of framework. Jun 16, 2008 7:11:12 PM INFO: -> |
| ps Jun 16, 2008 7:13:57 PM INFO: START LEVEL 1 Jun 16, 2008 7:13:57 PM INFO: ID State Level Name Jun 16, 2008 7:13:57 PM INFO: [ 0] [Active ] [ 0] System Bundle (1.0.4) Jun 16, 2008 7:13:57 PM INFO: [ 1] [Active ] [ 1] org.jvnet.tiger-types repackaged as module (0.3.2) . . . INFO: [ 137] [Installed ] [ 1] WebTier Security Integration (10.0.0.SNAPSHOT) Jun 16, 2008 7:13:57 PM INFO: [ 138] [Installed ] [ 1] Web module command line interface (10.0.0.SNAPSHOT) Jun 16, 2008 7:13:57 PM INFO: [ 139] [Installed ] [ 1] Admin GUI Web Container Plugin (10.0.0.SNAPSHOT) Jun 16, 2008 7:13:57 PM INFO: -> |
Please leave suggestions on other TOTD (Tip Of The Day) that you'd like to see. A complete archive is available here.
Technorati: totd glassfish v3 felix osgiPosted by Arun Gupta in General | Comments[5]
|
|
|
|
|
Thursday June 19, 2008
![]() |
Sicilia
JUG took my email interview a few days ago and published it
on
their website. Read it here. Thanks to Mario Cartia! |
Posted by Arun Gupta in General | Comments[1]
|
|
|
|
|
Wednesday June 18, 2008
Rails 2.1 on GlassFish - it works!
Rails 2.1 was released
earlier this month. GlassFish
provides a complete development/deployment
environment for Rails applications. Some of the main reasons
for using GlassFish (instead of WEBrick or Mongrel)
are:
| ~/testbed/rails21/jruby-1.1.2
>bin/jruby -S gem
install rails --no-ri --no-rdoc JRuby limited openssl loaded. gem install jruby-openssl for full support. http://wiki.jruby.org/wiki/JRuby_Builtin_OpenSSL Updating metadata for 253 gems from http://gems.rubyforge.org/ ............................................................................... ............................................................................... ............................................................................... ................ complete Bulk updating Gem source index for: http://gems.rubyforge.org/ Successfully installed activesupport-2.1.0 Successfully installed activerecord-2.1.0 Successfully installed actionpack-2.1.0 Successfully installed actionmailer-2.1.0 Successfully installed activeresource-2.1.0 Successfully installed rails-2.1.0 6 gems installed |
| ~/testbed/rails21/jruby-1.1.2/samples/rails
>../../bin/jruby
-S rails -d mysql runner create create app/controllers create app/helpers create app/models create app/views/layouts create config/environments create config/initializers create db create doc create lib create lib/tasks create log create public/images create public/javascripts create public/stylesheets create script/performance create script/process create test/fixtures create test/functional create test/integration create test/unit create vendor create vendor/plugins create tmp/sessions create tmp/sockets create tmp/cache create tmp/pids create Rakefile create README create app/controllers/application.rb create app/helpers/application_helper.rb create test/test_helper.rb create config/database.yml create config/routes.rb create config/initializers/inflections.rb create config/initializers/mime_types.rb create config/initializers/new_rails_defaults.rb create config/boot.rb create config/environment.rb create config/environments/production.rb create config/environments/development.rb create config/environments/test.rb create script/about create script/console create script/dbconsole create script/destroy create script/generate create script/performance/benchmarker create script/performance/profiler create script/performance/request create script/process/reaper create script/process/spawner create script/process/inspector create script/runner create script/server create script/plugin create public/dispatch.rb create public/dispatch.cgi create public/dispatch.fcgi create public/404.html create public/422.html create public/500.html create public/index.html create public/favicon.ico create public/robots.txt create public/images/rails.png create public/javascripts/prototype.js create public/javascripts/effects.js create public/javascripts/dragdrop.js create public/javascripts/controls.js create public/javascripts/application.js create doc/README_FOR_APP create log/server.log create log/production.log create log/development.log create log/test.log |
| ~/testbed/glassfish/v3/tp2/glassfishv3-tp2/glassfish
>java
-DJRUBY_HOME=/Users/arungupta/testbed/rails21/jruby-1.1.2 -jar
modules/glassfish-10.0-tp-2-SNAPSHOT.jar Jun 17, 2008 6:14:21 PM com.sun.enterprise.glassfish.bootstrap.ASMain main INFO: Launching GlassFish on HK2 platform Jun 17, 2008 6:14:22 PM com.sun.enterprise.v3.services.impl.GrizzlyProxy start INFO: Listening on port 8080 Jun 17, 2008 6:14:22 PM com.sun.enterprise.v3.services.impl.GrizzlyProxy start INFO: Listening on port 8181 Jun 17, 2008 6:14:22 PM com.sun.enterprise.v3.services.impl.GrizzlyProxy start INFO: Listening on port 4848 Jun 17, 2008 6:14:22 PM com.sun.enterprise.v3.admin.adapter.AdminConsoleAdapter setContextRoot INFO: Admin Console Adapter: context root: /admin Jun 17, 2008 6:14:22 PM com.sun.enterprise.v3.server.AppServerStartup run INFO: Glassfish v3 started in 974 ms |
| ~/testbed/rails21/jruby-1.1.2/samples/rails
>~/testbed/glassfish/v3/tp2/glassfishv3-tp2/glassfish/bin/asadmin
deploy runner Command deploy executed successfully. |
| Jun
17, 2008 6:14:41 PM com.sun.enterprise.rails.RailsDeployer
registerAdapter INFO: Loading application runner at /runner Jun 17, 2008 6:14:41 PM INFO: Starting Rails instances Jun 17, 2008 6:14:49 PM SEVERE: JRuby limited openssl loaded. gem install jruby-openssl for full support. http://wiki.jruby.org/wiki/JRuby_Builtin_OpenSSL Jun 17, 2008 6:14:51 PM com.sun.grizzly.jruby.RubyObjectPool$1 run INFO: Rails instance instantiation took : 9066ms Jun 17, 2008 6:14:51 PM com.sun.enterprise.v3.deployment.DeployCommand execute INFO: Deployment of runner done is 9168 ms |

| ~/testbed/rails21/jruby-1.1.2/samples/rails/runner
>../../../bin/jruby
-S rake db:create (in /Users/arungupta/testbed/rails21/jruby-1.1.2/samples/rails/runner) ~/testbed/rails21/jruby-1.1.2/samples/rails/runner >../../../bin/jruby script/generate scaffold distance miles:float run_at:datetime JRuby limited openssl loaded. gem install jruby-openssl for full support. http://wiki.jruby.org/wiki/JRuby_Builtin_OpenSSL exists app/models/ exists app/controllers/ exists app/helpers/ create app/views/distances exists app/views/layouts/ exists test/functional/ exists test/unit/ exists public/stylesheets/ create app/views/distances/index.html.erb create app/views/distances/show.html.erb create app/views/distances/new.html.erb create app/views/distances/edit.html.erb create app/views/layouts/distances.html.erb create public/stylesheets/scaffold.css create app/controllers/distances_controller.rb create test/functional/distances_controller_test.rb create app/helpers/distances_helper.rb route map.resources :distances dependency model exists app/models/ exists test/unit/ exists test/fixtures/ create app/models/distance.rb create test/unit/distance_test.rb create test/fixtures/distances.yml create db/migrate create db/migrate/20080618012326_create_distances.rb ~/testbed/rails21/jruby-1.1.2/samples/rails/runner >../../../bin/jruby -S rake db:migrate (in /Users/arungupta/testbed/rails21/jruby-1.1.2/samples/rails/runner) == 20080618012326 CreateDistances: migrating ================================== -- create_table(:distances) -> 0.0080s == 20080618012326 CreateDistances: migrated (0.0090s) ========================= |
| config.time_zone = 'Pacific Time (US & Canada)' |


| ~/testbed/rails21/jruby-1.1.2
>bin/jruby -S gem
install glassfish JRuby limited openssl loaded. gem install jruby-openssl for full support. http://wiki.jruby.org/wiki/JRuby_Builtin_OpenSSL Updating metadata for 13 gems from http://gems.rubyforge.org/ ............. complete Successfully installed glassfish-0.2.0-universal-java 1 gem installed |
| ~/testbed/rails21/jruby-1.1.2/samples/rails
>../../bin/jruby
-S glassfish_rails runner Jun 17, 2008 6:39:37 PM com.sun.enterprise.glassfish.bootstrap.ASMain main INFO: Launching GlassFish on HK2 platform Jun 17, 2008 6:39:37 PM com.sun.enterprise.glassfish.bootstrap.ASMainHK2 findDerbyClient INFO: Cannot find javadb client jar file, jdbc driver not available Jun 17, 2008 6:39:38 PM com.sun.enterprise.v3.services.impl.GrizzlyProxy start INFO: Listening on port 3000 Jun 17, 2008 6:39:38 PM com.sun.enterprise.v3.services.impl.GrizzlyEmbeddedHttpConfigurator configureSSL WARNING: pewebcontainer.all_ssl_protocols_disabled Jun 17, 2008 6:39:38 PM com.sun.enterprise.v3.services.impl.GrizzlyEmbeddedHttpConfigurator configureSSL WARNING: pewebcontainer.all_ssl_ciphers_disabled Jun 17, 2008 6:39:38 PM com.sun.enterprise.v3.services.impl.GrizzlyProxy start INFO: Listening on port 3131 Jun 17, 2008 6:39:38 PM com.sun.enterprise.v3.services.impl.GrizzlyProxy start INFO: Listening on port 3838 Jun 17, 2008 6:39:39 PM com.sun.enterprise.v3.admin.adapter.AdminConsoleAdapter setContextRoot INFO: Admin Console Adapter: context root: /admin Jun 17, 2008 6:39:39 PM com.sun.enterprise.rails.RailsDeployer registerAdapter INFO: Loading application runner at / Jun 17, 2008 6:39:39 PM INFO: Starting Rails instances Jun 17, 2008 6:39:44 PM SEVERE: JRuby limited openssl loaded. gem install jruby-openssl for full support. http://wiki.jruby.org/wiki/JRuby_Builtin_OpenSSL Jun 17, 2008 6:39:45 PM com.sun.grizzly.jruby.RubyObjectPool$1 run INFO: Rails instance instantiation took : 6710ms Jun 17, 2008 6:39:45 PM com.sun.enterprise.v3.server.AppServerStartup run INFO: Glassfish v3 started in 8053 ms |

Posted by Arun Gupta in web2.0 | Comments[6]
|
|
|
|
|
Tuesday June 17, 2008
![]() |
Kohsuke (aka Mr. Hudson) and I attended The Server Side Java Symposium, Las Vegas in Mar 2008. In one of the evenings we spent togehter, I decided to pick Kohsuke's brain on top 10 features of Hudson. My notes were lost but luckily I found them so this article is slightly dated but most of the content is still very much valid. Newer features have been added since then anyway. |

Posted by Arun Gupta in General | Comments[1]
|
|
|
|
|
Monday June 16, 2008
TOTD #33: Building GlassFish v3 Workspace
Reviving after a 2-week
hiatus ...
This TOTD (Tip Of The Day) provides complete instructions on how to
checkout/build GlassFish
v3 workspace.
|
~/workspaces/glassfish >svn
checkout
https://svn.dev.java.net/svn/glassfish-svn/trunk/v3 Error validating server certificate for 'https://svn.dev.java.net:443': - The certificate is not issued by a trusted authority. Use the fingerprint to validate the certificate manually! Certificate information: - Hostname: *.dev.java.net - Valid: from Thu, 09 Aug 2007 06:44:32 GMT until Sat, 09 Aug 2008 06:44:32 GMT - Issuer: Equifax Secure Inc., US - Fingerprint: e9:12:f6:a0:36:fe:7d:b0:07:dd:8b:d6:c3:b6:29:ff:ba:02:03:46 (R)eject, accept (t)emporarily or accept (p)ermanently? t Authentication realm: <https://svn.dev.java.net:443> CollabNet Subversion Repository Password for 'arungupta': <YOUR PASSWORD HERE> A v3/deployment A v3/deployment/javaee-core A v3/deployment/javaee-core/src A v3/deployment/javaee-core/src/main . . . A v3/packager/packages/glassfishv3-ejb/build.properties A v3/packager/packages/glassfishv3-ejb/build.xml A v3/packager/packages/glassfishv3-ejb/glassfishv3-ejb.spec.tmpl A v3/packager/packages/README U v3 Checked out revision 21054. |
|
~/workspaces/glassfish/v3 >ls
-la total 24 drwxr-xr-x 25 arungupta arungupta 850 Jun 16 15:03 . drwxr-xr-x 3 arungupta arungupta 102 Jun 16 14:58 .. drwxr-xr-x 10 arungupta arungupta 340 Jun 16 15:03 .svn drwxr-xr-x 17 arungupta arungupta 578 Jun 16 15:00 admin drwxr-xr-x 10 arungupta arungupta 340 Jun 16 15:01 admingui drwxr-xr-x 6 arungupta arungupta 204 Jun 16 15:01 build drwxr-xr-x 15 arungupta arungupta 510 Jun 16 15:00 common drwxr-xr-x 9 arungupta arungupta 306 Jun 16 15:03 connectors drwxr-xr-x 7 arungupta arungupta 238 Jun 16 14:59 core drwxr-xr-x 10 arungupta arungupta 340 Jun 16 14:58 deployment drwxr-xr-x 10 arungupta arungupta 340 Jun 16 15:01 distributions drwxr-xr-x 9 arungupta arungupta 306 Jun 16 15:01 ejb drwxr-xr-x 8 arungupta arungupta 272 Jun 16 15:02 extras drwxr-xr-x 6 arungupta arungupta 204 Jun 16 15:00 installer drwxr-xr-x 27 arungupta arungupta 918 Jun 16 15:01 javaee-api drwxr-xr-x 5 arungupta arungupta 170 Jun 16 15:02 osgi-platforms drwxr-xr-x 13 arungupta arungupta 442 Jun 16 15:03 packager drwxr-xr-x 6 arungupta arungupta 204 Jun 16 14:58 persistence -rw-r--r-- 1 arungupta arungupta 11866 Jun 16 15:03 pom.xml drwxr-xr-x 6 arungupta arungupta 204 Jun 16 15:02 registration drwxr-xr-x 7 arungupta arungupta 238 Jun 16 15:02 security drwxr-xr-x 8 arungupta arungupta 272 Jun 16 15:01 tests drwxr-xr-x 8 arungupta arungupta 272 Jun 16 14:58 transaction drwxr-xr-x 15 arungupta arungupta 510 Jun 16 15:02 web drwxr-xr-x 5 arungupta arungupta 170 Jun 16 14:58 webservices |
| export MAVEN_OPTS=-Xmx512m |
|
~/workspaces/glassfish/v3 >mvn
-U install [INFO] Scanning for projects... [INFO] Reactor build order: [INFO] GlassFish Build Utilities [INFO] GlassFish v3 Maven2 plugin [INFO] Maven extension for building GlassFish [INFO] GlassFish Parent Project . . . [INFO] ------------------------------------------------------------------------ [INFO] BUILD SUCCESSFUL [INFO] ------------------------------------------------------------------------ [INFO] Total time: 5 minutes 56 seconds [INFO] Finished at: Mon Jun 16 15:33:46 PDT 2008 [INFO] Final Memory: 57M/121M [INFO] ------------------------------------------------------------------------ |
| ~/testbed/glassfish/v3/snapshot
>unzip
~/workspaces/glassfish/v3/distributions/glassfish/target/glassfish-10.0-SNAPSHOT.zip
Archive: /Users/arungupta/workspaces/glassfish/v3/distributions/glassfish/target/glassfish-10.0-SNAPSHOT.zip creating: glassfish/ creating: glassfish/docs/ . . . inflating: glassfish/lib/templates/keyfile inflating: glassfish/lib/templates/logging.properties inflating: glassfish/lib/templates/login.conf inflating: glassfish/lib/templates/profile.properties inflating: glassfish/lib/templates/server.policy |
| ~/testbed/glassfish/v3/snapshot/glassfish
>ls -la total 592 drwxr-xr-x 14 arungupta arungupta 476 Apr 23 16:37 . drwxr-xr-x 3 arungupta arungupta 102 Jun 16 15:40 .. -rw-r--r-- 1 arungupta arungupta 250464 Jun 16 15:24 3RD-PARTY-LICENSE.txt -rw-r--r-- 1 arungupta arungupta 4603 Jun 16 15:24 COPYRIGHT -rw-r--r-- 1 arungupta arungupta 36116 Jun 16 15:24 LICENSE.txt -rw-r--r-- 1 arungupta arungupta 271 Jun 16 15:24 README drwxr-xr-x 8 arungupta arungupta 272 Jun 16 15:33 bin drwxr-xr-x 6 arungupta arungupta 204 Jun 16 15:33 config drwxr-xr-x 7 arungupta arungupta 238 Jun 16 15:33 docs drwxr-xr-x 3 arungupta arungupta 102 Jun 16 15:33 domains drwxr-xr-x 5 arungupta arungupta 170 Jun 16 15:33 felix drwxr-xr-x 9 arungupta arungupta 306 Jun 16 15:32 javadb drwxr-xr-x 11 arungupta arungupta 374 Apr 23 16:37 lib drwxr-xr-x 74 arungupta arungupta 2516 Jun 16 15:33 modules |
| ~/testbed/glassfish/v3/snapshot/glassfish
>bin/asadmin
start-domain -v Jun 16, 2008 3:44:54 PM com.sun.enterprise.admin.launcher.GFLauncherLogger info INFO: JVM invocation command line: /System/Library/Frameworks/JavaVM.framework/Versions/1.6.0/Home/bin/java -cp /Users/arungupta/testbed/glassfish/v3/snapshot/glassfish/modules/glassfish-10.0-SNAPSHOT.jar -XX:+UnlockDiagnosticVMOptions -XX:NewRatio=2 . . . INFO: Started bundle org.glassfish.common.container-common [85] Jun 16, 2008 3:44:56 PM com.sun.enterprise.v3.admin.adapter.AdminConsoleAdapter setContextRoot INFO: Admin Console Adapter: context root: /admin Jun 16, 2008 3:44:56 PM com.sun.enterprise.v3.server.AppServerStartup run INFO: Glassfish v3 started in 1594 ms Jun 16, 2008 3:44:56 PM com.sun.enterprise.glassfish.bootstrap.ASMainFelix launchOSGiFW INFO: Framework successfully started |

Please leave suggestions on other TOTD (Tip Of The Day) that you'd like to see. A complete archive is available here.
Technorati: totd glassfish v3 felix osgiPosted by Arun Gupta in General | Comments[8]
|
|
|
|
|
Monday June 02, 2008
Mihir Gupta is born ... ta da!
I'm glad to announced that yesterday afternoon there was a new addition
to our family.
Mihir Gupta, our 2nd son, was born.
Big brother is "extremely happy" and waiting for young one to come
home. And mom and dad are revising their
skills :)
| Date | Jun 1, 2008 |
| Weight | 7 lb 3 oz |
| Length | 20.5 inches |
Tic Tac Toe using Rails and Grails on GlassFish v3
GlassFish v3
is a modular
(OSGi compliant), embeddable (runs in-VM) and extensible (hosts
non-Java applications) Application Server. The "extensible" part was
demonstrated during JavaOne
2008 by deploying Rails,
Grails and Django sample
application on GlassFish
v3 Technology Preview 2. This blog announces the availability
of Rails, Grails and (of course!) Java EE version of the demo code.
The
sample application is a simple multi-player game that can be played on
Internet and deployed on GlassFish. One of the simplest multi-player
game is Tic-Tac-Toe.
The complete instructions to checkout, build, deploy and run the sample
are available here.
The demo can certainly be improved by using the best practices from
Rails and Grails and I'll work on them in next few days.
The
demo is played in 2 different browser windows (tested on Firefox,
Safari & IE). The clicks in the grid on one browser are
displayed
on the other browser (propagated using GlassFish Comet) and row and
column winners are shown.

Posted by Arun Gupta in web2.0 | Comments[15]
|
|
|
|
|
Today's Page Hits: 160
Total # blog entries: 1002