Saturday, February 22, 2014

An Introduction to Oracle Mobile Suite

Here is a quick overview and introduction to the Oracle Mobile Suite. There are basically four areas that the Oracle Mobile Suite helps with your mobile strategy:
  • Development of multichannel applications with Oracle Mobile Application Framework
  • Data and services integration across the enterprise with Oracle SOA Suite
  • Uniform information security across all layers of enterprise and mobile applications with Oracle Identity Management
  • Deployment and management (cloud and on premise) of multichannel applications with Oracle Cloud Application Foundation
The video below shows the core capabilities of the Oracle Mobile Suite and how can you benefit of it.


Wednesday, February 5, 2014

Getting Started with HTML5 WebSocket on Oracle WebLogic 12c

The current release of Oracle WebLogic (12.1.2) added support to HTML5 WebSocket (RFC-6455) providing the bi-directional communication over a single TCP connection between clients and servers. Unlike the HTTP communication model, client and server can send and receive data independently from each other. 

The use of WebSocket is becoming very popular for highly interactive web applications that depend on time critical data delivery, requirements for true bi-directional data flow and higher throughput.
To initiate the WebSocket connection, the client sends a handshake request to the server. The connection is established if the handshake request passes validation, and the server accepts the request. When a WebSocket connection is established, a browser client can send data to a WebLogic Server instance while simultaneously receiving data from that server instance. 

The WebLogic server implementation has the following components:
  •  The WebSocket protocol implementation that handles connection upgrades and establishes and manages connections as well as exchanges with the client. The WebLogic server fully implements the WebSocket protocol using its existing threading and networking infrastructure.
  • The WebLogic WebSocket Java API, through the weblogic.websocket package, allows you to create WebSocket-based server side applications handling client connections, WebSocket messages, providing context information for a particular WebSocket connection and managing the request/response handshake. For additional information about the WebLogic WebSocket Java API interfaces and classes, visit the following resource: http://docs.oracle.com/middleware/1212/wls/WLPRG/websockets.htm#BABJEFFD
  • To declare a WebSocket endpoint you use the @WebSocket annotation that allow you to mark a class as a WebSocket listener that's ready to be exposed and handle events. The annotated class must implement the WebSocketListener interface or extend from the WebSocketAdapter class.
When you deploy the WebSocket-based application on WebLogic, you basically follow the same approach using the standard Java EE Web Application archives (WARs), either as standalone or WAR module. Either way, the WebLogic Application Server detects the @WebSocket annotation on the class and automatically establishes it as a WebSocket endpoint.

Here is a simple application that creates a WebSocket endpoint at the /echo/ location path, receives messages from the client and sends the same message back to the client.

import weblogic.websocket.WebSocketAdapter;
import weblogic.websocket.WebSocketConnection;
import weblogic.websocket.annotation.WebSocket;

@WebSocket(pathPatterns={"/echo/*"})
public class Echo extends WebSocketAdapter{

@Override
  public void onMessage(WebSocketConnection connection, String msg){
      try{
          connection.send(msg);
      }catch(IOException ioe){
          //Handle error condition
      }
  }

}

On the client side, you typically use the WebSocket JavaScript API that most of the web browsers already support.


There are many samples out there that you can use to test the implementation above. One quick way of doing that is to navigate to http://www.websocket.org/echo.html and then point the location field to your WebLogic server. If you follow the sample available on https://github.com/mjabali/HelloWorld_WebSocket then you'll end up with something like ws://localhost:7001/HelloWorld_WebSocket/echo/ for the WebSocket server application.

The sample client provided will be available at http://localhost:7001/HelloWorld_WebSocket/index.html after the WebLogic deployment. See the README.md file on GitHub for additional instructions.

Have fun!

Wednesday, October 30, 2013

Getting Started with Oracle WebLogic 12c Dynamic Clusters

One of the new features introduced on WebLogic 12c (12.1.2) is the ability to create and add new managed servers to a clustered environment dynamically. Dynamic Clusters make the task of creating additional servers for scaling out your environment really easy.
 You no longer have to configure managed servers individually but instead you configure a cluster with the number of servers you want and the server template or the domain default values. From there the system maps out managed servers with attributes inherited from the server template.

Dynamic clusters can absolutely be a building block for elasticity in the cloud environment.


To create a sample WebLogic Dynamic Cluster configuration, follow the steps below:

- Download and install Oracle WebLogic Server 12.1.2 at http://www.oracle.com/technetwork/middleware/fusion-middleware/downloads/index.html

- Create a new domain called mydomain. If you need the instructions on how to create a WebLogic domain, go to: http://docs.oracle.com/middleware/1212/wls/WLDCW/newdom.htm#i1097775

- Start WebLogic Admin Server by running $WLS_HOME/user_projects/domains/my_domain/startWebLogic.sh | .bat where WLS_HOME is the directory where you have installed WebLogic

- Navigate to WebLogic console at http://localhost:7001/console (default settings used here)

- Under the domain structure, click on Machines and configure a new Machine called myMachine and the default settings.

- Create the Dynamic Cluster. Click on Cluster under the Domain Structure menu



- Click on the New button and then select Dynamic Cluster

- Specify the name for your Dynamic Cluster (i.e. myDynamicCluster) and press Next


- Select the number of dynamic server you want to configure, select the server name prefix and the template to be used when creating new servers. Click Next


- For this simple local configuration, specify the Machine Binding to be using the machine you created (myMachine) previously. Click Next




- Select the listen port for the first server in the dynamic cluster and then the SSL lister port for the first server in the dynamic cluster. The subsequent servers will be assigned with an incremental port number. Click Next



- You will be presented with the summary of your New Dynamic Cluster configuration. Click Finish and it will be created for you.


- The Summary of Clusters screens should show you the recently created Dynamic Cluster.


- Click on myDynamicCluster and then go to the Control tab. 


Before you can start any of the dynamic cluster members, make sure you have started the Node Manager on your machine with the following command: $WLS_HOME/user_projects/domains/my_domain/bin/startNodeManager.sh | .bat

As soon as the Node Manager is started, then go back to the WebLogic Admin Console, then select one of the servers in the cluster and then click Start. As a result of that operation, you should see the selected server up and running.


- The next step here is to start the other servers configured in your cluster and as a bonus you can dynamically add new members to the dynamic cluster.


I hope you found this sample tutorial and stay tuned for more!

Tuesday, October 22, 2013

Oracle Mobile Development Platform Workshop

It has been almost five months since I started at Oracle and I have been busy working on a bunch of different technologies including WebLogic, Coherence, Service Bus, API Gateway and obviously Mobile. If you are interested in the Oracle Mobile Development Platform, we are offering a free technical webinar on October 30th at 9:30 AM Pacific/10:30 AM Mountain.  This is going to be a 90 minute technical presentation and demonstration where you will see how:
  • You can develop Mobile Applications once and deploy natively to both iOS and Android
  • Resulting  Applications allow your company’s employees and customers to securely access your internal packaged and custom applications from any device
  • Your Mobile Applications are written Java and HTML5, but leverage native device functionality such as GPS, Camera, Address Book and Accelerometer
  • The Resulting Applications look, feel, and perform as though they were natively developed, i.e., these are not just web applications running in a phone’s browser
  • Oracle is using the Mobile Development Platform for their own application delivery
  • Oracle’s Mobile Platform enables full lifecycle support of Mobile Applications covering their development, end-to-end security, service connectivity and integration, deployment, distribution and management
To attend the webinar, please contact me at: mqjabali [at] gmail dot com

See you online...

Wednesday, June 19, 2013

The new 127.0.0.1

I've started on a new job a week ago at Oracle and I'm very impressed with what I've seen so far. First of all, after 8 years I'm back to the office life and not working from home full time. Honestly, I was missing that kind of stuff and the interactions and conversations I've in the office are unbeatable. There are so many smart folks here that anytime I hear them talking about the exciting things they are working on I can't wait to finish all of the paperwork and onboarding stuff and get my hands dirty with the technology.
I'm working out of one of the old Sun Microsystems offices and you can imagine that most of the guys and girls here are either from the hardware side, Linux or Solaris...
I'm primarily working with the Oracle Fusion Middleware product line which is a long list of products itself.
I've heard so many different opinions about my decision to join Oracle and I prefer to keep the good ones for now. Nobody builds a company like this without passion and hard work and I truly believe this is going to be a fun ride.

Tuesday, April 9, 2013

Using TIBCO Silver Mobile with TIBCO Web Messaging

Every company has or it's planning to have a mobile app these days and among other top priorities like Social, Event Processing, Analytics and Cloud, Mobility is a hot topic for CIOs looking for how they can change the game and put on their internal and external consumers' fingertips the right information at the right time with the right context. Not only that requirement but also how to capture, sense, act and respond to business events and notify mobile users of actions they need to take or what just happened that's so important to them.

Sometimes, there is a big disconnection between the "App" and all the backend systems that really do all the heavy lifting.

Integrating those two distinct worlds is getting easier primarily because of technologies like TIBCO Silver Mobile and TIBCO Web Messaging. Those product already have their huge value attached to their capabilities but when you combine them then the value brought to the table is extreme. 

TIBCO Silver Mobile is an open mobile development application platform (MDAP) that lets you build and manage mobile apps and create your own secure enterprise app portal. The platform lets you leverage whatever investments you've made in back-end automation infrastructure, whether from TIBCO or another provider.

Some of the Silver Mobile benefits are:

Helps decrease mobile application development time and cost with a cross-platform, write-once environment and simplified Java and HTML5 back-end integration capabilities
Lets you easily build onto your web application code base and add provisions for using pictures, video, contacts, and other data collected by mobile workers to mobile applications
Deploys mobile apps securely on your own mobile app portal using your existing security standards and controls access to app downloads and the information available through them
- Supports Android, iOS, and others – and provides a familiar mobile app download process
Gives front-line mobile workers access to the full resources of the enterprise by letting them access and contribute information in real time

You can download TIBCO Silver Mobile from the TIBCO Access Point (TAP) here: http://tap.tibco.com/storefront/trialware/tibco-silver-mobile/prod15310.html

On the other hand, TIBCO Web Messaging overcomes traditional HTTP-based web architectures that simply don't provide the real-time, bidirectional communication that today's new applications and services demand by using HTML5 WebSocket.

Some of the Web Messaging benefits are:

Build compelling real-time applications using the new HTML5 WebSocket standard for low-latency web communication with a fraction of the overhead of existing web architectures.
Use HTML5 API for Java Message Service, support legacy browsers, and natively integrate TIBCO EMS for faster and at less costly web and mobile application development.
Don't sacrifice enterprise readiness to get next-generation web services with TIBCO Enterprise Message Service integration, enhanced security, and connection offloading.
Natively integrate with TIBCO Enterprise Message Service to extend the reach of enterprise IT infrastructures through asynchronous or synchronous communication.
Provide real-time full-duplex communication for web applications with HTML5 WebSocket at a fraction of the overhead of existing web architectures.
Simplify application development for multiple client platforms with a JMS-client API familiar to enterprise developers.

In conclusion, combining these two powerful technologies give the business users not only full access to the information they need at any time and any place but also leverage the resources your company already invested on.

Thursday, January 17, 2013

Configuring TIBCO Web Messaging to Securely Connect to TIBCO EMS

If you want to configure your TIBCO Web Messaging gateway, which normally lives in the DMZ, to connect to TIBCO EMS messaging backbone over a TCP connection, the procedure is straightforward. Just point to the TIBCO EMS server hostname and port number, assuming that's already open in the firewall, in the trusted network and that's it.

Something similar to the following service (stomp.jms) configuration should be enough:

<service>
  <accept>ws://${gateway.hostname}:${gateway.nonsecure.port}/jms</accept>
  <type>stomp.jms</type>
    <properties>
      <connection.factory.name>GenericConnectionFactory</connection.factory.name>
      <context.lookup.topic.format>%s</context.lookup.topic.format>
      <context.lookup.queue.format>%s</context.lookup.queue.format>
      <env.java.naming.factory.initial>
            com.tibco.tibjms.naming.TibjmsInitialContextFactory
      </env.java.naming.factory.initial>
      <env.java.naming.provider.url>
            tcp://${EMS.hostname}:${EMS.portNumber}
      </env.java.naming.provider.url>
      <destination.strategy>session</destination.strategy>
    </properties>
    <realm-name>dev_realm</realm-name>
    <authorization-constraint>
      <require-role>AUTHORIZED</require-role>
    </authorization-constraint>
  </service>

Now, if you want to configure an end-to-end secured enabled environment then some extra parameters are necessary to make everything work correctly. The service configuration below will give you what you need (most of them are self-explanatory) to enable that.

<service>
    <accept>wss://${gateway.hostname}:${gateway.secure.port}/jms</accept>
    <type>stomp.jms</type>  
    <properties>
     <connection.factory.name>SecureConnectionFactory</connection.factory.name>
      <context.lookup.topic.format>%s</context.lookup.topic.format>
      <context.lookup.queue.format>%s</context.lookup.queue.format>
      <connection.security.principal>ems_user</connection.security.principal>
      <connection.security.credentials>ems_password</connection.security.credentials>
      <env.java.naming.factory.initial>
          com.tibco.tibjms.naming.TibjmsInitialContextFactory
      </env.java.naming.factory.initial>
      <env.com.tibco.tibjms.naming.security_protocol>
          ssl
      </env.com.tibco.tibjms.naming.security_protocol> 
      <env.java.naming.provider.url>
         ssl://${EMS.hostname}:${EMS.securePortNumber}
      </env.java.naming.provider.url>
      <env.com.tibco.tibjms.naming.ssl_enable_verify_host>
         true
      </env.com.tibco.tibjms.naming.ssl_enable_verify_host>  
      <env.com.tibco.tibjms.naming.ssl_trusted_certs>
         ems_certificate.pem
      </env.com.tibco.tibjms.naming.ssl_trusted_certs> 
      <env.com.tibco.tibjms.naming.ssl_trace>
         true
      </env.com.tibco.tibjms.naming.ssl_trace>
      <destination.strategy>session</destination.strategy>
     </properties>
     <realm-name>dev_realm</realm-name>
     <authorization-constraint>
      <require-role>AUTHORIZED</require-role>
    </authorization-constraint>  
  </service>

The current version of TIBCO Web Messaging also provides you a really nice feature called Reverse Connectivity where you will be able to close all incoming traffic ports while still allowing external clients to initiate the connection. But, this is a topic to be explored on a next post. Stay tuned!