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 202416 - Standalone instance not handled properly
Summary: Standalone instance not handled properly
Status: VERIFIED WORKSFORME
Alias: None
Product: serverplugins
Classification: Unclassified
Component: GlassFish (show other bugs)
Version: 7.1
Hardware: PC Windows XP
: P3 normal (vote)
Assignee: Vince Kraemer
URL:
Keywords:
Depends on:
Blocks:
 
Reported: 2011-09-21 12:13 UTC by Jiri Skrivanek
Modified: 2012-06-12 08:49 UTC (History)
0 users

See Also:
Issue Type: DEFECT
Exception Reporter:


Attachments

Note You need to log in before you can comment on or make changes to this bug.
Description Jiri Skrivanek 2011-09-21 12:13:51 UTC
If you register standalone instance of GlassFish server, its node in the IDE doesn't reflect state of server and browser with deployed application is opened at wrong port. To reproduce:

- create cluster
cd glassfish3/bin
asadmin start-domain
asadmin create-cluster c1
asadmin create-local-instance --cluster c1 li1c1
asadmin create-local-instance --cluster c1 li2c1
asadmin create-local-instance sli
asadmin start-cluster c1
asadmin start-local-instance sli
- start IDE
- register that GlassFish server in IDE and type sli in the Target field in Domain Location page of the Add Server Instance wizard
- create web application
- run this application
- browser is opened at address http://localhost:28080/WebApplication1 but it is wrong and http://localhost:28082/WebApplication1 works as found out in admin console. Also it is not possible to expand server node in Service view. It looks like the server instance is not running but it is as seen in admin console. Refresh on that node doesn't change it.

Product Version: NetBeans IDE Dev (Build 201109190600)
Java: 1.7.0; Java HotSpot(TM) Client VM 21.0-b17
System: Windows XP version 5.1 running on x86; Cp1250; en_US (nb)
Comment 1 Vince Kraemer 2011-09-21 19:28:00 UTC
i could not replicate the issue that you claim to suffer with the node.

I was able to replicate the problem with the url to Run an app deployed onto a stand-alone instance.

I have a code change that will address that.
Comment 2 Quality Engineering 2011-09-22 14:52:38 UTC
Integrated into 'main-golden'
Changeset: http://hg.netbeans.org/main-golden/rev/dc031bf29bea
User: vince kraemer <vkraemer@netbeans.org>
Log: #202416 : get correct url for accessing the http port of a stand-alone instance
Comment 3 Vince Kraemer 2011-09-23 01:45:00 UTC
Hmm.

 Just tried Win7 and could not replicate the problem...

Here is what I did.

D/L and install jdk 7 (c:\Program Files\Java\jdk1.7.0)
D/L and install NB (c:\Program Files\NetBeans Dev 201109180600 and c:\P F\glassfish-3.1.1)

Then I...

cd c:\P F\glassfish-3.1.1
bin\asadmin start-domain
bin\asadmin create-local-instance bump
bin\asadmin create-local-instance sli1
bin\asadmin start-instance sli1


I started NetBeans

I registered sli1

The node was decorated with the 'running' marker...

I created a web app that targeted the instance

I deployed it.

I expanded the node that represents sli1 in the services explorer and was able to see that the web app was deployed.

Can you provide a bit more details on how you installed the various bits and the location of the domain that you started?

My guess is you created the instances as part of  domain1 in c:\Program Files\glassfish-3.1.1\domains...

That usually is not the domain that is registered 'automagically', since normal users aren't allowed to write into subdirectories of c:\Program Files.
Comment 4 Jiri Skrivanek 2011-09-27 13:25:05 UTC
I found out that it doesn't work only if I register also cluster instance. If only standalone instance is registered, it works. Feel free to close this bug if cluster and standalone should not work together. So my steps:

...
asadmin start-cluster c1
asadmin start-local-instance sli

- register cluster c1 in IDE
- register sli in IDE
- now only cluster instance is shown as running but standalone seems to be stopped
Comment 5 Vince Kraemer 2012-06-05 07:16:20 UTC
I came back to this and it still worksforme. 

please reopen if you can still replicate the issue.
Comment 6 Jiri Skrivanek 2012-06-12 08:49:12 UTC
Yes, now in NetBeans 7.2 it works for me.