Recent Posts
Archives

Archive for the ‘en-US’ Category

PostHeaderIcon Mule / MQJE001 / MQJMS2007

Case

In a Mule ESB workflow, the endpoint is a <jms:outbound-endpoint>, pointing to a JMS queue hosted on MQ Series and accessed through WebLogic 10.3.3.

I get the following stracktrace

[java]Exception stack is:
1. MQJE001: Completion Code 2, Reason 2027 (com.ibm.mq.MQException)
com.ibm.mq.MQQueue:1624 (null)
2. MQJMS2007: failed to send message to MQ queue(JMS Code: MQJMS2007) (javax.jms.JMSException)
com.ibm.mq.jms.services.ConfigEnvironment:622 (http://java.sun.com/j2ee/sdk_1.3/techdocs/api/javax/jms/JMSException.html)
3. Failed to create and dispatch response event over Jms destination "queue://MQSERVER/AMQ.4C8A5E112285475605?persistence=1". Failed to route event via endpoint: null. Message payload is of type: JMSObjectMessage (org.mule.api.transport.DispatchException)
org.mule.transport.jms.JmsReplyToHandler:154 (http://www.mulesource.org/docs/site/current2/apidocs/org/mule/api/transport/DispatchException.html)[/java]

Fix

On Mule config file, explicitly set the attribute disableTemporaryReplyToDestinations at true in the JMS outbound tag:

[xml]<jms:outbound-endpoint
queue="jonathan.lalou.jms.queue"
connector-ref="jmsConnector"
transformer-refs="foo" disableTemporaryReplyToDestinations="true"/>[/xml]

PostHeaderIcon Mule / MQJMS3000: failed to create a temporary queue from SYSTEM.DEFAULT.MODEL.QUEUE

Case

I have a Mule workflow, of which outbound is a <jms:outbound-endpoint>. The destination queue is hosted on MQ Series and accessed through WebLogic 10.3.3 bridge.

I get the following error:

MQJMS3000: failed to create a temporary queue from SYSTEM.DEFAULT.MODEL.QUEUE

Complete Stacktrace

[java]2010-11-03 13:03:11,421 ERROR mule.DefaultExceptionStrategy       – Caught exception in Exception Strategy: MQJMS3000: failed to create a temporary queue from SYSTEM.DEFAULT.MODEL.QUEUE
javax.jms.JMSException: MQJMS3000: failed to create a temporary queue from SYSTEM.DEFAULT.MODEL.QUEUE
at com.ibm.mq.jms.services.ConfigEnvironment.newException(ConfigEnvironment.java:644)
at com.ibm.mq.jms.MQConnection.createTemporaryQueue(MQConnection.java:2958)
at com.ibm.mq.jms.MQSession.createTemporaryQueue(MQSession.java:4650)
at com.ibm.mq.jms.MQQueueSession.createTemporaryQueue(MQQueueSession.java:286)
at org.mule.transport.jms.Jms11Support.createTemporaryDestination(Jms11Support.java:247)
at org.mule.transport.jms.JmsMessageDispatcher.getReplyToDestination(JmsMessageDispatcher.java:483)
at org.mule.transport.jms.JmsMessageDispatcher.dispatchMessage(JmsMessageDispatcher.java:171)
at org.mule.transport.jms.JmsMessageDispatcher.doDispatch(JmsMessageDispatcher.java:73)
at org.mule.transport.AbstractMessageDispatcher$Worker.run(AbstractMessageDispatcher.java:262)
at org.mule.work.WorkerContext.run(WorkerContext.java:310)
at edu.emory.mathcs.backport.java.util.concurrent.ThreadPoolExecutor.runWorker(ThreadPoolExecutor.java:1061)
at edu.emory.mathcs.backport.java.util.concurrent.ThreadPoolExecutor$Worker.run(ThreadPoolExecutor.java:575)
at java.lang.Thread.run(Thread.java:619)[/java]

Explanation

A similar issue is described here on Mule support forum. Richard Swart wrote:

This not really mule specific error but an MQ authorization error. The QueueSession.createTemporaryQueue method needs access to the model queue that is defined in the QueueConnectionFactory temporaryModel field (by default this is SYSTEM.DEFAULT.MODEL.QUEUE).

Quick Fix

To fix the issue: on MQ server side, grant visibility to client applications on the default SYSTEM.DEFAULT.MODEL.QUEUE

PostHeaderIcon sljava.dll / IntelliJ IDEA / ActivIdentity

Case

The administrators tried to install ActivIdentity on my desktop. Then I rebooted my computer and launched IntelliJ IDEA 8.1.4 as usual.
IDEA froze. I tried to launch former versions (8.0, 7.5.4), with the same result. Then I launched the idea.bat (available in the same folder as the idea.exe), setting echo on, to have a little more logs.

Stacktrace

[java]Caused by: java.lang.UnsatisfiedLinkError: Expecting an absolute path of the library: \Program Files\ActivIdentity\SecureLogin\sljava.dll[/java]

Complete stacktrace

[java]C:\Program Files\JetBrains\IntelliJ IDEA 8.1.4\bin>"C:\win32app\Java\jdk1.6.0_01\jre\bin\java.exe" "
-Xms256m" "-Xmx1024m" "-XX:MaxPermSize=140m" "-Xbootclasspath/p:../lib/boot.jar " "-ea" -Xbootclassp
ath/a:../lib/boot.jar -cp "..\lib\bootstrap.jar;..\lib\util.jar;..\lib\jdom.jar;..\lib\log4j.jar;.
.\lib\extensions.jar;..\lib\trove4j.jar;C:\win32app\Java\jdk1.6.0_01\lib\tools.jar" com.intellij.ide
a.Main
java.lang.reflect.InvocationTargetException
at sun.reflect.NativeMethodAccessorImpl.invoke0(Native Method)
at sun.reflect.NativeMethodAccessorImpl.invoke(NativeMethodAccessorImpl.java:39)
at sun.reflect.DelegatingMethodAccessorImpl.invoke(DelegatingMethodAccessorImpl.java:25)
at java.lang.reflect.Method.invoke(Method.java:597)
at com.intellij.ide.plugins.PluginManager$2.run(PluginManager.java:126)
at java.lang.Thread.run(Thread.java:619)
Caused by: java.lang.UnsatisfiedLinkError: Expecting an absolute path of the library: \Program Files
\ActivIdentity\SecureLogin\sljava.dll
at java.lang.Runtime.load0(Runtime.java:767)
at java.lang.System.load(System.java:1005)
at com.actividentity.sso.javasso.SSOLoginScriptRunner.(SSOLoginScriptRunner.java:905
)
at com.actividentity.sso.javasso.ConsoleLogger.(Logger.java:54)
at com.actividentity.sso.javasso.Logger.(Logger.java:73)
at com.actividentity.sso.javasso.awt_swing.JavaSSOHook.(JavaSSOHook.java:32)
at sun.reflect.NativeConstructorAccessorImpl.newInstance0(Native Method)
at sun.reflect.NativeConstructorAccessorImpl.newInstance(NativeConstructorAccessorImpl.java:
39)
at sun.reflect.DelegatingConstructorAccessorImpl.newInstance(DelegatingConstructorAccessorIm
pl.java:27)
at java.lang.reflect.Constructor.newInstance(Constructor.java:513)
at java.lang.Class.newInstance0(Class.java:355)
at java.lang.Class.newInstance(Class.java:308)
at java.awt.Toolkit.loadAssistiveTechnologies(Toolkit.java:773)
at java.awt.Toolkit.getDefaultToolkit(Toolkit.java:861)
at java.awt.Window.getToolkit(Window.java:1127)
at java.awt.Window.init(Window.java:369)
at java.awt.Window.(Window.java:407)
at java.awt.Frame.(Frame.java:402)
at java.awt.Frame.(Frame.java:367)
at javax.swing.SwingUtilities$SharedOwnerFrame.(SwingUtilities.java:1731)
at javax.swing.SwingUtilities.getSharedOwnerFrame(SwingUtilities.java:1808)
at javax.swing.JOptionPane.getRootFrame(JOptionPane.java:1673)
at com.intellij.idea.MainImpl.b(MainImpl.java:8)
at com.intellij.idea.MainImpl.a(MainImpl.java:79)
at com.intellij.idea.MainImpl.start(MainImpl.java:73)
… 6 more
ERROR: Error while accessing com.intellij.idea.MainImpl.start with arguments: []
java.lang.reflect.InvocationTargetException
at sun.reflect.NativeMethodAccessorImpl.invoke0(Native Method)
at sun.reflect.NativeMethodAccessorImpl.invoke(NativeMethodAccessorImpl.java:39)
at sun.reflect.DelegatingMethodAccessorImpl.invoke(DelegatingMethodAccessorImpl.java:25)
at java.lang.reflect.Method.invoke(Method.java:597)
at com.intellij.ide.plugins.PluginManager$2.run(PluginManager.java:126)
at java.lang.Thread.run(Thread.java:619)
Caused by: java.lang.UnsatisfiedLinkError: Expecting an absolute path of the library: \Program Files
\ActivIdentity\SecureLogin\sljava.dll
at java.lang.Runtime.load0(Runtime.java:767)
at java.lang.System.load(System.java:1005)
at com.actividentity.sso.javasso.SSOLoginScriptRunner.(SSOLoginScriptRunner.java:905
)
at com.actividentity.sso.javasso.ConsoleLogger.(Logger.java:54)
at com.actividentity.sso.javasso.Logger.(Logger.java:73)
at com.actividentity.sso.javasso.awt_swing.JavaSSOHook.(JavaSSOHook.java:32)
at sun.reflect.NativeConstructorAccessorImpl.newInstance0(Native Method)
at sun.reflect.NativeConstructorAccessorImpl.newInstance(NativeConstructorAccessorImpl.java:
39)
at sun.reflect.DelegatingConstructorAccessorImpl.newInstance(DelegatingConstructorAccessorIm
pl.java:27)
at java.lang.reflect.Constructor.newInstance(Constructor.java:513)
at java.lang.Class.newInstance0(Class.java:355)
at java.lang.Class.newInstance(Class.java:308)
at java.awt.Toolkit.loadAssistiveTechnologies(Toolkit.java:773)
at java.awt.Toolkit.getDefaultToolkit(Toolkit.java:861)
at java.awt.Window.getToolkit(Window.java:1127)
at java.awt.Window.init(Window.java:369)
at java.awt.Window.(Window.java:407)
at java.awt.Frame.(Frame.java:402)
at java.awt.Frame.(Frame.java:367)
at javax.swing.SwingUtilities$SharedOwnerFrame.(SwingUtilities.java:1731)
at javax.swing.SwingUtilities.getSharedOwnerFrame(SwingUtilities.java:1808)
at javax.swing.JOptionPane.getRootFrame(JOptionPane.java:1673)
at com.intellij.idea.MainImpl.b(MainImpl.java:8)
at com.intellij.idea.MainImpl.a(MainImpl.java:79)
at com.intellij.idea.MainImpl.start(MainImpl.java:73)
… 6 more
ERROR: Error while accessing com.intellij.idea.MainImpl.start with arguments: []
java.lang.AssertionError: Error while accessing com.intellij.idea.MainImpl.start with arguments: []
at com.intellij.openapi.diagnostic.DefaultLogger.error(DefaultLogger.java:49)
at com.intellij.openapi.diagnostic.Logger.error(Logger.java:56)
at com.intellij.ide.plugins.PluginManager$2.run(PluginManager.java:130)
at java.lang.Thread.run(Thread.java:619)[/java]

Explanation and Fix

I ran other Java applications, such as Eclipse and Mule ESB. The result was the same.

When you look at the stacktrace, you can see that sun.reflect.NativeConstructorAccessorImpl.newInstance0 calls com.actividentity.sso.javasso.awt_swing.JavaSSOHook. This makes me think ActivIdentity intercepts Java calls, even of very low level, and checks them before executing them. I don’t know if compiled code of JRE’s jars is modified, or if some methods are inserted through a mechanism similar to AOP. Anyway, the fact is that ActivIdentity is always called, even though I doubt a lot that original HotSpot was designed to do so…

I tried to uninstall ActivIdentity, this had no effect. I looked in Windows regedit but I found nothing. I tried also to check the value of java.library.path which, for Windows, points to Windows’PATH environment variable.

Therefore, the only solution I found to fix the issue was to changed the JAVA_HOME parameter (more accurately: the parameter IDEA_JDK) from one JDK to another, in my case: from 1.6.0_01 to 1.6.0_18)

PostHeaderIcon Tutorial: from an application, make a clustered application, within WebLogic 10

Abstract

You have a non-clustered installation, on the host with DNS name jonathanDevDesktop, with an admin (port: 7001), a muletier (port: 7003) and a webtier (port: 7005) instances.
You need set your muletier as a clustered installation, with two nodes, on the same server. The second node will dedeployed on port 7007.

We assume you have a configured JMS Modules (in our case: JmsMqModule, even though the bridge between WebLogic and MQ has no impact here).

Process

Batches

  • Copy $DOMAINS\jonathanApplication\start-muletier-server.bat" as $DOMAINS\jonathanApplication\start-muletier-server-2.bat"
  • Edit it:
    • Possibly, modify the debug port (usually: 5006)
    • Replace the line
      call "%DOMAIN_HOME%\bin\startManagedWebLogic.cmd" muletier t3://jonathanDevDesktop:7001

      with

      call "%DOMAIN_HOME%\bin\startManagedWebLogic.cmd" muletier2 t3://jonathanDevDesktop:7001

Second Node Creation

  • Following points are not required.
    • Copy the folder %DOMAIN_HOME%\servers\muletier as %DOMAIN_HOME%\servers\muletier2
    • Delete the folders %DOMAIN_HOME%\servers\muletier2\cache and %DOMAIN_HOME%\servers\muletier2\logs
  • Stop the server muletier
  • On WebLogic console:
    • Servers > New > Server Name: muletier2, Server Listen Port: 7007 > Check Yes, create a new cluster for this server. > Next
    • Name: jonathanApplication.cluster.muletier > Messaging Mode: Multicast, Multicast Address: 239.235.0.4, Multicast Port:5777
    • Clusters > jonathanApplication.cluster.muletier > Configuration > Servers > Select a server: muletier
    • Clusters > jonathanApplication.cluster.muletier > Configuration > Servers > Select a server: muletier2
  • Start the instances of muletier and muletier2 in MS-DOS consoles.
  • On the WebLogic console:
    • Deployments > jonathanApplication-web (the mule instance) > Targets > check “jonathanApplication.cluster.muletier” and “All servers in the cluster” > Save
  • On the muletier2 DOS console, you can see the application is deployed.

JMS Configuration

The deployment of JMS on clustered environment is a little tricky.

  • On WebLogic console: JMS Modules > JmsMqModule > Targets > check “jonathanApplication.cluster.muletier” and “All servers in the cluster
  • Even though it is not required, restart your muletiers. Then you can send messages either on port 7003 or 7007, they will be popped and handled the same way.

PostHeaderIcon Tutorial: Use WebShere MQ as JMS provider within WebLogic 10.3.3, and Mule ESB as a client

Abstract

You have an application deployed on WebLogic 10 (used version for this tutorial: 10.3.3). You have to use an external provider for JMS, in our case MQ Series / WebSphere MQ.
The client side is a Mule ESB launched in standalone.

Prerequisites

You have:

  • a running WebLogic 10 with an admin instance and an another instance, in our case: Muletier.
  • a file file.bindings, used for MQ.

JARs installation

  • Stop all your WebLogic 10 running instances.
  • Get the JARs from MQ Series folders:
    • providerutil.jar
    • fscontext.jar
    • dhbcore.jar
    • connector.jar
    • commonservices.jar
    • com.ibm.mqjms.jar
    • com.ibm.mq.jar
  • Copy them in your domain additional libraries folder (usually: user_projects/domains/jonathanApplication/lib/)
  • Start WebLogic 10 admin. A block like this should appear:
    [java]&lt;Oct 15, 2010 12:09:21 PM CEST&gt; &lt;Notice&gt; &lt;WebLogicServer&gt; &lt;BEA-000395&gt; &lt;Following extensions directory contents added to the end of the classpath:
    C:\win32app\bea\user_projects\domains\jonathanApplication\lib\com.ibm.mq.jar;C:\win32app\bea\user_projects\domains\jonathanApplication\lib\com.ibm.mqjms.jar;C:\win32app\bea\user_projects\domains\jonathanApplication\lib\commonservices.jar;C:\win32app\bea\user_projects\domains\jonathanApplication\lib\connector.jar;C:\win32app\bea\user_projects\domains\jonathanApplication\lib\dhbcore.jar;C:\win32app\bea\user_projects\domains\jonathanApplication\lib\fscontext.jar;C:\win32app\bea\
    user_projects\domains\jonathanApplication\lib\providerutil.jar&gt;[/java]

Config

  • Get file.bindings, copy it into user_projects/domains/jonathanApplication/config/jms, rename it as .bindings (without any prefix)
  • Launch the console, login
  • JMS > JMS Modules > Create JMS System Module > Name: JmsMqModule. Leave other fields empty. > Next > target server MuleTier > Finish
  • Select JmsMqModule > New > Foreign Server > Name: MQForeignServer > keep check MuleTier > Finish
    • Select MQForeignServer >
    • Tab Connection Factories > New >
      • Name: MQForeignConnectionFactory
      • Local JNDI Name: the JNDI name on WebLogic side, eg: jonathanApplication/jms/connectionFactory/local (convention I could observe: separator on WebLogic: slash '/' ; unlike clients for which the separator in a dot '.')
      • Remote JNDI Name: the JNDI name on MQ side, eg: JONATHAN_APPLICATION.QCF
      • OK
    • Tab Destinations > New >
      • Queue of requests:
        • Name: JONATHAN.APPLICATION.REQUEST
        • Local JNDI Name: JONATHAN.APPLICATION.REQUEST
        • Remote JNDI Name: JONATHAN.APPLICATION.REQUEST
      • Queue of response:
        • Name: JONATHAN.APPLICATION.REPONSE
        • Local JNDI Name: JONATHAN.APPLICATION.REPONSE
        • Remote JNDI Name: JONATHAN.APPLICATION.REPONSE
      • NB: usually, MQ data are upper-cased and Java’s JNDI names are low-cased typed ; anyway (because of Windows not matching case?) here we use uppercase in for both names.

Mule

This part of the tutorial deals with a case of Mule ESB being your client application (sending and/or receiving JMS messages).

  • Get the archive wlfullclient.jar (56MB). Alternatively, you can generate it yourself: go to the server/lib directory of your WebLogic installation (usually: C:\win32app\bea\wlserver_10.3\server\lib, and run: java -jar wljarbuilder.jar
  • Copy the archive into $MULE_HOME/lib/user
  • Copy the seven jars above (providerutil.jar, fscontext.jar, dhbcore.jar, connector.jar, commonservices.jar, com.ibm.mqjms.jar, com.ibm.mq.jar) into the same folder: $MULE_HOME/lib/user
  • You can launch the mule. The config file is similar to any other configuration using standard JMS.

PostHeaderIcon No handlers could be found for logger…

Case

You run a Python script, and you get an error similar to:
[python]No handlers could be found for logger &quot;stomp.py&quot;[/python]

Fix

Edit the script, and add the following block:
[python]import logging
logging.basicConfig()[/python]
This will produce explicit log that will allow you to identity the source of the actual issue.

PostHeaderIcon Tutorial: an Event Bus Handler for GWT / GXT

Overview

Introduction

Let’s consider a application, JonathanGwtApplication, divided in three main panels

  • a panel to select animal name name
  • a panel to display, expand and collapse trees of the animal ancestors
  • a panel of information to display many indicators (colors, ages, etc.).

An issue we encounter is: how to make the different panels communicate? In more technical terms, how to fire events from a panel to another one?

A first solution would be to declare each panel as listener to the other panels. Indeed, this principle may go further, and declare each component as listener to a list of other components…
Main drawbacks:

  • the code becomes hard to read
  • adding or removing a component requires to modify many parts of the code
  • we don’t follow GWT 2’s “philosophy”, which is to use Handlers rather than Listeners.

Hence, these reasons incited us to provide a global EventBusHandler.

The EventBusHandler concept

The EventBusHandler is a global bus which is aware of all events that should be shared between different panels, and fires them to the right components.
The EventBusHandler is a field of JonathanGwtApplicationContext.

Intrastructure

  • lalou.jonathan.application.web.gwt.animal.events.HandledEvent: generic interface for a event. Abstract method:
    [java]EventTypeEnum getEventEnum();[/java]
  • lalou.jonathan.application.web.gwt.animal.handler.EventHandler: generic interface for a component able to handle an event. Abstract method:
    [java]void handleEvent(HandledEvent handledEvent);[/java]
  • lalou.jonathan.application.web.gwt.animal.handler.EventHandlerBus: the actual bus. As a concrete class, it has two methods:
    [java]/**
    * Fires an event to all components declared as listening to this event
    * event type.
    *
    * @param baseEvent
    */
    public void fireEvent(HandledEvent baseEvent) {
    // …
    }

    /**
    * Adds an listener/handler for the event type given as parameter
    *
    * @param eventTypeEnum
    * @param eventHandler
    * @return The List of handlers for the key given as parameter. This list
    * contains the eventHandler that was given as second parameter
    */
    public List<EventHandler> put(EventTypeEnum eventTypeEnum,
    EventHandler eventHandler) {
    // …
    }[/java]

How to use the bus?

  1. Define an event: in JonathanGwtApplication, an event is decribed by two elements:
    • a functionnal entity: eg: “animal”, “food”, “tree node”. The functionnal entity must be isomorph to a technical DTO, eg: AnimalDTO for an entity Animal.(in the scope of this turoriel we assume to have DTOs, even though the entities may ne sufficient)
    • a technical description of the event: “selection changed”, “is expanded”
  2. Add an entry in the enum EventTypeEnum. Eg: “ANIMAL_SELECTION_CHANGED
  3. in lalou.jonathan.application.web.gwt.animal.events, create an event, implementing HandledEvent and its method getEventEnum(). The match between EventTypeEnum and DTO is achieved here. Eg:
    [java]public class AnimalSelectionChangedEvent extends
    SelectionChangedEvent<AnimalDTO> implements HandledEvent {

    public AnimalSelectionChangedEvent(
    SelectionProvider<AnimalDTO> provider,
    List<AnimalDTO> selection) {
    super(provider, selection);
    }

    public EventTypeEnum getEventEnum() {
    return EventTypeEnum.ANIMAL_SELECTION_CHANGED;
    }

    }[/java]

  • When an event that should interest other component is fired, simply call the bus. The bus will identify the event type and dispatch it to the relevant handlers. eg:
    [java]animalComboBox.addSelectionChangedListener(new SelectionChangedListener<AnimalDTO>() {

    @Override
    public void selectionChanged(SelectionChangedEvent<AnimalDTO> se) {
    final AnimalDTO selectedAnimalVersion;
    selectedAnimalVersion= se.getSelectedItem();
    JonathanGwtApplicationContext.setSelectedAnimal(selectedAnimal);

    final AnimalSelectionChangedEvent baseEvent = new AnimalSelectionChangedEvent(
    se.getSelectionProvider(), se.getSelection());
    JonathanGwtApplicationContext.getEventHandlerBus()
    .fireEvent(baseEvent);

    }
    });[/java]

  • Handlers:
    • easy case: the component handles only one type of event: this handler must implement the right interface (eg: AnimalSelectionChangedEventHandler) and its method, eg:
      [java]protected void handleAnimalSelectionChangedEvent(HandledEvent handledEvent) {
      return;
      }[/java]
    • frequent case: the component handles two or more event types. No matter, make the component implement all the needed interfaces (eg: AnimalSelectionChangedEventHandler, FoodSelectionChangedEventHandler). Provide a unique entry point for the method to implement, which is common to both interfaces. Retrieve the event type, and handle it with ad hoc methods. Eg:
      [java]public void handleEvent(HandledEvent handledEvent) {
      final EventTypeEnum eventTypeEnum;

      eventTypeEnum = handledEvent.getEventEnum();

      switch (eventTypeEnum) {
      case ANIMAL_SELECTION_CHANGED:
      handleAnimalSelectionChangedEvent(handledEvent);
      return;
      case FOOD_SELECTION_CHANGED:
      handleFoodSelectionChangedEvent(handledEvent);
      return;
      default:
      break;
      }
      }

      protected void handleAnimalSelectionChangedEvent(HandledEvent handledEvent) {
      // do something
      }
      protected void handleFoodSelectionChangedEvent(HandledEvent handledEvent) {
      // do something else
      }[/java]

  • PostHeaderIcon SQL*Plus Does Not Update a Stored Procedure

    Case

    You have a stored procedure that you would like to update. The script is OK with TOAD, but raises an error when launched via SQL*Plus.

    Fix

    Add a slash (‘/’) or a dot (‘.’) at the end of file.

    PostHeaderIcon Use a JDBC datasource from WebLogic’s JNDI

    Case

    Your application is connected to a database. The configuration of the DB connexion is set in a Spring file. You would like the connexion to be set in WebLogic, so that no URL/login/password lays in your source code.

    Steps

    WebLogic

    Create a new data source:

    • go the WebLogic console >
      • JDBC >
        • DataSource >
          • New >
            • set the name, JNDI name (eg: database.jndi.name), DB type  (Oracle, Sybase, …) >
              • Next >
                • Select the driver >
                  • Next >
                    • Select the targeted server(s)

    This will

    1. create a new file <yourDomain>/config/jdbc/<datasourceName>-XXXX-jdbc.xml.
    2. add a <jdbc-system-resource> block in <yourDomain>/config/config.xml

    Spring

    Replace the block:

    [xml]<bean id="dataSource" class="org.apache.commons.dbcp.BasicDataSource">
    <property name="driverClassName" value="${database.driver}" />
    <property name="url" value="${database.url}" />
    <property name="username" value="${database.username}" />
    <property name="password" value="${database.password}" />
    </bean>[/xml]

    with:

    [xml]<jee:jndi-lookup id="dataSource" jndi-name="${database.jndi.name}" />[/xml]

    PostHeaderIcon How to shutdown Hudson?

    Hudson is launched via a command line (java -jar hudson.war). But to shutdown it, provided that your Hudson is deployed on http://localhost:8080/hudson, you will have to open the following URL in your webbrowser:
    http://localhost:8080/hudson/exit