Vish Joshi

Greenhorn
+ Follow
since Dec 22, 2010
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 Vish Joshi


I am making a simple JSF application with no special components-

my jsf page is-
HelloWorld.jsp


web.xml


When is run HelloWorld.jsp the server shows the following error-


I have reduced this application to almost zero to track the error so I am not using any faces-config.xml and backing beans!!
I think the error is in jars what i suppose?
currently i am using three jars jsf-api,jsf-impl and jstl 1.2!
12 years ago
JSF
I have resolved the problem..it was commons-logging.jar's version problem!
12 years ago
Hi,
here is the spring-config.xml i am using-
12 years ago
weblogic-ejb-jar.xml is used in EJB 2.0 that i know ! but EJB 3.0 is deployment descriptors light (what i hav read from web sites)....in JBOSS and other servers we have a defined format for default jndi names but i am unable to figure it out in weblogic 10.3???


Bean
package Bean;
import interfaces.EjbBusinessInterface;

import javax.ejb.Stateless;
import javax.ejb.Remote;

@Stateless(mappedName="TestSessionBean")

public class CalculatorBean implements EjbBusinessInterface{
public void add(int x,int y){
System.out.println(x+y) ;
}
}


Business Interafce
package interfaces;

import javax.ejb.Remote;

@Remote
public interface EjbBusinessInterface {
public void add(int x,int y);

}

Client
package Client;
import java.util.Hashtable;
import javax.naming.Context;
import javax.naming.InitialContext;

import Bean.CalculatorBean;

public class TestSessionClient {

private static CalculatorBean helloWorld;
public static void main(String[] args)

{
try

{
Hashtable<String, String> env = new Hashtable<String, String>();
env.put(Context.INITIAL_CONTEXT_FACTORY,"weblogic.jndi.WLInitialContextFactory");

env.put(Context.PROVIDER_URL,"t3://192.168.9.168:7001");
Context ctx = new InitialContext(env);
System.out.println("Initial Context created");
helloWorld = (CalculatorBean) ctx.lookup("TestSessionBean");
System.out.println("lookup successful");
System.out.println("Calling EJB method . . .");
helloWorld.add(2,4);
System.out.println("Output will be in Managed server console");
}

catch (Exception e)
{
e.printStackTrace();
}

}

}


as i am writing ejb3.0 we do not need the deployment descriptors(ejb-jar.xml,weblogic-ejb-jar.xmal etc.).
in the above files how should i give the jndi name and what is the format of default jndi name for weblogic 10.3?
i am using weblogic 10.3 as the application server!! i went through the jndi tree in weblogic...if i use the name mentioned as 'binding name' in weblogic jndi tree(Environments->Servers->Admin Server->view jndi tree) it gives 'ClassNotFound Exception'..... am i right in locating the default jndi name in the place i mentioned??....if not what is the format of default jndi name in weblogic 10.3?
can any one tell me where should i specify the JNDI name in ejb3 or where can i get the default JNDI name?

Many thanks in advance!
<project default="dir" >
<property name="build" value="Build"/>
<target name="dir" >

<javac srcdir="../Build1" destdir="." includes="hello.java"/>
<java classname="hello">

<classpath>
<pathelement path="Build1/convergys"/>
</classpath>

</java>

</target>
</project>

Folder Structure is like this:-
Build
->com
->hello.class
->build2.xml



13 years ago