WebORB FAQ’s


General

What is the cost of a WebORB license?

WebORB licenses are free for development, staging and production servers. We advise you to choose a support plan to make sure you are covered if you need support from the Midnight Coders.

Can I use Flex Builder or Flex SDK to develop Flex apps with WebORB?

Yes, WebORB integrates very well with both Flex Builder and the Flex SDK.

Flex developers can use the standard ActionScript API to communicate with server objects.

This includes Flex remoting (RemoteObject), Flex data management (DataService) and Flex

messaging (Producer/Consumer)

MXML and API classes.

How do I get started with WebORB?

When you download WebORB, you get a fully-featured product build that you can use at no extra licensing cost for development,staging and production purposes. The best way to learn the product is to follow one of our ‘Getting Started’ guides.We also offer product training specifically customized to your needs.

Development

Do I need anything special on the client side to integrate with .NET?

No, since WebORB handles all the client/server integration, your Flex application does not require anything special.

In fact, you can use the same Flex client to communicate with both .NET,

Java, PHP or Ruby (assuming your server application supports the same functionality).

Do my .NET classes need to use any special APIs or dependencies on WebORB?

No, your server-side code can be 100% WebORB-free. Unless you require some advanced features, you do not need to use any special classes, interfaces or attributes.

Your method arguments and return types can be standard .NET classes, collections and interfaces or types from your application domain. WebORB will automatically handle all the translation between client objects and their server-side counterparts. You do not need to use any special base classes or attributes to expose your classes for remote access.

How does WebORB map client-side objects to the corresponding .NET types?

The WebORB client/server type mapping system is one of the most powerful features of our product.

WebORB intelligently adapts client-side objects to any corresponding server type. For example, If a Flex or Flash client sends a linear array, the server side type can be any linear .NET collection or a custom array of application objects. Additionally, developer can override default type mapping mechanism and map specific .NET types to their corresponding ActionScript classes.

How can my .NET application deliver errors and exceptions to the client side?

Delivering exceptions to the client application does not require any special programming techniques.

Your .NET application can simply throw an exception and WebORB takes care of serializing it as a Flex/Flash fault event.

Your client application also receives all the information the server code passed with the exception (error message, error code, stack trace).

Show me a basic example of Flex to .NET connectivity.

The following example demonstrates basic invocation of a method in a .NET class.

Consider the following very basic .NET class: The class can be compiled in any of the following Visual Studio solution

types: Class Library, Web Application or Web Service.

C#

namespace Example

{

class BasicService

{

public String SayHello()

{

return “hello world”;

}

}

}

VB.Net

Namespace Example

Class BasicService

Public Function SayHello() As String

Return “hello world”

End Function

End Class

End Namespace

The following code can be used to invoke the SayHello() method shown above from a Flex client:

var ro:RemoteObject = new RemoteObject( “GenericDestination” );

ro.source = “Example.BasicService”;

ro.SayHello.addEventListener( ResultEvent.RESULT, gotHelloResult );

ro.SayHello();

public function gotHelloResult( result:ResultEvent ):void

{

Alert.show( “Server responded – “ + result.result );

}

Deployment

How can I deploy my .NET application so Flex clients can consume its services?

Deployment of a .NET application is as simple as copying the assembly files into a WebORB-enabled IIS virtual directory.

WebORB does not require any additional configuration changes and once copied over, you can start accessing your .NET

classes from a Flex client.

How can deploy WebORB into my existing .NET application?

Deployment involves copying the WebORB assembly and configuration files as well as making a

simple configuration change to register the assembly. There are two methods for deploying WebORB into a virtual

directory corresponding to an ASP.NET application – manual and automated using WebORB Management Console.

The manual deployment is documented in the user guide as well as the Deployment tab of the console.

The automated approach makes WebORB deployment as simple as a folder drag-n-drop.

Security

Automated exposure of the deployed classes sounds dangerous. How can I restrict access to my application?

A main requirement for WebORB was to make it as simple as possible for a developer to get started with the product. As a result, the deployment mechanism is super simple – it requires zero configuration changes. At the same time, WebORB supports a very powerful security system, which can limit access to the executable code at any level, starting with assemblies right down to a particular method declaration. These two requirements coexist through the ‘deployment mode’ set in the product’s configuration file. By default, the mode is ‘open’, so the deployed classes are available for prototyping and application development. The other mode is ‘closed’, where no classes are exposed unless there is an explicit security grant.

How can I secure my application to prevent unauthorized use?

There are two ways to configure code-level security – using your WebORB Management Console or through the product configuration file. Security restrictions can be applied to namespaces, classes and methods. Access to any of these can be restricted to users with particular credentials, or users accessing the application from a defined IP address mask.

Can I add my own authentication or authorization mechanism?

Yes, in fact, WebORB provides a rich extensibility mechanism for custom authentication

and authorization implementations. Applications can be secured to authenticate users against a database or custom security domains.

How can my Flex client know if authentication failed?

When WebORB security restricts access to a secured method (or class, or namespace),

WebORB delivers an exception to the client as a FaultEvent. To indicate a problem with security, the extendedData field of the Fault object encapsulated within FaultEvent is set to 401. As a result, your Flex application code can do a simple check as shown below:

public function handleFault( event: FaultEvent ):void

{

if( Number( event.fault.extendedData ) == 401 )

{

// authentication failure logic goes here

}

}

Data Management/Database integration

Can I use ADO.NET to fetch data from a database and show it in Flex?

Yes, WebORB contains special serialization logic to serialize System.Data.DataTable as an array of complex types. Each complex type in the array is an object with fields corresponding to the column names. As a result, when the server code returns a DataTable, the client side can assign the return value as a data provider for the databindable components (DataGrid, List, etc). Server-side code does not need to include any WebORB specific code.

Does WebORB support Flex Data Management Services (FDMS)?

WebORB currently implements a subset of the FDMS functionality. Application can perform all four basic database operations (CRUD) using the mx.data.DataService API.

Data destination classes can be registered in data-management-config.xml. Client applications can use mx.data.DataService class to perform fill and sync operations. The current release does not support FDMS client synchronization and conflict resolution; however, these features are going to be available in the Flex ActiveRecord implementation we are currently working on (see below).

What is Flex ActiveRecord for WebORB?

Flex ActiveRecord for WebORB will be Midnight Coders enhanced implementation of Flex Data Management Services functionality. It borrows some of the best ideas from the frameworks like Ruby on Rails ActiveRecord and Hibernate. The system will provide a rich interface for all data related operations (data retrieval, construction, update and deletion). It supports transactions and can be easily extended with custom operations. The framework will include a powerful code generator for both ActionScript and .NET (C#/VB.Net) classes.

The client-side API is very similar to the Rails’ ActiveRecord with support for dynamic, patterned methods.

For more info, see the WebORB Blog.

Messaging and Streaming

Does WebORB support Flex Messaging?

Yes, WebORB supports both Flex Producer and Consumer MXML/API and provides integration with MSMQ. WebORB allows to associate MSMQ queues to messaging destinations. Messages published by Flex producers to a messaging destination get delivered to the corresponding queue. Flex consumers subscribe to a destination and become queue listeners. WebORB facilitates the delivery of all messages from the queue to all listeners. Also, WebORB can deliver any messages published by non-Flex producers thus providing integration between Flex and Windows-based applications.

Does WebORB support real-time messaging?

WebORB contains an implementation of the Real-Time Messaging Protocol (RTMP).

As a result, the product supports all the functionality delivered on top of RTMP,

including support for Remote SharedObjects, client stream recording, video streaming, server-to-client invocations.

Can Flex application use Remote SharedObjects in WebORB?

Yes, WebORB includes support for remote SharedObject API.

See the Sample Applications section of the WebORB for .NET product page.

Can I send a message from a client to all other connected clients?

Yes, you can use the SharedObject API to perform a client-side function invocation from a client on all other clients connected to the same SharedObject.

Can I stream Flash video to a Flex/Flash client through WebORB?

Yes, WebORB supports FLV video streaming. An example is included with the WebORB for .NET product distribution.

~ by mjcprasad2000 on March 31, 2009.

Leave a comment