This Bugzilla instance is a read-only archive of historic NetBeans bug reports. To report a bug in NetBeans please follow the project's instructions for reporting issues.

Bug 93069 - wrong default location
Summary: wrong default location
Status: VERIFIED FIXED
Alias: None
Product: serverplugins
Classification: Unclassified
Component: Sun Appserver 9 (show other bugs)
Version: 6.x
Hardware: Sun Solaris
: P2 blocker (vote)
Assignee: Nitya Doraisamy
URL:
Keywords:
: 89528 (view as bug list)
Depends on:
Blocks:
 
Reported: 2007-01-23 20:30 UTC by Vince Kraemer
Modified: 2007-02-07 19:04 UTC (History)
3 users (show)

See Also:
Issue Type: DEFECT
Exception Reporter:


Attachments
patch file (12.83 KB, application/octet-stream)
2007-02-07 15:29 UTC, Michal Mocnak
Details
patch file (14.44 KB, application/octet-stream)
2007-02-07 19:03 UTC, Michal Mocnak
Details

Note You need to log in before you can comment on or make changes to this bug.
Description Vince Kraemer 2007-01-23 20:30:52 UTC
The algorithm for determining where the server bits might be ingores the
com.sun.aas.installRoot property.

it should not.

this issue is related to issue 93053
Comment 1 Vince Kraemer 2007-01-23 20:33:32 UTC
if the install root isn't writable, we probably want the user to create a
personal domain... make that the default choice.
Comment 2 Vince Kraemer 2007-01-23 20:37:43 UTC
Checking in appsrv/src/org/netbeans/modules/j2ee/sun/api/ServerLocationManager.java;
/cvs/serverplugins/sun/appsrv/src/org/netbeans/modules/j2ee/sun/api/ServerLocationManager.java,v
 <--  ServerLocationManager.java
new revision: 1.7; previous revision: 1.6
done
Checking in
appsrv81/src/org/netbeans/modules/j2ee/sun/ide/j2ee/ui/AddInstanceVisualPlatformPanel.java;
/cvs/serverplugins/sun/appsrv81/src/org/netbeans/modules/j2ee/sun/ide/j2ee/ui/AddInstanceVisualPlatformPanel.java,v
 <--  AddInstanceVisualPlatformPanel.java
new revision: 1.9; previous revision: 1.8
Comment 4 Petr Blaha 2007-01-26 16:57:05 UTC
Verified in trunk build 070126.
Comment 5 Petr Blaha 2007-01-26 17:03:06 UTC
This is usability issue for users that use the server that is installed with
root privileges. This is important for NB+AS bundle on Unix systems where the
bundle is installed as root
Comment 6 Vince Kraemer 2007-01-26 17:58:04 UTC
this is not ready for integration... needs reviews, etc.

I will put the '5.5.1_candidate' flag in the whiteboard once the fix is ready to
integrate...
Comment 7 Vince Kraemer 2007-01-29 22:54:44 UTC
better fix...

don't change the ServerLocationManager.java.

change AddDomainPlatformPanel.java

diffs:
http://www.netbeans.org/source/browse/serverplugins/sun/appsrv81/src/org/netbeans/modules/j2ee/sun/ide/j2ee/ui/AddDomainPlatformPanel.java?r1=1.10&r2=1.11
Comment 9 Vince Kraemer 2007-01-30 00:21:23 UTC
needs to be reverified
Comment 10 Vince Kraemer 2007-01-30 00:21:56 UTC
new fix in the trunk
Comment 11 Petr Blaha 2007-01-30 13:50:41 UTC
I tested this in the latest build and works fine. Marking as verified. The fix
could be merged in release551 branch.
Comment 12 _ pcw 2007-01-30 16:28:37 UTC
latest set of diffs reviewed by me, looks great.
Comment 13 Vince Kraemer 2007-01-31 20:07:02 UTC
Checking in AddInstanceVisualPlatformPanel.java;
/cvs/serverplugins/sun/appsrv81/src/org/netbeans/modules/j2ee/sun/ide/j2ee/ui/AddInstanceVisualPlatformPanel.java,v
 <--  AddInstanceVisualPlatformPanel.java
new revision: 1.1.2.3.2.2.24.1; previous revision: 1.1.2.3.2.2
done
Checking in AddDomainPlatformPanel.java;
/cvs/serverplugins/sun/appsrv81/src/org/netbeans/modules/j2ee/sun/ide/j2ee/ui/AddDomainPlatformPanel.java,v
 <--  AddDomainPlatformPanel.java
new revision: 1.1.2.3.2.5.18.2; previous revision: 1.1.2.3.2.5.18.1
Comment 14 Vince Kraemer 2007-02-01 05:26:40 UTC
*** Issue 89528 has been marked as a duplicate of this issue. ***
Comment 15 Michal Mocnak 2007-02-07 15:28:42 UTC
Based on this issue i have created a patch which creates a personal domain in
the user's home dir when he uses sjsas + nb bundle which is installed as root. I
attach the patch.
Comment 16 Michal Mocnak 2007-02-07 15:29:13 UTC
Created attachment 38180 [details]
patch file
Comment 17 Antonin Nebuzelsky 2007-02-07 17:07:21 UTC
I did not read the patch thoroughly, but I think I noticed that you are using
fixed port numbers there. This is wrong. What if the installation is multi-user
environment on a Sun Ray server?

Not sure if we want such a complex change in 5.5.1. Should be very carefully
reviewed and tested.
Comment 18 Petr Blaha 2007-02-07 17:16:47 UTC
I don't assume that this change should be in NB 5.5.1 as well. I guess that we
can check ports before domain is created.
Comment 19 Antonin Nebuzelsky 2007-02-07 18:15:45 UTC
> check ports before domain is created

Could we actually recheck ports every time we are starting the domain and change
them for the domain if they are occupied by someone else at the particular moment?

Still thinking about the SunRay scenario - several students in a class starting
their IDEs one after another and creating the domain at random moments. If we
only check the ports before domain creation, there could still be two IDEs
trying to use the same ports for their domains.
Comment 20 Michal Mocnak 2007-02-07 18:38:20 UTC
Changing ports every time we are starting domain is problem. All ports are
stored in the xml config files in domain. We would have to parse and serialize them.

What we can do is to check ports before domain is created. I will attach updated
patch in a few minutes.
Comment 21 Michal Mocnak 2007-02-07 19:03:28 UTC
Created attachment 38190 [details]
patch file
Comment 22 Vince Kraemer 2007-02-07 19:04:32 UTC
Please move the patch and discussion over to issue 93053

I left that issue open for changes similar to those that you have proposed here...

I am concerned that somebody will not be able to follow the thread and commit
code  incorrrectly...