This week's giveaway is in the JDBC forum.
We're giving away four copies of Java Database Connections & Transactions (e-book only) and have Marco Behler on-line!
See this thread for details.
Win a copy of Java Database Connections & Transactions (e-book only) this week in the JDBC forum!

Anu Gaur

Greenhorn
+ Follow
since Apr 14, 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 Anu Gaur

yes, at line 17, a is pointed to null.
7 months ago
Two objects should be created one of SmallClass and one of BigClass. Two references a and bigClass should be pointing to BigClass object and one reference smallClass should be pointing to SmallClass object. As soon as a is pointed to null, all other references are pointing to each-other somehow and not touched by external program thus valid for garbage collection.
7 months ago
Compile errors removed :
7 months ago
I got this question in one of internal papers of my organization. I dont know exact reference.

Also, as per my understanding, all objects created ll be valid for garbage collection at the end of program as main reference is made to point null and thus all objects created ll be lying on heap without any external reference.
7 months ago
What objects would be eligible for garbage collection?
8 months ago
Why we are moving towards functional programming in java 8. One benefit is reduced lines of code by using lambda expression. But i want to understand from conceptual perspective why functional programming in java?
8 months ago
Hi,

Snippet for PreferencesUtil.java method - setRmiPortPreference()


So this is basically getting the node from system where in it is failing because of lack of admin rights. Is it correct?

Also, i tried by comment out of this method call, but still it failed on next line where in it is trying to create the registry.

Please suggest.
6 years ago
Hello,

I do not have admin rights on my machine. I have written a simple java source code which trying to create a registry for RMI calls. But the code is breaking because of lack of admin rights. Is there any way through which i can create registry even if i have no admin rights?

Following is additional information :

Code snippet :

Exception : Jun 11, 2013 4:57:49 PM java.util.prefs.WindowsPreferences openKey
WARNING: Could not open windows registry node Software\JavaSoft\Prefs\com\nec\jp\dianascope\prefs at root 0x80000002. Windows RegOpenKey(...) returned error code 5.
Exception in thread "main" java.lang.SecurityException: Could not open windows registry node Software\JavaSoft\Prefs\com\nec\jp\dianascope\prefs at root 0x80000002: Access denied
at java.util.prefs.WindowsPreferences.openKey(WindowsPreferences.java:513)
at java.util.prefs.WindowsPreferences.openKey(WindowsPreferences.java:480)
at java.util.prefs.WindowsPreferences.openKey(WindowsPreferences.java:466)
at java.util.prefs.WindowsPreferences.putSpi(WindowsPreferences.java:612)
at java.util.prefs.AbstractPreferences.put(AbstractPreferences.java:251)
at com.nec.jp.dianascope.util.PreferencesUtil.setRmiPortPreference(PreferencesUtil.java:35)
at com.nec.jp.dianascope.CoreServer.main(CoreServer.java:5562)


6 years ago
I didn't mean how to set up SSL configuration for Tomcat.
My question is which approach is preferable.
For eg we have have Apache server and Tomcat container.
then httpd should be used or Tomcat should be configured for SSL.Hope i am able to clear my point.
9 years ago
Thanks for the reply....

but in the applications where we have some modules in java and some say in some other language(eg PHP) then we will have to use Apache as web server and tomcat as container.whats say?

and please reply to 2nd question as well in first post.
9 years ago
Apache is a web server and tomcat is a container which supports servlets,jsp etc. but also that tomcat can be used as standalone web-server than my question is why don't we use tomcat as standalone server in production environment?


i got the answer on this link --http://www.coderanch.com/t/81462/Tomcat/Standalone-Tomcat
As far as i understood the benefit is speed for static pages.

My next question is if we want to make some pages in our application to be secure means https pages, then how should it be done?

On the apache server level or on the application level through acegi etc?We want to make certain pages of our application to be https not all the pages.
9 years ago