Let's engage user with Flash platform
Posts tagged WebOrb
Resolve Weborb for Rails’ dependencies error in one statement!
Jan 30th
WebORB is a best start framework for everyone who need to integrate their Adobe Flash or Adobe Flex product to the other server platform except Adobe ColdFusion. For me, it made me a money from 2 projects already.
But you may found that when you choose WebORB for Rails to integrate your nice flashy web application with a popular web framework like Ruby on Rails, especially with version 2.2.x+. You may scream after you install WebORB’s plug-in via following script and then run the server again to test something:
>ruby script/plugin install http://themidnightcoders.net:8089/svn/weborb
These exception below will make you scream:
Exiting
/Library/Ruby/Gems/1.8/gems/activesupport-2.2.2/lib/active_support/dependencies.rb:102:in `const_missing': uninitialized constant Rails::Plugin::Dependencies (NameError)
from /Users/mikih/Documents/workspace/isgroup_website_backend/vendor/plugins/weborb/init.rb:30:in `evaluate_init_rb'
from /Library/Ruby/Gems/1.8/gems/rails-2.2.2/lib/rails/plugin.rb:103:in `evaluate_init_rb'
from /Library/Ruby/Gems/1.8/gems/activesupport-2.2.2/lib/active_support/core_ext/kernel/reporting.rb:11:in `silence_warnings'
from /Library/Ruby/Gems/1.8/gems/rails-2.2.2/lib/rails/plugin.rb:99:in `evaluate_init_rb'
from /Library/Ruby/Gems/1.8/gems/rails-2.2.2/lib/rails/plugin.rb:44:in `load'
from /Library/Ruby/Gems/1.8/gems/rails-2.2.2/lib/rails/plugin/loader.rb:33:in `load_plugins'
from /Library/Ruby/Gems/1.8/gems/rails-2.2.2/lib/rails/plugin/loader.rb:32:in `each'
from /Library/Ruby/Gems/1.8/gems/rails-2.2.2/lib/rails/plugin/loader.rb:32:in `load_plugins'
... 33 levels...
from /Library/Ruby/Site/1.8/rubygems/custom_require.rb:31:in `require'
from ./script/server:3
from -e:2:in `load'
from -e:2
That is, I screamed with you too. But after trying to find the solution. I just found a simple solution to past this annoying problem, posted by Mr. Davevil.
- Open file:
init.rb in /vendor/plugins/weborb/init.rb - Replace following statement: Dependencies.mechanism = :load
- With this statement: ActiveSupport::Dependencies.mechanism = :load
Then save it, and run your server again. I drank a big class of Coca-Cola for this succeed.
Array to WebOrb’s Java
Feb 28th
For this week, my project has moved into final phase. I have found that if you want to send pure Flex’s Array to Java’s server site through WebOrb data service (it’s free for all! but some great feature such as Security and Data-push only available for paid version) You must declare the public attribute type ( a collection one ) to be plain array.
like here,
Java class destination
public class JavaToken{
public SimpleClassBean[] collection;
}
Flex’s class initialize
public class FlexToken{
public collection : Array;
}
With these implementation, Weborb will serialize flex’s array attribute to Java’s destination.
In Thai
สัปดาห์นี้ เป็นช่วงเวลาที่ โปรเจคผมเริ่มเข้าสู่ เส้นตาย เอ้ย ช่วงสุดท้ายแล้วครับ ( จริงๆ แล้วเหลืออีก อาทิตย์หนึ่ง แห่ะๆ) วันนี้ผมได้ค้นพบว่า สำหรับผู้ใช้ WebOrb for Java อาจจะไม่แน่ใจเรื่องการส่ง type array เข้าไปฝั่ง server วันนี้ได้ข้อกระจ่างครับ คือให้ทำการประกาศ class ฝั่ง server ให้ attribute array ดังกล่าวเป็น plain array ครับ (ดังตัวอย่างด้านบน) ซึ่ง Weborb จะทำการ pass ไปให้อย่างไม่มีข้อผิดพลาด
PS. เสาร์ที่ 2 กุมภา นี้ เจอกัน ที่งาน Flex seminar โดย Double-i Studio นะครับ (อยากได้เสื้อง่ะ แงๆ)
Array to WebOrb’s Java
Feb 28th
For this week, my project has moved into final phase. I have found that if you want to send pure Flex’s Array to Java’s server site through WebOrb data service (it’s free for all! but some great feature such as Security and Data-push only available for paid version) You must declare the public attribute type ( a collection one ) to be plain array.
like here,
Java class destination
public class JavaToken{
public SimpleClassBean[] collection;
}
Flex’s class initialize
public class FlexToken{
public collection : Array;
}
With these implementation, Weborb will serialize flex’s array attribute to Java’s destination.
In Thai
สัปดาห์นี้ เป็นช่วงเวลาที่ โปรเจคผมเริ่มเข้าสู่ เส้นตาย เอ้ย ช่วงสุดท้ายแล้วครับ ( จริงๆ แล้วเหลืออีก อาทิตย์หนึ่ง แห่ะๆ) วันนี้ผมได้ค้นพบว่า สำหรับผู้ใช้ WebOrb for Java อาจจะไม่แน่ใจเรื่องการส่ง type array เข้าไปฝั่ง server วันนี้ได้ข้อกระจ่างครับ คือให้ทำการประกาศ class ฝั่ง server ให้ attribute array ดังกล่าวเป็น plain array ครับ (ดังตัวอย่างด้านบน) ซึ่ง Weborb จะทำการ pass ไปให้อย่างไม่มีข้อผิดพลาด
PS. เสาร์ที่ 2 กุมภา นี้ เจอกัน ที่งาน Flex seminar โดย Double-i Studio นะครับ (อยากได้เสื้อง่ะ แงๆ)



