Tuesday 27 May 2014

Configure Oracle Enterprise Repository to use WebLogic JMS

The Oracle Enterprise Repository still out-of-the-box uses ActiveMQ-JMS for its internal messaging. As it runs on WebLogic Server anyways and WebLogic users might probably find it easier to manage WebLogic's built in JMS instead of ActiveMQ, here is a how-to. Many thanks to Sören Halter, who found this solution, but for the lack of an own Blog he handed it over to me.

The first step is to configure JMS Server on WebLogic. If you are not in developer mode, click 'Lock & Edit' first.


In the WebLogic Console under Services | Messaging | JMS Servers click new.


Give it a name and continue with 'Next'.


Choose the server where the OER is installed and click Finish.
The next step is to create a JMS System Module


Under <domain_name>|Services|Messaging|JMS Modules click 'New'. Give it a name and click 'Next' to continue.


Again choose the server that OER is installed at and click 'Next'.


Check 'Would you like...' because this is the next step anyways and click 'Finish' to end this Wizard.


We need a JMS Topic, so under 'Summary of Resources' click 'New'.


Choose 'Topic' and click 'Next'.


Give it a name and a JNDI Name, for example OERTopic and jms.OERTopic. Then and click 'Next'.


Choose 'Create a New Subdeployment'


The default is OK, click 'OK'


Choose the former created JMS Server and click 'Finish'

We are done on WebLogic Console. Next, ActiveMQ needs to be disabled. Open the OER Web Interface and login as Admin.


The required setting cmee.eventframework.embedded.jms.enabled is disabled, so go to Admin|System Settings, paste it to the 'Enable New System Setting' box and click 'Enable'.


Go to the now visible cmee.eventframework.embedded.jms.enabled Setting and set it to false. Then do the same for
  • cmee.eventframework.jndi.provider.url : t3://<hostname>:<OER-Server port>
  • cmee.eventframework.jndi.user : weblogic
  • cmee.eventframework.jndi.password : welcome1 ;-)
  • cmee.eventframework.jndi.context.factory : weblogic.jndi.WLInitialContextFactory
  • cmee.eventframework.jms.connection.factory : weblogic.jms.ConnectionFactory
  • cmee.eventframework.jms.topic : in my case jms.OERTopic (see above)
Then scroll to the bottom and click save.


Finally it should look like this. That's it for the configuration. To check that it really works, we could use a durable subscriber.



Navigate to the newly created Topic (Services|Messaging|JMS Modules|OER-SystemModule, klick on the Topic). If you are in production mode don't forget to click 'Lock & Edit'.


Go to Monitoring|Durable Subscribers and click 'New'


Give it a name, choosing the same value for the Client ID is fine.


The durable subscriber is created, but right now there are no Messages. So it is time to generate some load. Login to OER, create some assets, register them etc.. Then back to the durable subscriber, check the box in the first column and click the 'Show Messages' button.


Click on one of them to see what OER is talking about


So the WLS JMS configuration for OER is up and running.
This is of course only a basic set up, see 'Configuring and Managing JMS for Oracle WebLogic Server' for more sophisticated WebLogic JMS configurations.

Friday 16 May 2014

Running JME and JSE Embedded / JES on the same Raspberry Linux Distribution

For complex projects in with embedded technology, it might make sense to combine several Oracle tools. For example, use the Java Micro Edition (JME) for the ease of connectivity to external devices and combine that with the Java Embedded Suite based on Java Standard Edition Embedded, for example for using Oracle Event Processing Embedded to do some post processing.
To use both products on the same Raspberry Pi system, it is important choose the rigth Linux distribution.
JME8 needs libraries built for usage of a hardware FPU (armhf), whereas JSE Embedded needs libraries for software FPU emulation (armsf). See also "What do you mean by "soft float ABI" and "hard float ABI"?".
The Debian based distributions I tried (Wheezy, Raspbian) require to choose one specific image built for armhf or armsf. And the latest one with armsf that I found is of late 2012, so and apt-get upgrade takes quite a few hours on a Raspberry Pi. So depending on the chosen distribution image, only JME or JES can be used, but not both, which might be fine depending on the requirements.
To use both on one system, a distibution should be choosen, which supports both, armsf and armhf. Pidora does the trick see link, so JES and JME can be run on the same system (Marcel, thanks for the hint).

---8<-----------------------------------------------------------------------------------------

UPDATE: in between, Oracle has also released JSE Embedded with support armhf, but for example Oracle Event Processing Embedded does not support that version. So it is still a good idea to use Pidora as long as it is not clear that all required software will use armhf