S Subramonyan

Ranch Hand
+ Follow
since Aug 26, 2004
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 S Subramonyan

Hi All,

I am new to JAAS. But I have been working on Servlets & JSP on Tomcat for a while.

My client needs to have the ability to login a user who is already logged on to Notes automatically to a JAAS configuration. So that someother program in the company can access the existence of that username and consider that this request is already authenticated.

This all should happen in the background. My client does not want to interrupt the users with login boxes.

I would like to know how can I do all this stuff?

I looked in Sun's website for JAAS api. It seems like its bundled with JWSDP. But it needs a web container. I cannot change my current Tomcat 5.0 to Tomcat 5.0 for JWSDP.

Any help is appreciated.

Thanks
Subramonyan.
16 years ago
Thanks Kumar.

Ya, I realized, I don't even need Web Services for this. I was totally illiterate about URLConnection class in Java SE.

I used URLConnection and its working perfect as I wanted.

Thanks for your help!
17 years ago
Hi,

I have a requirement. I am lookign for a way to sort this out.

I have a servlet, that would get input from the user. For some organization specific reasons, my company does not want to call a servlet to process the user input. We'll store the user data to a text file/xml file.

I need a way to process this data by a timed program(like a timer). It should pick up this text data and then give this data to a URL like("http://host/dataProcessor.jsp"). And my program should be able to get the data thats returned from this URL.

Is this soemthing that only a web service can do or is there any other way to do it or if its a web service thing, how do I do it.

I appreciate you help.

Thanks
17 years ago
Hi Janna Voss

Don't worry. Exact same thing happened to me too.. I asked them if I can see the score from the computer. They let me see my score.

Don't worry at all.. You would get the certificate form Sun soon

Good Luck!
Hi All,

We are planning to develop a system that uses Lawson ERP system as the back end. The system is to be developed in J2EE. Websphere seems to be the prospective application and web server we would be using.

Is it possible for EJBs to access ERP backend? Have anyone been worked in a similar architecture.

Please help.

Thanks
Hi,

encodeRedirectUrl(string url) is used when you don't have cookies supported in the destination browser. It adds the jsessionid as part of the url. Its called Url Re-writing.

When using sendRedirect using the normal url in browsers that don't support cookies, the browser client will not participate in the current session. To enable this, you have to explicitly make the client a part of the current session.
Eg:

String url = http://mywebsite/accountinfo

sendRedirect(url) -----------> not Wrong, but will not give expected results.

sendRedirect(encodeRedirectUrl(url)) ---------------> Will give expected results.

Hope this helps.
Hi,

How are you all?

I need some help desperately. I have to demonstrate the transaction mechanism to my employer. I don't have much EJB experience. Someone please help me out here. Can anyone give me a simple bean project to demonstrate transaction mechanism? Anything particular to Weblogic is greatly appreciated. Remember your first days with EJB and please help me out. Please see this link too. https://coderanch.com/t/314961/EJB-JEE/java/EJB-Transactions-inWeblogic

Thanks a lot! in advance.
In fact what I meant was, some sample code to demonstrate the transaction mechanism. From the theory that I read, I understand, there are both Container-managed and Bean Managed. Bean Managed you write explicit code, right?

If some one please help me out here, that would be just great!!!
Hi,

I just started learning EJB. But my employer said, I should go straight to Transactions so that he could get me a project soon. So what I did was, I created some Sessions Beans, Entity Beans etc first. Now I want to do a simple EJB project that makes use of Transactions. Could anyone please give me some sample code / ideas so that I can build a simple transaction-based EJBProject to start learning? In fact I tried on my own, but it failed. Exceptions are overflowing!!! :-)

I use Weblogic. Anything particular to Weblogic is greatly appreciated.

Thank you very much.
Hi,

I have a technical interview today(J2EE-Servlets, JSP, Struts, EJB, Ant). I don't have struts exp. Anyone of you know has any interview questions related to Struts. What could be asked? I was wondering if you guys have any advices. This is my first Job interview!!!

Thanks in advance.
17 years ago
Hi,

I was writing my first bean. I have the following java files on "examples" folder.


1. HelloWorld.java
2. HelloWorldBean.java
3. HelloWorldHome.java
4. HelloWorldLocal.java
5. HelloWorldLocalHome.java

Out of this, 2 home interfaces, local(no. 5) and Home(no.3) are not compiling. It says correspoding interfaces as the return type in the create method is not found (cannot resolve symbol).

Can anyone help me here please?

Thanks in avdvance.
My fellow Ranchers,

How are you all?

I have a big problem that I am facing now. I took my SCWCD last week. Now I am going to study EJB.

But!

I have *zero* experience in EJB/JavaBeans.

I took this book "Developing JavaBeans" (O'reilly) and read 2-3 chapters and understood this is *NOT* what I am looking for. (I got this idea that JavaBeans is different and Enterprise JavaBeans is different, correct me if I am wrong)

I am looking forward to study *EJB*.

Where can I start studying. I am *NOT* looking forward to taking certification right now. I want to study technology first. I need to lay a good foundation! Please help me.

Please give me the names of any books that would do justise to a starter like me.

All your responses are really really appreciated.
I think changes made to the servlet will reflect on the client once you hit the refressh button. But before that check tomcat command prompt to see if "WebappClassLoader ..... updated ..was time1 : now: time2". After you see this in the tomcat window, you can successfully get the modified servlet in the browser. It might take a minute or two.
Pallavi,

You just need to give the servlet class name if its not packaged.

For eg: you have a class Serv1 in WEB-INF/classes, Serv2 in WEB-INF/classes/com/SCWCD

<servlet>
<servlet-name>name1</servlet-name>
<servlet-class>Serv1</servlet-class>
</servlet>


<servlet>
<servlet-name>name2</servlet-name>
<servlet-class>com.SCWCD.Serv2</servlet-class>
</servlet>

And don't forget to map the url pattern to the servlet name!!!
Yes you can, for eg:

You have a webapp named test. You have a servlet class named MyServlet.class

You can specify any name for it in the dd element <servlet-name>, and you can map it to any url pattern you want.

eg: in web.xml,

<web-app>
......
..
<servlet>
<servlet-name>OhMy</servlet-name>
<servlet-class>MyServlet</servlet-class>
</servlet>
..
..

<servlet-mapping>
<servlet-name>OhMy</servlet-name>
<url-pattern>/OhMy</url-pattern>
</servlet-mapping>

<servlet-mapping>
<servlet-name>OhMy</servlet-name>
<url-pattern>/ohh.*</url-pattern>
</servlet-mapping>

<servlet-mapping>
<servlet-name>OhMy</servlet-name>
<url-pattern>/foo.baz</url-pattern>
</servlet-mapping>

..
</web-app>

Hope this helps!