[
http://jira.jboss.com/jira/browse/JBMESSAGING-554?page=comments#action_12... ]
Richard Achmatowicz commented on JBMESSAGING-554:
-------------------------------------------------
1. I've now implented JBossMessagingAdmin class, which was essentially making a copy
of Adrian's JBossMQAdmin class and adjusting the JMX calls to create destinations to
use the Messaging ServerPeer class.
Instead of including an instance of JBossTestServices to get access to JMX, I just picked
up a copy of the MBeanServerConnection object from the JNDI nameserver.
2. I've also implemented the JMSTestCase class:
/**
* JMSTestCase.
* A base test case for all JMS generic test cases.
*
* @author <a href="richard.achmatowicz(a)jboss.com">Richard
Achmatowicz</a>
* @version $Revision: 38213 $
*/
public class JMSTestCase extends JBossTestCase
{
private Logger log = Logger.getLogger(JMSTestCase.class);
protected Admin admin;
/**
* Constructor for JMSTestCase object
* @param name test case name
*/
public JMSTestCase(String name) throws Exception
{
super(name);
}
/**
* Create the Admin object to perform all JMS adminsitrative functions
* in a JMS provider-independent manner
*/
protected void setUp() {
try {
// get the Admin implementation for the current JMS provider
// specified in provider.properties
admin = AdminFactory.getAdmin() ;
} catch (Exception e) {
e.printStackTrace() ;
}
}
public void createQueue(String name) {
try {
admin.createQueue(String name) ;
} catch (Exception e) {
e.printStackTrace() ;
}
}
and so on.
I'll start on refactoring my first test case tomorrow.
Create an Admin abstraction that would allow running generic JMS
tests regardless of provider implementation
------------------------------------------------------------------------------------------------------------
Key: JBMESSAGING-554
URL:
http://jira.jboss.com/jira/browse/JBMESSAGING-554
Project: JBoss Messaging
Issue Type: Sub-task
Components: Tests and Performance
Reporter: Ovidiu Feodorov
Assigned To: Richard Achmatowicz
Fix For: 1.2.0.Beta1
Since Messaging and JBossMQ use slightly different ways of deploying their administered
objects (destinations and connection factories), we need to create an unified Admin
interface that would allow to deploy these artifacts regardless of provider
implementation, and then create plug-ins for Messaging and MQ.
Initial work in this direction has been done by Adrian, see
http://www.jboss.org/index.html?module=bb&op=viewtopic&t=72570
--
This message is automatically generated by JIRA.
-
If you think it was sent incorrectly contact one of the administrators:
http://jira.jboss.com/jira/secure/Administrators.jspa
-
For more information on JIRA, see:
http://www.atlassian.com/software/jira