djyoti sahu

Greenhorn
+ Follow
since Jan 28, 2003
Merit badge: grant badges
For More
Cows and Likes
Cows
Total received
0
In last 30 days
0
Total given
0
Likes
Total received
0
Received in last 30 days
0
Total given
0
Given in last 30 days
0
Forums and Threads
Scavenger Hunt
expand Ranch Hand Scavenger Hunt
expand Greenhorn Scavenger Hunt

Recent posts by djyoti sahu

It requires tools.jar in lib folder of webapplication
17 years ago
Sap Netweaver is a integration tool which is based on open standard like J2EE,SOAP,XML.

It uses all j2ee specification.Depending upon the the component the technologies plays the role.For portal it require java + servlet;for exchange infrastructure it require webservices and ejb.

Netweaver provides technology as well as domain
17 years ago
Hi,
How could I see the transalted sql from ejb ql in jboss server.

MyEclipse is IDE for my development environment.

Regrads
jyoti
18 years ago
Hi
All,
It may be silly question. Please let me know if I can use two ejb-jar.xml files in ear.

Regards
djyoti
Hi all,
How to upload .xls and .doc to server side.
regards
jyoti
19 years ago
Hi
all,
please tell me.
How to convert xml to ms word and vice versa.
How to convert xml to ms excel and vice versa.
with reagrds
jyoti ranjan sahu
JMS Setup in JBOSS with mysql:
-------------------
1.Remove hsqldb-jdbc2-service.xml from $JBOSS_HOME/server/default/deploy/jms/ directory
2.Copy $JBOSS_HOME/docs/examples/jms/mysql-jdbc2-service.xml to $JBOSS_HOME/server/default/deploy/jms/
3.Modify name in mysql-jdbc2-service.xml with your name given in mysql-ds.xml (This is in deploy/jms directory)

Ex:in my application name of datasource is myatlasdbpool
<mbean code="org.jboss.mq.pm.jdbc2.PersistenceManager" name="jboss.mq:service=PersistenceManager">
<depends optional-attribute-name="ConnectionManager">jboss.jca:service=LocalTxCM,name=myatlasdbpool</depends>
</mbean>
4.Choose or enter new desitination name in jbossmq-destinations-service.xml (This is in deploy/jms directory)
<mbean code="org.jboss.mq.server.jmx.Queue" name="jboss.mq.destination:service=Queue,name=ex">
<depends optional-attribute-name="DestinationManager">jboss.mq:service=DestinationManager</depends>
</mbean>
5.Set RecursiveSearch as "True" in jboss-service.xml (This is in default/conf directory)
<attribute name="RecursiveSearch">True</attribute>
6.Make <create-table>true</create-table> in jbosscmp-jdbc.xml config files

<defaults>
<datasource>java:/myatlasdbpool</datasource>
<datasource-mapping>mySQL</datasource-mapping>
<create-table>false</create-table>
<remove-table>false</remove-table>
</defaults>

7.Example Entry in ejb-jar.xml
<message-driven>
<ejb-name>SendMessageMDB</ejb-name>
<ejb-class>com.beo.atlas.beans2.sendmail.SendMessageMDB</ejb-class>
<transaction-type>Container</transaction-type>
<message-driven-destination>
<destination-type>javax.jms.Queue</destination-type>
<subscription-durability>NonDurable</subscription-durability>
</message-driven-destination>
</message-driven>
8.Example Entry in jboss.xml, here the prefix "queue/" is a must, we will use this name from the caller
<message-driven>
<ejb-name>SendMessageMDB</ejb-name>
<destination-jndi-name>queue/ex</destination-jndi-name>
</message-driven>
9.Example calling code:

import javax.jms.*;

try {
javax.naming.Context ctx = new InitialContext();
QueueConnectionFactory qcf = (QueueConnectionFactory)ctx.lookup("ConnectionFactory");
QueueConnection qConn = qcf.createQueueConnection();
QueueSession qSession = qConn.createQueueSession(false,1);
Queue q = (Queue) ctx.lookup("queue/ex");
QueueSender sender = qSession.createSender(q);
TextMessage msg = qSession.createTextMessage();
msg.setText("Hello from Shivdeep!");
sender.send(msg);
}
catch(Exception e) {
e.printStackTrace();
}
10.Message Driven Bean: SendMessageMDB.java
import javax.jms.MessageListener;
import javax.ejb.MessageDrivenBean;
import javax.jms.Message;
import javax.ejb.MessageDrivenContext;
public class SendMessageMDB implements MessageDrivenBean, MessageListener {

private MessageDrivenContext ctx;

public void setMessageDrivenContext(MessageDrivenContext ctx) {
this.ctx = ctx;
}
public void ejbCreate() { }
public void ejbRemove() {
ctx = null;
}
public void onMessage(Message msg) {
//THIS CODE WILL BE EXECUTED WHEN THE MESSAGE IS SENT
}
}
20 years ago
Hi
norman richards,

Thanks for suggestion.
i am getting some Exception during deployment.
I am using mysql as database.

my files are



<!--jboss.xml-->

<message-driven>
<ejb-name>SendMessageMDB</ejb-name>
<destination-jndi-name>queue/ex</destination-jndi-name>
</message-driven>
<!--ejb-jar.xml-->
<message-driven>
<ejb-name>SendMessageMDB</ejb-name>
<ejb-class>com.beo.atlas.beans2.sendmail.SendMessageMDB</ejb-class>
<transaction-type>Container</transaction-type>
<message-driven-destination>
<destination-type>javax.jms.queue</destination-type>
<subscription-durability></subscription-durability>
</message-driven-destination>
</message-driven>

<!-- client code -->
javax.naming.Context ctx = new InitialContext();
QueueConnectionFactory qcf = (QueueConnectionFactory)ctx.lookup("ConnectionFactory");
//create a connection
QueueConnection qConn = qcf.createQueueConnection();
//creater session
QueueSession qSession = qConn.createQueueSession(false,1);
//create a sender
Queue q = ( Queue ) ctx.lookup("queue/ex");
QueueSender sender = qSession.createSender(q);
//after message received from the quue the message will be removed from message queue
//QueueSender receiver = qSession.createReceiver(q);
//delivery message
TextMessage msg = qSession.createTextMessage();
msg.setText("i will set mesage here ");
sender.send(msg);

<!-- mdb code-->
i am getting exception at time of exception
javax.jms.JMSException: Error creating the dlq connection: XAConnectionFactory not bound
at org.jboss.ejb.plugins.jms.DLQHandler.createService(DLQHandler.java:169)
at org.jboss.system.ServiceMBeanSupport.create(ServiceMBeanSupport.java:158)
at org.jboss.ejb.plugins.jms.JMSContainerInvoker.innerCreate(JMSContainerInvoker.java:458)
at org.jboss.ejb.plugins.jms.JMSContainerInvoker.startService(JMSContainerInvoker.java:674)
at org.jboss.system.ServiceMBeanSupport.start(ServiceMBeanSupport.java:192)
at org.jboss.ejb.MessageDrivenContainer.startService(MessageDrivenContainer.java:234)
at org.jboss.system.ServiceMBeanSupport.start(ServiceMBeanSupport.java:192)
at sun.reflect.GeneratedMethodAccessor41.invoke(Unknown Source)

with regards
jyoti
20 years ago
hi
all,
please tell me what are the files i have to configure for jms.
where will i mention jndi name of destination and connection factory.

with regards
jyoti
20 years ago
i am using struts1.1.
after session timeout it throws org.apache.jasper.JasperException.
main cause java.lang.IllegalStateexception.
try to solve through globalexception
but not execute
any solution.
20 years ago
can i use eclipse for j2EE development and how.
what is the use of ejb ref in web-xml file in tomcat?
20 years ago
hai
every body.
i code hallo world stateless(remote home,
remote reference,bean,two ar file).
please tell how to deploy halloworld
stateless bean in weblogic 6.1.
please write down the step.

jyoti


jyoti
20 years ago
Hi

all,

can any body give ejb20.jar

regards


jyoti
(djyoti@myway.com)
20 years ago
i unzipped jbosss 3x(no tomcat)

run run.bat

te=200301260037)] Started in 0m:31s:625ms
19:34:05,296 INFO [Log4jService$URLWatchTimerTask] Configuring from URL
ce:log4j.xml
19:35:05,273 INFO [Log4jService$URLWatchTimerTask] Configuring from URL
ce:log4j.xml
19:36:05,279 INFO [Log4jService$URLWatchTimerTask] Configuring from URL
ce:log4j.xml
19:37:05,285 INFO [Log4jService$URLWatchTimerTask] Configuring from URL
ce:log4j.xml
19:38:05,291 INFO [Log4jService$URLWatchTimerTask] Configuring from URL
ce:log4j.xml
19:39:05,308 INFO [Log4jService$URLWatchTimerTask] Configuring from URL
ce:log4j.xml
19:40:05,304 INFO [Log4jService$URLWatchTimerTask] Configuring from URL
ce:log4j.xml
19:41:05,310 INFO [Log4jService$URLWatchTimerTask] Configuring from URL
ce:log4j.xml
19:42:05,317 INFO [Log4jService$URLWatchTimerTask] Configuring from URL
ce:log4j.xml
19:43:05,323 INFO [Log4jService$URLWatchTimerTask] Configuring from URL
ce:log4j.xml
19:44:05,329 INFO [Log4jService$URLWatchTimerTask] Configuring from URL
ce:log4j.xml
19:45:05,335 INFO [Log4jService$URLWatchTimerTask] Configuring from URL
ce:log4j.xml
19:46:05,342 INFO [Log4jService$URLWatchTimerTask] Configuring from URL
ce:log4j.xml
19:47:05,348 INFO [Log4jService$URLWatchTimerTask] Configuring from URL


after giving url : http://localhost:8080


No Default Context
There is no default context registered with this server.
Contexts known to this server are:
WebApplicationContext[/jmx-console,file:/E:/jyoti/jboss software/jboss-3.0.6/jboss-3.0.6/server/default/deploy/jmx-console.war/]
WebApplicationContext[/invoker,file:/E:/jyoti/jboss software/jboss-3.0.6/jboss-3.0.6/server/default/deploy/http-invoker.sar/invoker.war/]
The links above may not work if a virtual host is configured


Does jboss require any class path setting like tomcat
20 years ago