Win a copy of Terraform in Action this week in the Cloud forum!

Rahul Shivsharan

Ranch Hand
+ Follow
since Jun 17, 2009
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 Rahul Shivsharan

Hi,

There are new bunch of JVM languages getting importance in the market,

so just wanted to know,

to learn Jython, whether i need to know Python,
to learn JRuby, whether i need to know Ruby.

i'm working on a JSF project,
I am working on a functionality where on click of a button in managed-bean i have to lookup a velocity template "SDVL_TEMPLATE.vm" and put the key values,
the .vm file resides in "WEB-INF/template/" path

in web.xml i have done the following setting,



velocity.properties resides in WEB-INF, it has following entries,



and in my managed-bean, in the button invokation method i have done this,


But still in server console i get ResourseNotFound Exception, for SDVL_TEMPLATE.vm file.
Please can any body tell me where i am going wrong
9 years ago
JSF
Hi,
I read technical books because i like it,
mostly Java technologies, UI related i.e HTML, Javascript , jQuery.
I read books at job too when i am not having any work, in PDF

Now when i read technical books or see technical blogs, my office colleagues taunt me that,
i should not read every thing, only read when that related kind of work comes i.e if i get work on Spring AOP than and only than i shoud read about AOP.
They say that its dumb if you read stuffs which has nothing to do with your work.

Recently i was reading on EJB Interceptors,
My colleagues said if i don't have any work on EJB, than why to read it.

Now my thougths are
If i read before and i am well prepared on new technologies,
than its good for me, thats what i think,
Waiting for your suggestions
9 years ago
hi i am creating an web application using Maven 2

this is my folder structure

sampleWebProj
|
----main
|
-----java
|
----web

and below is my pom.xml


i am using glassfish as an appserver,
now i want to include glassfish-web.xml file in WEB-INF folder, how should i do it.

i tried using

<containerConfigXML>glassfish-web.xml</containerConfigXML>

but it doesnt includes

my question is as per the above folder structure , where should i put the glassfish-web.xml file ,
and what should i enter in pom.xml file so that the glassfish-web.xml file get copied in WEB-INF folder

10 years ago
Hi,
I have an total IT experience of 4 years completely in Java/JEE, development.

Prevoisly i have worked on web application development in Java, Servlet JSP, Struts and JSF.

Also having a good knowledge of EJB 3.0 and Spring , have practised in it in a demo projects.

I have also worked on ORM like Hibernate. In this i have an experience of 1 year.

I have also worked on Ajax,
Also used jQuery in Javascript development,
Used jQueryUI pluggin too.

Now, my Question is ,
My company is going to shift me to some other project which will be completely on Android .

So how does this will effect my carrer .

I was looking myself to be in completely in Java/JEE stack. I thought that gromming my career in this will help me advance technically and Financialy.
I mean, Java/JEE is everywhere, be it Banking, Finance, Healthcare or tourism etc....

If at all looking at my past experience if i shift to android developement , how will this effect me.
Android has just now started, where will i stand in future if using Android development or any Tablet or Iphone development.


Please give me a suggestion, should i go in android development of should i continue working in Java/JEE development.

What will be the feature of Android as well as iPhone and tablet developement


10 years ago
SPring creates proxy class and that proxy class has the additional methods of advice

So here according to the above example,
the proxy class will have methods of
takeSeats()
turnOffCellPhones()
applause()
perform()
demandRefund(),

Am i right ?


One more Question,

In the above example I typecasted Performer with the proxy object of Singer and i invoked perform method throught the reference of Performer.
What if i want to invoke method which is present only in Singer class, let say method xyz() in class Singer ,

than invoking xyz() using performed will give compilation error right ?

10 years ago
I am practising out the AOP,
this is the code as follows,

this is Performer.java,


this is Singer.java,


this is Audience.java,


this is AudienceAround.java,


this is beans-cfg-3_0.xml,


and the class having the main method MainPractise35.java,



My question is, in the class MainPractise35.java, if i typecast the Singer class , i get error PROBLEM java.lang.ClassCastException: $Proxy7 cannot be cast to com.aoptwo.Singer

but if i typecast the same using Performer class it runs fine ,
this is the changed code,


So can you please explain why my previous code was not running, thought i am type casting Singer why it gives an Proxy error
10 years ago
so mark should i start reading "Spring 3.0 In Action" ?
10 years ago
i got it,
one more configuration was remaining in the xml,
my edited xml file



A proxy creation is also required,

now the above example will run fine with Spring 2.0 config

10 years ago
Guy's please help me out on this,

i know this question is discussed in this forum,
but that didn't helped me out

Please reply back
10 years ago
Performer.java,



Audience.java



AudienceAdvice.java



bean-cfg-Two.xml


MainPractise24.java



What i am expecting is,
whenever i call perform() method of Performer class, the takeSeats() and turnOffCellPhones() method of Audience class should be called first,
and after execution of method perform(), applause() method of Audience class should be called

but no AOP is happening, the perform method is getting called straight,


even if i changed the eml file to

10 years ago
forget the commented code,

i repeat my question

the object of Manager is created outside the Spring container,

but still Spring Container should be able to inject the properties in object Manager as it is anotated @Configurable,

but the properties are not getting injected ?
why ?

do i am missing any xml schema definition or a jar,

i have inccluded all spring 3.0 jars plus
aopalliance-1.0.jar
aspectjrt-1.0.5.jar
aspectjweaver-1.5.2.jar


so why nullpointer exception
10 years ago
My bean-cfg-Two.xml,


My Manager.java which is annotated by @Configurable


My MainPractise19.java having the main method,


in the above code i have created Manager object outside the spring container,
but what i expected was the properties of the Manager object will be injected by the spring container,

but still i am getting a null pointer exception in Managers income() method ant emp.income() line, why ?

Whether spring has injected the properties ?

I am missing some thing ?
10 years ago