[GLASSFISH-19079] Decouple admin ReST resources from underlying protocol layer Created: 15/Sep/12  Updated: 16/Sep/12  Resolved: 16/Sep/12

Status: Resolved
Project: glassfish
Component/s: rest-interface
Affects Version/s: 4.0_b53
Fix Version/s: 4.0_b55

Type: Improvement Priority: Major
Reporter: Sanjeeb Sahoo Assignee: Sanjeeb Sahoo
Resolution: Fixed Votes: 0
Labels: None
Remaining Estimate: Not Specified
Time Spent: Not Specified
Original Estimate: Not Specified


 Description   

Currently there are some references to underlying protocol layer from ReST resources such as: CommandResource, CompositeResource and SessionResource. e.g., CommandResource.java is making deep assumptions about Grizzly being the network manager:

+ @Inject
+ protected Ref<Request> requestRef;

This is done to retrieve the current Subject which is a standard interface. So, if we bind the Subject as a request scoped object into Grizzly resource configuration, we could achieve desired decoupling.



 Comments   
Comment by Sanjeeb Sahoo [ 16/Sep/12 ]

This issue has been fixed in following two svn commits:

Revisions: #55983
-----------------
This involves abstracting out the Jersey container aspect by introducing an object called JerseyContainer.

We also allow subclass to provide SubjectFactoryBinder which can retrieve the subject from appropriate
protocol specific object.

Ran QuickLook as well as some closed source admin tests as per recommendation of Martin Mares.

Code reviewed by Martin Mares.

Thanks to Jakub for providing the patch to inject Subject in CommandResource.

Revisions: #55987
-----------------

This changeset involves abstracting out the ReST resource provider aspect by
introducing an object called RestResourceProvider. Code out of RestCommandAdapter,
RestManagementAdapter and RestMonitoringAdapter have been moved to implementations of
RestResourceProviders called RestCommandResourceProvider, RestManagementResourceProvider
and RestMonitoringResourceProvider respectively.

RestAdapter uses a bridge pattern where RestResourceProvider is the delegate.

This allows us to evolve RestAdapter independently from RestResourceProvider.

Tests run: QuickLook and closed source tests that exercise ReST interfaces.

Because of a bug in git/svn bridge, my comment didn't appear properly in svn.





[GLASSFISH-19074] Problem related to admin console happened on server.log after loading admin console Created: 14/Sep/12  Updated: 14/Sep/12  Resolved: 14/Sep/12

Status: Resolved
Project: glassfish
Component/s: admin_gui
Affects Version/s: None
Fix Version/s: 4.0_b55

Type: Bug Priority: Major
Reporter: TangYong Assignee: Anissa Lam
Resolution: Fixed Votes: 0
Labels: None
Remaining Estimate: Not Specified
Time Spent: Not Specified
Original Estimate: Not Specified
Environment:

1 Windows XP
2 GF trunk 2012/09/14



 Description   

1 updating to gf trunk 2012/09/14 and building gf

2 starting domain and loading admin console

3 after loading admin console, on server.log, the following exception happened, although admin console can be accessed normally. (can not find commons-io-1.3.1.jar)

[#|2012-09-14T12:04:14.875+0900|WARNING|44.0|org.apache.jasper.runtime.TldScanner|_ThreadID=21;_ThreadName=Thread-22;|PWC6351: In TLD scanning, the supplied resource file:/E:/gf0914/glassfish3/glassfish/lib/install/applications/__admingui/WEB-INF/extra/commons-io-1.3.1.jar does not exist
java.io.FileNotFoundException: E:\gf0914\glassfish3\glassfish\lib\install\applications__admingui\WEB-INF\extra\commons-io-1.3.1.jar (指定されたファイルが見つかりません。)
at java.util.zip.ZipFile.open(Native Method)
at java.util.zip.ZipFile.<init>(ZipFile.java:127)
at java.util.jar.JarFile.<init>(JarFile.java:135)
at java.util.jar.JarFile.<init>(JarFile.java:72)
at sun.net.www.protocol.jar.URLJarFile.<init>(URLJarFile.java:72)
at sun.net.www.protocol.jar.URLJarFile.getJarFile(URLJarFile.java:48)
at sun.net.www.protocol.jar.JarFileFactory.get(JarFileFactory.java:80)
at sun.net.www.protocol.jar.JarURLConnection.connect(JarURLConnection.java:104)
at sun.net.www.protocol.jar.JarURLConnection.getJarFile(JarURLConnection.java:71)
at org.apache.jasper.runtime.TldScanner.scanJar(TldScanner.java:442)
at org.apache.jasper.runtime.TldScanner.scanJars(TldScanner.java:694)
at org.apache.jasper.runtime.TldScanner.scanTlds(TldScanner.java:350)
at org.apache.jasper.runtime.TldScanner.onStartup(TldScanner.java:239)
at org.apache.catalina.core.StandardContext.callServletContainerInitializers(StandardContext.java:5594)
at com.sun.enterprise.web.WebModule.callServletContainerInitializers(WebModule.java:595)
at org.apache.catalina.core.StandardContext.start(StandardContext.java:5491)
at com.sun.enterprise.web.WebModule.start(WebModule.java:512)
at org.apache.catalina.core.ContainerBase.addChildInternal(ContainerBase.java:932)
at org.apache.catalina.core.ContainerBase.addChild(ContainerBase.java:916)
at org.apache.catalina.core.StandardHost.addChild(StandardHost.java:687)
at com.sun.enterprise.web.WebContainer.loadWebModule(WebContainer.java:2289)
at com.sun.enterprise.web.WebContainer.loadWebModule(WebContainer.java:1935)
at com.sun.enterprise.web.WebApplication.start(WebApplication.java:109)
at org.glassfish.internal.data.EngineRef.start(EngineRef.java:122)
at org.glassfish.internal.data.ModuleInfo.start(ModuleInfo.java:278)
at org.glassfish.internal.data.ApplicationInfo.start(ApplicationInfo.java:299)
at com.sun.enterprise.v3.server.ApplicationLifecycle.deploy(ApplicationLifecycle.java:497)
at com.sun.enterprise.v3.server.ApplicationLoaderService.processApplication(ApplicationLoaderService.java:398)
at com.sun.enterprise.v3.admin.adapter.InstallerThread.load(InstallerThread.java:201)
at com.sun.enterprise.v3.admin.adapter.InstallerThread.run(InstallerThread.java:98)

#]


 Comments   
Comment by TangYong [ 14/Sep/12 ]

Fistly, please confirm whether the problem can be reproduced or not?

Secondly, on my env, I have found that on glassfish3\glassfish\lib\install\applications__admingui\WEB-INF\extra,
commons-io-1.1.jar exist and commons-io-1.3.1.jar does not exist. In addition, on the newest gf souce,

on main\appserver\admingui\war\src\main\webapp\WEB-INF\sun-web.xml, the following code uses commons-io-1.3.1.jar

<class-loader delegate="true" extra-class-path="WEB-INF/extra/webui-jsf-suntheme-4.0.2.10.jar:WEB-INF/extra/dojo-ajax-nodemo-0.4.1.jar:WEB-INF/extra/webui-jsf-4.0.2.10.jar:WEB-INF/extra/commons-fileupload-1.1.1.jar:WEB-INF/extra/commons-io-1.3.1.jar:WEB-INF/extra/json-1.0.jar:WEB-INF/extra/prototype-1.5.0.jar" />

So, I think that some place uses commons-io-1.1.jar and other place uses commons-io-1.3.1.jar so that there is some inconsistence on admin gui distribution.

Comment by TangYong [ 14/Sep/12 ]

I have found the reason of problem:

on main\nucleus\pom.xml, the following dependency has been commented out,

<dependency>
<groupId>commons-io</groupId>
<artifactId>commons-io</artifactId>
<version>1.3.1</version>
</dependency>

I did not know the reason of commenting out, however, once uncommenting the above code, the problem will be fixed.

So, please confirm the nucleus\pom.xml.

Comment by Romain Grécourt [ 14/Sep/12 ]
Project:    glassfish
Repository: svn
Revision:   55971
Author:     romain_grecourt
Date:       2012-09-14 14:47:59 UTC
Link:       

Log Message:
------------
fix for http://java.net/jira/browse/GLASSFISH-19074. also removing some maven API dependencies...


Revisions:
----------
55971


Modified Paths:
---------------
trunk/main/nucleus/pom.xml


Diffs:
------
Index: trunk/main/nucleus/pom.xml
===================================================================
--- trunk/main/nucleus/pom.xml	(revision 55970)
+++ trunk/main/nucleus/pom.xml	(revision 55971)
@@ -1039,43 +1039,12 @@
                 <artifactId>jmockit</artifactId>
                 <version>0.999.15</version>
             </dependency>
-<!--            <dependency>
-                <groupId>org.apache.maven</groupId>
-                <artifactId>maven-core</artifactId>
-                <version>2.0.7</version>
-            </dependency>
             <dependency>
                 <groupId>commons-io</groupId>
                 <artifactId>commons-io</artifactId>
                 <version>1.3.1</version>
             </dependency>
             <dependency>
-                <groupId>org.apache.maven</groupId>
-                <artifactId>maven-plugin-api</artifactId>
-                <version>2.0</version>
-            </dependency>
-            <dependency>
-                <groupId>org.apache.maven.scm</groupId>
-                <artifactId>maven-scm-api</artifactId>
-                <version>1.0-beta-3</version>
-            </dependency>
-            <dependency>
-                <groupId>org.apache.maven.plugins</groupId>
-                <artifactId>maven-scm-plugin</artifactId>
-                <version>1.0-beta-3</version>
-            </dependency>
-            <dependency>
-                <groupId>org.apache.maven</groupId>
-                <artifactId>maven-project</artifactId>
-                <version>2.0</version>
-            </dependency>
-            <dependency>
-                <groupId>org.apache.maven</groupId>
-                <artifactId>maven-archiver</artifactId>
-                <version>2.0</version>
-            </dependency>-->
-            
-            <dependency>
                 <groupId>org.apache.ant</groupId>
                 <artifactId>ant</artifactId>
                 <version>1.8.2</version>




Please re-open as needed if you still see this issue.





[GLASSFISH-18955] embedded web container does not shutdown properly Created: 27/Jul/12  Updated: 17/Sep/12  Resolved: 17/Sep/12

Status: Resolved
Project: glassfish
Component/s: web_container
Affects Version/s: 4.0
Fix Version/s: 4.0_b55

Type: Bug Priority: Critical
Reporter: Sanjeeb Sahoo Assignee: Amy Roh
Resolution: Fixed Votes: 0
Labels: None
Remaining Estimate: Not Specified
Time Spent: Not Specified
Original Estimate: Not Specified


 Description   

During embedded testing I noticed that embedded web container is not shutting down properly. Basically WebContainer.preDestroy() needs to undo everything that happens in WebContainer.postConstruct().

If you want to experiment, the quickest way to try is to do the following:

Copy a web app to domain1/autodeploy/

java -DGlassFish_Interactive=true -jar glassfish.jar

You will see a prompt after sometime. Type:
start

It will start GlassFish and deploy the web app. Now you can access the web app.
Now type:
stop
It will stop GlassFish.
Then start again.
You will see an NPE like this:

[#|2012-07-27T23:35:25.988+0530|WARNING|44.0|javax.enterprise.system.container.web.com.sun.enterprise.web.connector|_ThreadID=10;_ThreadName=main;|Error registering contexts
java.lang.NullPointerException
at com.sun.enterprise.web.connector.MapperListener.init(MapperListener.java:193)
at com.sun.enterprise.web.connector.coyote.PECoyoteConnector.start(PECoyoteConnector.java:549)
at org.apache.catalina.startup.Embedded.start(Embedded.java:932)
at com.sun.enterprise.web.WebContainer.postConstruct(WebContainer.java:604)
at com.sun.hk2.component.AbstractCreatorImpl.inject(AbstractCreatorImpl.java:132)
at com.sun.hk2.component.ConstructorCreator.initialize(ConstructorCreator.java:117)
at com.sun.hk2.component.AbstractCreatorImpl.get(AbstractCreatorImpl.java:84)
at com.sun.hk2.component.SingletonInhabitant.get(SingletonInhabitant.java:67)
at com.sun.hk2.component.EventPublishingInhabitant.get(EventPublishingInhabitant.java:141)
at com.sun.hk2.component.AbstractInhabitantImpl.get(AbstractInhabitantImpl.java:135)
at org.glassfish.internal.data.EngineInfo.getContainer(EngineInfo.java:93)
at com.sun.enterprise.v3.server.ApplicationLifecycle.startContainers(ApplicationLifecycle.java:997)
at com.sun.enterprise.v3.server.ApplicationLifecycle.setupContainerInfos(ApplicationLifecycle.java:707)
at com.sun.enterprise.v3.server.ApplicationLifecycle.deploy(ApplicationLifecycle.java:372)
at com.sun.enterprise.v3.server.ApplicationLoaderService.processApplication(ApplicationLoaderService.java:393)
at com.sun.enterprise.v3.server.ApplicationLoaderService.postConstruct(ApplicationLoaderService.java:229)
at com.sun.hk2.component.AbstractCreatorImpl.inject(AbstractCreatorImpl.java:132)
at com.sun.hk2.component.ConstructorCreator.initialize(ConstructorCreator.java:117)
at com.sun.hk2.component.AbstractCreatorImpl.get(AbstractCreatorImpl.java:84)
at com.sun.hk2.component.SingletonInhabitant.get(SingletonInhabitant.java:67)
at com.sun.hk2.component.EventPublishingInhabitant.get(EventPublishingInhabitant.java:141)
at com.sun.hk2.component.AbstractInhabitantImpl.get(AbstractInhabitantImpl.java:135)
at com.sun.enterprise.v3.server.StartupRunLevelBridge.activate(StartupRunLevelBridge.java:93)
at com.sun.enterprise.v3.server.RunLevelBridge.postConstruct(RunLevelBridge.java:110)
at com.sun.enterprise.v3.server.StartupRunLevelBridge.postConstruct(StartupRunLevelBridge.java:65)
at com.sun.hk2.component.AbstractCreatorImpl.inject(AbstractCreatorImpl.java:132)
at com.sun.hk2.component.ConstructorCreator.initialize(ConstructorCreator.java:117)
at com.sun.hk2.component.AbstractCreatorImpl.get(AbstractCreatorImpl.java:84)
at com.sun.hk2.component.SingletonInhabitant.get(SingletonInhabitant.java:67)
at com.sun.hk2.component.EventPublishingInhabitant.get(EventPublishingInhabitant.java:141)
at com.sun.hk2.component.EventPublishingInhabitant.get(EventPublishingInhabitant.java:141)
at com.sun.hk2.component.RunLevelInhabitant.get(RunLevelInhabitant.java:110)
at com.sun.hk2.component.AbstractInhabitantImpl.get(AbstractInhabitantImpl.java:135)
at com.sun.enterprise.v3.server.AppServerStartup$StartupInhabitantActivator.activate(AppServerStartup.java:526)
at org.jvnet.hk2.component.internal.runlevel.DefaultRunLevelService$Worker.activateRunLevel(DefaultRunLevelService.java:1106)
at org.jvnet.hk2.component.internal.runlevel.DefaultRunLevelService$Worker.upActiveRecorder(DefaultRunLevelService.java:1060)
at org.jvnet.hk2.component.internal.runlevel.DefaultRunLevelService$Worker.run(DefaultRunLevelService.java:1026)
at org.jvnet.hk2.component.internal.runlevel.DefaultRunLevelService$SyncProceedToOp.proceedTo(DefaultRunLevelService.java:1256)
at org.jvnet.hk2.component.internal.runlevel.DefaultRunLevelService.proceedTo(DefaultRunLevelService.java:797)
at org.jvnet.hk2.component.internal.runlevel.DefaultRunLevelService.proceedTo(DefaultRunLevelService.java:759)
at com.sun.enterprise.v3.server.AppServerStartup.proceedTo(AppServerStartup.java:360)
at com.sun.enterprise.v3.server.AppServerStartup.run(AppServerStartup.java:254)
at com.sun.enterprise.v3.server.AppServerStartup.doStart(AppServerStartup.java:172)
at com.sun.enterprise.v3.server.AppServerStartup.start(AppServerStartup.java:163)
at com.sun.enterprise.glassfish.bootstrap.GlassFishImpl.start(GlassFishImpl.java:79)
at com.sun.enterprise.glassfish.bootstrap.GlassFishDecorator.start(GlassFishDecorator.java:63)
at com.sun.enterprise.glassfish.bootstrap.osgi.EmbeddedOSGiGlassFishImpl.start(EmbeddedOSGiGlassFishImpl.java:73)
at com.sun.enterprise.glassfish.bootstrap.GlassFishDecorator.start(GlassFishDecorator.java:63)
at com.sun.enterprise.glassfish.bootstrap.osgi.OSGiGlassFishImpl.start(OSGiGlassFishImpl.java:71)
at com.sun.enterprise.glassfish.bootstrap.GlassFishMain$Launcher.startConsole(GlassFishMain.java:129)
at com.sun.enterprise.glassfish.bootstrap.GlassFishMain$Launcher.launch(GlassFishMain.java:115)
at sun.reflect.NativeMethodAccessorImpl.invoke0(Native Method)
at sun.reflect.NativeMethodAccessorImpl.invoke(NativeMethodAccessorImpl.java:39)
at sun.reflect.DelegatingMethodAccessorImpl.invoke(DelegatingMethodAccessorImpl.java:25)
at java.lang.reflect.Method.invoke(Method.java:597)
at com.sun.enterprise.glassfish.bootstrap.GlassFishMain.main(GlassFishMain.java:97)
at com.sun.enterprise.glassfish.bootstrap.ASMain.main(ASMain.java:55)

#]

Please treat this urgently.



 Comments   
Comment by Shing Wai Chan [ 27/Jul/12 ]

I have the latest workspace. I do not see the NPE mentioned above. Can you try with the latest workspace?

Comment by Sanjeeb Sahoo [ 30/Jul/12 ]

Good to know the NPE does not appear with latest code. Does the webapp actually work after embedded server is restarted?

Comment by Shing Wai Chan [ 30/Jul/12 ]

The connector is not working after running "stop" and "start" again.
Can you clarify what "-DGlassFish_Interactive=true", "stop" and "start" are doing?
Is it a new feature?
I do not see WebContainer.preDestroy is called from the debugger.

Comment by Sanjeeb Sahoo [ 31/Jul/12 ]

Shingwai,

That's what was my observation as well. Connectors are not working after embedded server is restarted. I do believe it's a problem with WebContainer.preDestroy() which is not undoing everything that has happened in postConstruct(). I applied the following patch in my local workspace to fix the connectors issue:

ss141213@Sahoo:/space/ss141213/WS/gf/trunk$ git diff appserver/web
diff --git a/appserver/web/web-glue/src/main/java/com/sun/enterprise/web/WebContainer.java b/appserver/web/web-glue/src/main/java/com/sun/enterprise/web/WebContainer.java
index 68f6c37..eed42ac 100644
— a/appserver/web/web-glue/src/main/java/com/sun/enterprise/web/WebContainer.java
+++ b/appserver/web/web-glue/src/main/java/com/sun/enterprise/web/WebContainer.java
@@ -634,7 +634,12 @@ public class WebContainer implements org.glassfish.api.container.Container, Post
}

public void preDestroy() {
+ // FIX ME: preDestroy should be just the ooposite of postConstruct, but I am not sure why it is not
try {
+ for (WebConnector c : new ArrayList<WebConnector>(connectorMap.values()))

{ + deleteConnector(c); + System.out.println("WebContainer.preDestroy " + c); + }

_embedded.stop();
} catch (LifecycleException le) {
_logger.log(Level.SEVERE,

But, even then something is broken. There after I decided to open this bug.

To answer your question about -DGlassFish_Interactive, start, stop, no, they have been there in the code base for a couple of years now. We internally use them to try out embedded features. It's so much simpler to use them rather than having to write a new program to describe a bug.

Comment by Shing Wai Chan [ 31/Jul/12 ]

Is it related to embedded restart. Assign to Amy for further investigation.

Comment by Amy Roh [ 06/Aug/12 ]

Sahoo,

Which embedded jar are you using? I can't start the embedded server using the latest trunk.

org.glassfish.embeddable.GlassFishException: com.sun.enterprise.module.bootstrap.BootException: Cannot find main module : no such module
at com.sun.enterprise.glassfish.bootstrap.StaticGlassFishRuntime.newGlassFish(StaticGlassFishRuntime.java:155)
....
Caused by: com.sun.enterprise.module.bootstrap.BootException: Cannot find main module : no such module
at com.sun.enterprise.module.bootstrap.Main.findStartupService(Main.java:234)
at com.sun.enterprise.glassfish.bootstrap.StaticGlassFishRuntime.newGlassFish(StaticGlassFishRuntime.java:123)

Comment by Sanjeeb Sahoo [ 08/Aug/12 ]

Amy,

As I mentioned in the bug notes, I am using the regular glassfish.jar that exists in glassfish/modules dir. Just follow the instruction provided in the bug description. Shingwai has already reproduced it.

Thanks,
Sahoo

Comment by Amy Roh [ 08/Aug/12 ]

I confirm that WebContainer#preDestroy/postConstruct are never invoked during GlassFish#stop/start. Shouldn't these be called from GlassFish? AppServerContext#serverStopping() is never invoked during server stop and the old WebContainer is used rather than a new WebContainer getting created via WebContainer#postConstruct.

Comment by Sanjeeb Sahoo [ 09/Aug/12 ]

Amy,

The behavior you have observed must be to do with recent HK2 2.1.x integration. But, when I filed the bug, I used a version of glassfish that used HK2 2.0.x and there I did notice preDestroy() getting called. Since you should not be worrying about these details, I recommend you using GlassFish 3.1.2 to reproduce the bug and fix it. Or, you can use 4weeks older trunk builds of GlassFish as well. Upto you. The fix will be equally applicable to most recent workspace.

Thanks much,
Sahoo

Comment by Amy Roh [ 09/Aug/12 ]

I've put in an incremental fix (55377) but this needs to be investigated further.

The trunk needs to be fixed so that WebContainer#preDestroy/postConstruct are invoked during GlassFish#stop/start.

Comment by Amy Roh [ 10/Aug/12 ]

If I manually invoke preDestroy/postConstruct during glassfish restart using EventListener, I can access 8080 after restart with the patch but I still get 404 for previously deployed webapps so something else is broken here. I'll investigate this further when I get back.

Assigning to hk2 so WebContainer is destroyed during shutdown so it can be started via postConstruct during restart. Embedded server start is also broken as described in GLASSFISH-18989. Please assign it back to me once AppServerContext is fixed to invoke serverStopping() -> WebContainer preDestroy.

Comment by jwells [ 10/Aug/12 ]

I have recently added the ability for @Singleton scoped objects to be shutdown on the shutdown of the ServiceLocator. I believe that this must therefore be happening because the shutdown of the embedded server isn't happening properly, which is is Mason's area of expertise.

Comment by mtaube [ 31/Aug/12 ]

After Revision 55766, WebContainer.preDestroy is being called on shutdown

Comment by Amy Roh [ 31/Aug/12 ]

I confirm that WebContainer.preDestroy gets invoked on shutdown as expected.

However, when restarting GrizzlyService.postConstruct is never called and the mappers are not starting.

GrizzlyService.postConstruct is called as expected when starting glassfish for the first time. Stopping is calling GrizzlyService.preDestroy as expected but restarting glassfish never invokes GrizzlyService.postConstruct.

Comment by mtaube [ 04/Sep/12 ]

After revision 55791, GrizzlyService.preDestroy/postConstruct will be called.

Comment by Amy Roh [ 17/Sep/12 ]

After Ryan's fix (svn 56001) in GlassfishNetworkListener.stop, restart is working as expected.





[GLASSFISH-16528] Cleanup JPA deployer code to remove dependencies on entries from domain.xml Created: 02/May/11  Updated: 14/Mar/12

Status: Open
Project: glassfish
Component/s: entity-persistence
Affects Version/s: None
Fix Version/s: 4.0_b55

Type: Task Priority: Major
Reporter: Mitesh Meswani Assignee: Mitesh Meswani
Resolution: Unresolved Votes: 0
Labels: None
Remaining Estimate: Not Specified
Time Spent: Not Specified
Original Estimate: Not Specified


 Description   

Current JPA deployer code stores entries in domain.xml that helps clean up at undeploy. Investigate if this can be avoided.






[GLASSFISH-16486] Provide SPI to support GlassFish use as a PaaS environment Created: 27/Apr/11  Updated: 01/Oct/12  Resolved: 01/Oct/12

Status: Closed
Project: glassfish
Component/s: logging
Affects Version/s: None
Fix Version/s: 4.0_b55

Type: New Feature Priority: Major
Reporter: naman_mehta Assignee: naman_mehta
Resolution: Invalid Votes: 0
Labels: None
Remaining Estimate: Not Specified
Time Spent: Not Specified
Original Estimate: Not Specified

Issue Links:
Dependency
blocks GLASSFISH-16494 Enhancement for logging in a PaaS env... Closed
Tags: ee7_cleanup_closed

 Description   

Creating this RFE based on my investigation on logging side to support GlassFish use as a PaaS environment.

So plan to update more details after one pager review comment:
http://wikis.sun.com/display/GlassFish/v32LoggingOnePager#v32LoggingOnePager-4.1.1EnhancementforlogginginaPaaSenvironment



 Comments   
Comment by Tom Mueller [ 01/Oct/12 ]

Since cloud support has been deferred for the Java EE 7 release, this issue is being closed. If it is useful for future Java EE work, it can be reopened.





[GLASSFISH-16484] Application redeploy to user-managed cluster Created: 27/Apr/11  Updated: 14/Mar/12  Resolved: 18/Jan/12

Status: Resolved
Project: glassfish
Component/s: deployment
Affects Version/s: 4.0
Fix Version/s: 4.0_b55

Type: New Feature Priority: Blocker
Reporter: Hong Zhang Assignee: Hong Zhang
Resolution: Won't Fix Votes: 0
Labels: None
Remaining Estimate: Not Specified
Time Spent: Not Specified
Original Estimate: Not Specified

Issue Links:
Dependency
blocks GLASSFISH-16431 CLUST-2 User-Managed Clusters Resolved
Tags: 3_2prd

 Description   

Allow an application that has been deployed to the user-managed cluster to be redeployed, i.e., undeployed and a new version deployed (or deploy --force) without recreating the cluster. This means that any cluster-specific configuration is retained. JMS messages are preserved, etc.



 Comments   
Comment by Tom Mueller [ 18/Jan/12 ]

The 3.2 release has been cancelled - moving on to 4.0.
Marking this as "won't fix" because it isn't a part of the 4.0 plan.





[GLASSFISH-16449] Extend installer configurator to handle virtual machine creation. Created: 25/Apr/11  Updated: 18/Oct/12  Resolved: 18/Oct/12

Status: Closed
Project: glassfish
Component/s: installation
Affects Version/s: 4.0
Fix Version/s: 4.0_b55

Type: New Feature Priority: Critical
Reporter: Snjezana Sevo-Zenzerovic Assignee: Snjezana Sevo-Zenzerovic
Resolution: Won't Fix Votes: 0
Labels: None
Remaining Estimate: Not Specified
Time Spent: Not Specified
Original Estimate: Not Specified

Issue Links:
Dependency
depends on GLASSFISH-16378 IaaS Management Service: API and SPI Closed
Tags: ee7_cleanup_closed

 Description   

GlassFish installer configurator should be extended to support basic IaaS functionality. Installer should be able to gather customization property parameters from the user and use them to create initial set of virtual machines.



 Comments   
Comment by Snjezana Sevo-Zenzerovic [ 25/Apr/11 ]

Issue depends on GLASSFISH-16378.

Comment by Snjezana Sevo-Zenzerovic [ 18/Oct/12 ]

Not applicable for the release due to removed cloud support.





[GLASSFISH-16439] Create a unique "domain ID" shared by and accessible to all servers in the domain Created: 22/Apr/11  Updated: 14/Mar/12  Resolved: 29/Sep/11

Status: Resolved
Project: glassfish
Component/s: admin
Affects Version/s: None
Fix Version/s: 4.0_b55, 4.0

Type: New Feature Priority: Major
Reporter: Tim Quinn Assignee: Tom Mueller
Resolution: Fixed Votes: 0
Labels: None
Remaining Estimate: Not Specified
Time Spent: Not Specified
Original Estimate: Not Specified

Issue Links:
Dependency
blocks GLASSFISH-16438 Ensure that admin traffic from other ... Resolved

 Description   

A related enhancement (Issue 16438) would allow servers receiving admin requests from other instances to be sure that the sending server is in the same domain as the recipient.

To do so the sender and recipient need access to a common "domain ID."



 Comments   
Comment by Tim Quinn [ 25/Jul/11 ]

In 3.1.1 secure admin creates, for its own use, a unique identifier that it sends on admin traffic among servers and which it persists in the secure-admin element in domain.xml.

In that sense, secure admin no longer depends on this issue. If admin itself changes to implement a domain-wide identifier then we could consider retrofitting the use of that new identifier back into secure admin.

Comment by Tom Mueller [ 29/Sep/11 ]

Marking this as fixed since secure-admin has what it needs in this area. In the future, should the need arise for this in another area, a more global value should be created.





[GLASSFISH-16426] Support the Paas redeploy scenario. Created: 21/Apr/11  Updated: 01/Oct/12  Resolved: 01/Oct/12

Status: Closed
Project: glassfish
Component/s: deployment
Affects Version/s: 4.0
Fix Version/s: 4.0_b55

Type: New Feature Priority: Blocker
Reporter: Hong Zhang Assignee: Hong Zhang
Resolution: Invalid Votes: 0
Labels: None
Remaining Estimate: Not Specified
Time Spent: Not Specified
Original Estimate: Not Specified

Issue Links:
Dependency
blocks GLASSFISH-16409 Support various PaaS deployment scena... Closed
Tags: ee7_cleanup_closed

 Description   

Support the Paas redeploy scenario.

Necessary changes will be made on the deployment framework to allow orchestrator to plug in its work to do service provisioning during redeployment.

This is a sub issue to address requirements on deployment for the high level service provisioning feature. End-to-end feature delivery will depend on service orchestration.



 Comments   
Comment by Tom Mueller [ 01/Oct/12 ]

Since cloud support has been deferred for the Java EE 7 release, this issue is being closed. If it is useful for future Java EE work, it can be reopened.





[GLASSFISH-16411] Add administration and management capabilities to support PaaS deployment Created: 21/Apr/11  Updated: 01/Oct/12  Resolved: 01/Oct/12

Status: Closed
Project: glassfish
Component/s: service-orchestration
Affects Version/s: 4.0
Fix Version/s: 4.0_b55

Type: New Feature Priority: Blocker
Reporter: Sivakumar Thyagarajan Assignee: Sivakumar Thyagarajan
Resolution: Invalid Votes: 0
Labels: None
Remaining Estimate: Not Specified
Time Spent: Not Specified
Original Estimate: Not Specified

Issue Links:
Dependency
blocks GLASSFISH-16402 Single-click application provisioning... Closed
Tags: ee7_cleanup_closed

 Description   

Add administration and management capabilities to support PaaS deployment:

  • P1: Admin command interception for managed services/resources: All the administration operations/commands on a managed entity(such as a cluster provisioned by the orchestrator) must be intercepted by the Orchestrator. The orchestrator will decide whether to allow or disallow these operations. (For example, orchestrator might not allow 'asadmin stop-cluster' on a managed cluster). Moreover, orchestrator might need to perform some additional tasks (eg: for book-keeping purposes) during the command execution on a managed object. Admin Infrastructure must wrap all the commands on the managed object to go to Orchestrator first.
  • P1: Additional asadmin commands: Implement admin commands for create/delete/list global services in a domain. The command implementation will internally invoke the plugin to do the needful. Plugin might internally use IaaS APIs, various existing glassfish commands to perform the task. Implement admin command to import/provision an external service into a domain.
  • P1: CLI/GUI to show all provisioned/shared services for a particular deployed application: Orchestrator, with the help of plugins can determine implicit service requirements or use default service requirements or use shared services in order to satisfy an application's various service requirements. There needs to be an administrative interface (eg: CLI) to show the list of all services used by a particular application. eg: The State of the service(started/stopped/stopping/starting) can also be shown. In case of partial undeployments, some services might be in deleted state.
  • P1: CLI/GUI to show the list of managed applications that share a particular services: A CLI command to list all applications that use or is bound to a global/shared service or an external service.
  • P2: Logging Orchestrator actions to aid troubleshooting: Since a PaaS-style deployment would entail a lot of Orchestrator operations (such as Template Matching, Service Provisioning, Service Assocation), it is imperative that the Orchestrator logs all its actions to enable offline troubleshooting.
  • P3: Monitoring probes: Expose monitoring probes for various Orchestrator functionalities
  • P3: Health check - service: Ability to perform a health-check on a particular Service (eg: ping)
  • P1: GUI (admin console) requirements: For example, a GUI option for PaaS style deployments, creating and registering Service Templates are suggested requirements on the admin console.


 Comments   
Comment by shreedhar_ganapathy [ 27/Oct/11 ]

Changed AffectsVersion to 4.0

Comment by shreedhar_ganapathy [ 07/Nov/11 ]

Need to revisit this issue to determine actual completion of several tasks listed in the description.
Siva, could you update the latest status of this RFE?

Comment by Tom Mueller [ 01/Oct/12 ]

Since cloud support has been removed from Java EE 7, this issue has been closed. This issue can be reopened if desired for future Java EE work.





[GLASSFISH-16410] Provide a set of standard pre-built Service Templates Created: 21/Apr/11  Updated: 01/Oct/12  Resolved: 01/Oct/12

Status: Closed
Project: glassfish
Component/s: paas-console, service-orchestration
Affects Version/s: 4.0
Fix Version/s: 4.0_b55

Type: New Feature Priority: Blocker
Reporter: Sivakumar Thyagarajan Assignee: Sivakumar Thyagarajan
Resolution: Invalid Votes: 0
Labels: None
Remaining Estimate: Not Specified
Time Spent: Not Specified
Original Estimate: Not Specified

Issue Links:
Dependency
blocks GLASSFISH-16402 Single-click application provisioning... Closed
Tags: ee7_cleanup_closed

 Description   

GlassFish 4 would come with standard pre-built templates for the supported service providers.

The orchestrator matches the service requirements of an application to a service template(either pre-built or user-provided) through its cloud metadata. The orchestrator/service plugin must not assume that the pre-built service template is the only template that could be provisioned. In other words, the orchestrator/plugin must support user-defined service templates.



 Comments   
Comment by shreedhar_ganapathy [ 27/Oct/11 ]

Changed AffectsVersion to 4.0

Comment by shreedhar_ganapathy [ 07/Nov/11 ]

I guess, this fix that went in as part of erstwhile 3.2 only partly addresses this requirement and additionally imposes an implicit requirement on PaaS console.
Updated components to reflect this.

Comment by Tom Mueller [ 01/Oct/12 ]

Since cloud support has been removed from Java EE 7, this issue has been closed. This issue can be reopened if desired for future Java EE work.





[GLASSFISH-16408] Service provisioning to support a standard list of ServiceTypes and Service Providers Created: 21/Apr/11  Updated: 01/Oct/12  Resolved: 01/Oct/12

Status: Closed
Project: glassfish
Component/s: service-orchestration
Affects Version/s: 4.0
Fix Version/s: 4.0_b55

Type: New Feature Priority: Major
Reporter: Sivakumar Thyagarajan Assignee: Sivakumar Thyagarajan
Resolution: Invalid Votes: 0
Labels: None
Remaining Estimate: Not Specified
Time Spent: Not Specified
Original Estimate: Not Specified

Issue Links:
Dependency
blocks GLASSFISH-16402 Single-click application provisioning... Closed
Tags: ee7_cleanup_closed

 Description   

Supported list of ServiceTypes and Service Providers

Support a standard list of service types and a list of service providers per ServiceType:
Suggested list:
RDBMS(JavaDB, MySQL)
HTTPLoadBalancer (TBD)
JMS(OpenMQ)



 Comments   
Comment by shreedhar_ganapathy [ 27/Oct/11 ]

Changed AffectsVersion to 4.0

Comment by Tom Mueller [ 01/Oct/12 ]

Since cloud support has been removed from Java EE 7, this issue has been closed. This issue can be reopened if desired for future Java EE work.





[GLASSFISH-16407] Automatic Service association for a PaaS application Created: 21/Apr/11  Updated: 01/Oct/12  Resolved: 01/Oct/12

Status: Closed
Project: glassfish
Component/s: service-orchestration
Affects Version/s: 4.0
Fix Version/s: 4.0_b55

Type: New Feature Priority: Blocker
Reporter: Sivakumar Thyagarajan Assignee: Sivakumar Thyagarajan
Resolution: Invalid Votes: 0
Labels: None
Remaining Estimate: Not Specified
Time Spent: Not Specified
Original Estimate: Not Specified

Issue Links:
Dependency
blocks GLASSFISH-16402 Single-click application provisioning... Closed
Tags: ee7_cleanup_closed

 Description   

Service Association/Binding

Automatically perform necessary actions(create the necessary pools/resources etc) in the application server to bind an application to the services provisioned for the application



 Comments   
Comment by shreedhar_ganapathy [ 27/Oct/11 ]

Changed AffectsVersion to 4.0

Comment by Tom Mueller [ 01/Oct/12 ]

Since cloud support has been removed from Java EE 7, this issue has been closed. This issue can be reopened if desired for future Java EE work.





[GLASSFISH-15690] spaces in the names of jar files cause deployment problems Created: 25/Jan/11  Updated: 24/Sep/12  Resolved: 24/Sep/12

Status: Closed
Project: glassfish
Component/s: deployment
Affects Version/s: 3.1_b38
Fix Version/s: 4.0_b55

Type: Bug Priority: Critical
Reporter: vince kraemer Assignee: Hong Zhang
Resolution: Fixed Votes: 0
Labels: None
Remaining Estimate: Not Specified
Time Spent: Not Specified
Original Estimate: Not Specified
Environment:

mac os x 10.6.6


Attachments: Zip Archive GLASSFISH-15690_friendly_message.zip     File Product Portal.ear     Java Archive File space-jars.jar    
Tags: 3_1-next, 3_1_1-scrubbed, 3_1_2-exclude

 Description   

steps to reproduce

unzip the attached file.
start the server
asadmin deploy Domain/Departement/Product\ Portal/dist/gfdeploy/Product_Portal

You will see the error message "remote failure: Error occurred during deployment: com/company/domain/web/controller/WebController. Please see server.log for more details.
Command deploy failed."

But wait... it gets better!

if you retry the deployment, you get a new different error message.

remote failure: Error occurred during deployment: Application name Product_Portal is already in use. Please pick a different name.. Please see server.log for more details.
Command deploy failed.

BUT.. if you list applications (asadmin list-applications), there isn't a Product_Portal there.

You have to restart the server to clear this second error.

See the netbeans issues http://netbeans.org/bugzilla/show_bug.cgi?id=188740 and http://netbeans.org/bugzilla/show_bug.cgi?id=194711 for more details.

I am marking this issue as critical for a couple reasons:

1. the first error message from deployment is not very informative... there is no mention that embedded spaces are not allowed in the names of jars that are part of an ear.... and it seems like that is an arbitrary constraint anyway.

2. the first deployment error puts the server into an inconsistent state that is impossible to resolve without restarting the server.



 Comments   
Comment by vince kraemer [ 25/Jan/11 ]

if you attempt to deploy this ear file, the log messages are better, but the error message presented by asadmin is not very strong.

~/GlassFish_Server/bin/asadmin deploy --name PPear Domain/Departement/Product\ Portal/dist/Product\ Portal.ear
remote failure: Error occurred during deployment: Exception while deploying the app [PPear]. Please see server.log for more details.
Command deploy failed.

Comment by Hong Zhang [ 26/Jan/11 ]

I was able to reproduce the issue. I agree with both counts of your conclusion:

For 1): We need to figure out what it takes to support a jar with space in its name, and if we don't support it, we need to provide a better error message. As jar with space in name is not very common use case, and the effort to solve this would be non-trivial, we will delay this part to next release as we are so close to the final release of 3.1.

For 2): It's not good to put server into inconsistent state after a failed deployment and I think we should fix it for this release. I have a fix available in my local workspace for this now and I will submit a change request for it.

Comment by Hong Zhang [ 26/Jan/11 ]

1. How bad is its impact? (Severity)
Hurts user experience, user has to restart server to get the server back into a consistent state. No failed deployments should put server into an inconsistent state.

2. How often does it happen? (Frequency)
When the failed scenario throws an Error instead of an Exception, the clean up/roll back logic would not be run as expected.

3. How much effort is required to fix it? (Cost)
The fix is available and reviewed.

4. What is the risk of fixing it? (Risk)
Small.

5. Does a work around for the issue exist? Can the workaround be reasonably employed by the end user?
Workaround is to restart server, can be done by user but hurts user experience.

6. If the issue is not fixed should the issue and its workaround (if applicable) be described in the Release Notes?
Probably.

Comment by Chris Kasso [ 26/Jan/11 ]

Approved for 3.1

Comment by Hong Zhang [ 26/Jan/11 ]

The fix for part 2) has been checked in. And we will further evaluate part 1) in the next release.

Comment by David Konecny [ 26/Jan/11 ]

Thanks for prompt fix.

Re. "As jar with space in name is not very common use case" - well, they are not because they cause problems like this one and so people stopped using them to avoid these problems.

Re. "Part 1)" - did I get it right that for this release you will fix just the error message? That would be great. Thx.

Comment by Hong Zhang [ 26/Jan/11 ]

The fix checked in is only for part 2). For part 1, we will investigate further in next release to see if we can support this use case, and if not, come up with a better error message.

Comment by scatari [ 04/Nov/11 ]

Please evaluate this for possible inclusion into 3.1.2.

Comment by Hong Zhang [ 14/Dec/11 ]

I tried to make changes to allow spaces in the module name and the changes just turned out to be too involving. I think we will have to delay this to the next release at this point.

We did address the two more severe issues in this release which are related to spaces in the path:
http://java.net/jira/browse/GLASSFISH-17242
http://java.net/jira/browse/GLASSFISH-16333

Comment by vince kraemer [ 14/Dec/11 ]

I am a bit confused by http://java.net/jira/browse/GLASSFISH-15690?focusedCommentId=326780&page=com.atlassian.jira.plugin.system.issuetabpanels%3Acomment-tabpanel#action_326780

This issue is not a space in module name issue... the module name is Product_Portal... right? There isn't a space in that name as best I can tell.

This issue is a directory deployment issue, no?

Comment by vince kraemer [ 14/Dec/11 ]

Hmm. It looks like you were working on the issue described in the first comment... It looks like my comment was to add more info about steps I took to investigate the issue in the description.

Comment by Hong Zhang [ 14/Dec/11 ]

If you look inside the ear, you would find an ejb module called "Product Objects.jar" which is the main issue here. If I change that module name to something like "Product_Objects.jar", the application deploys without any issue.

Comment by Jeremy_Lv [ 19/Sep/12 ]

about 1):which idea shall we take into measures to the spaces in the names of jar files. shall we support to deploy it with spaces in the names of jar file or just provide a better error messages?

the current messages are as follows:


[#|2012-09-19T11:41:33.799+0900|SEVERE|44.0|javax.enterprise.system.core.com.sun.enterprise.v3.server|_ThreadID=98;_ThreadName=admin-listener(12);|Exception while deploying the app [Product_Portal]|#]

[#|2012-09-19T11:41:33.799+0900|SEVERE|44.0|javax.enterprise.system.core.com.sun.enterprise.v3.server|_ThreadID=98;_ThreadName=admin-listener(12);|Illegal character in path at index 7: Product Objects.jar
java.lang.IllegalArgumentException: Illegal character in path at index 7: Product Objects.jar
at java.net.URI.create(URI.java:859)
at java.net.URI.resolve(URI.java:1043)
at com.sun.enterprise.deployment.Application.getTargetUri(Application.java:943)
at com.sun.enterprise.deployment.Application.getRelativeBundle(Application.java:964)
at com.sun.enterprise.deployment.util.ComponentValidator.accept(ComponentValidator.java:411)
at com.sun.enterprise.deployment.util.DefaultDOLVisitor.accept(DefaultDOLVisitor.java:78)
at com.sun.enterprise.deployment.util.ComponentValidator.accept(ComponentValidator.java:119)
at com.sun.enterprise.deployment.util.ApplicationValidator.accept(ApplicationValidator.java:146)
at org.glassfish.web.deployment.util.WebBundleValidator.accept(WebBundleValidator.java:81)
at com.sun.enterprise.deployment.BundleDescriptor.visit(BundleDescriptor.java:621)
at org.glassfish.web.deployment.descriptor.WebBundleDescriptorImpl.visit(WebBundleDescriptorImpl.java:2053)
at org.glassfish.web.deployment.descriptor.WebBundleDescriptorImpl.visit(WebBundleDescriptorImpl.java:2043)
at com.sun.enterprise.deployment.util.ApplicationValidator.accept(ApplicationValidator.java:125)
at com.sun.enterprise.deployment.BundleDescriptor.visit(BundleDescriptor.java:621)
at com.sun.enterprise.deployment.archivist.ApplicationArchivist.validate(ApplicationArchivist.java:700)
at com.sun.enterprise.deployment.archivist.ApplicationArchivist.openWith(ApplicationArchivist.java:248)
at com.sun.enterprise.deployment.archivist.ApplicationFactory.openWith(ApplicationFactory.java:235)
at org.glassfish.javaee.core.deployment.DolProvider.processDOL(DolProvider.java:188)
at org.glassfish.javaee.core.deployment.DolProvider.load(DolProvider.java:222)
at org.glassfish.javaee.core.deployment.DolProvider.load(DolProvider.java:96)
at com.sun.enterprise.v3.server.ApplicationLifecycle.loadDeployer(ApplicationLifecycle.java:875)
at com.sun.enterprise.v3.server.ApplicationLifecycle.setupContainerInfos(ApplicationLifecycle.java:815)
at com.sun.enterprise.v3.server.ApplicationLifecycle.deploy(ApplicationLifecycle.java:377)
at com.sun.enterprise.v3.server.ApplicationLifecycle.deploy(ApplicationLifecycle.java:228)
at org.glassfish.deployment.admin.DeployCommand.execute(DeployCommand.java:482)
at com.sun.enterprise.v3.admin.CommandRunnerImpl$2.execute(CommandRunnerImpl.java:529)
at com.sun.enterprise.v3.admin.CommandRunnerImpl.doCommand(CommandRunnerImpl.java:550)
at com.sun.enterprise.v3.admin.CommandRunnerImpl.doCommand(CommandRunnerImpl.java:1430)
at com.sun.enterprise.v3.admin.CommandRunnerImpl.access$1600(CommandRunnerImpl.java:114)
at com.sun.enterprise.v3.admin.CommandRunnerImpl$ExecutionContext.execute(CommandRunnerImpl.java:1734)
at com.sun.enterprise.v3.admin.CommandRunnerImpl$ExecutionContext.execute(CommandRunnerImpl.java:1683)
at org.glassfish.admin.rest.utils.ResourceUtil.runCommand(ResourceUtil.java:259)
at org.glassfish.admin.rest.utils.ResourceUtil.runCommand(ResourceUtil.java:248)
at org.glassfish.admin.rest.utils.ResourceUtil.runCommand(ResourceUtil.java:239)
at org.glassfish.admin.rest.utils.ResourceUtil.runCommand(ResourceUtil.java:231)
at org.glassfish.admin.rest.resources.TemplateListOfResource.createResource(TemplateListOfResource.java:132)
at sun.reflect.NativeMethodAccessorImpl.invoke0(Native Method)
at sun.reflect.NativeMethodAccessorImpl.invoke(NativeMethodAccessorImpl.java:57)
at sun.reflect.DelegatingMethodAccessorImpl.invoke(DelegatingMethodAccessorImpl.java:43)
at java.lang.reflect.Method.invoke(Method.java:601)
at org.glassfish.jersey.server.model.ResourceMethodInvocationHandlerFactory$1.invoke(ResourceMethodInvocationHandlerFactory.java:80)
at org.glassfish.jersey.server.model.AbstractJavaResourceMethodDispatcher.invoke(AbstractJavaResourceMethodDispatcher.java:113)
at org.glassfish.jersey.server.model.AbstractJavaResourceMethodDispatcherProvider$ResponseOutInvoker.doDispatch(AbstractJavaResourceMethodDispatcherProvider.java:176)
at org.glassfish.jersey.server.model.AbstractJavaResourceMethodDispatcher.dispatch(AbstractJavaResourceMethodDispatcher.java:79)
at org.glassfish.jersey.server.model.ResourceMethodInvoker.apply(ResourceMethodInvoker.java:268)
at org.glassfish.jersey.server.model.ResourceMethodInvoker.apply(ResourceMethodInvoker.java:84)
at org.glassfish.jersey.process.internal.RequestInvoker$AcceptingInvoker.apply(RequestInvoker.java:241)
at org.glassfish.jersey.process.internal.AsyncInflectorAdapter.apply(AsyncInflectorAdapter.java:157)
at org.glassfish.jersey.process.internal.RequestInvoker$2.run(RequestInvoker.java:188)
at org.glassfish.jersey.process.internal.RequestScope.runInScope(RequestScope.java:309)
at org.glassfish.jersey.process.internal.RequestInvoker$3.run(RequestInvoker.java:201)
at java.util.concurrent.Executors$RunnableAdapter.call(Executors.java:471)
at java.util.concurrent.FutureTask$Sync.innerRun(FutureTask.java:334)
at java.util.concurrent.FutureTask.run(FutureTask.java:166)
at com.google.common.util.concurrent.MoreExecutors$SameThreadExecutorService.execute(MoreExecutors.java:262)
at com.google.common.util.concurrent.AbstractListeningExecutorService.submit(AbstractListeningExecutorService.java:43)
at com.google.common.util.concurrent.AbstractListeningExecutorService.submit(AbstractListeningExecutorService.java:40)
at org.glassfish.jersey.process.internal.RequestInvoker.apply(RequestInvoker.java:197)
at org.glassfish.jersey.server.ApplicationHandler.handle(ApplicationHandler.java:758)
at org.glassfish.jersey.grizzly2.httpserver.GrizzlyHttpContainer.service(GrizzlyHttpContainer.java:298)
at org.glassfish.admin.rest.adapter.RestAdapter$1.service(RestAdapter.java:328)
at org.glassfish.admin.rest.adapter.RestAdapter.service(RestAdapter.java:190)
at com.sun.enterprise.v3.server.HK2Dispatcher.dispatch(HK2Dispatcher.java:113)
at com.sun.enterprise.v3.services.impl.ContainerMapper.service(ContainerMapper.java:236)
at org.glassfish.grizzly.http.server.HttpHandler.doHandle(HttpHandler.java:164)
at org.glassfish.grizzly.http.server.HttpServerFilter.handleRead(HttpServerFilter.java:175)
at org.glassfish.grizzly.filterchain.ExecutorResolver$9.execute(ExecutorResolver.java:119)
at org.glassfish.grizzly.filterchain.DefaultFilterChain.executeFilter(DefaultFilterChain.java:265)
at org.glassfish.grizzly.filterchain.DefaultFilterChain.executeChainPart(DefaultFilterChain.java:200)
at org.glassfish.grizzly.filterchain.DefaultFilterChain.execute(DefaultFilterChain.java:134)
at org.glassfish.grizzly.filterchain.DefaultFilterChain.process(DefaultFilterChain.java:112)
at org.glassfish.grizzly.ProcessorExecutor.execute(ProcessorExecutor.java:77)
at org.glassfish.grizzly.nio.transport.TCPNIOTransport.fireIOEvent(TCPNIOTransport.java:825)
at org.glassfish.grizzly.strategies.AbstractIOStrategy.fireIOEvent(AbstractIOStrategy.java:112)
at org.glassfish.grizzly.strategies.WorkerThreadIOStrategy.run0(WorkerThreadIOStrategy.java:115)
at org.glassfish.grizzly.strategies.WorkerThreadIOStrategy.access$100(WorkerThreadIOStrategy.java:55)
at org.glassfish.grizzly.strategies.WorkerThreadIOStrategy$WorkerThreadRunnable.run(WorkerThreadIOStrategy.java:135)
at org.glassfish.grizzly.threadpool.AbstractThreadPool$Worker.doWork(AbstractThreadPool.java:578)
at org.glassfish.grizzly.threadpool.AbstractThreadPool$Worker.run(AbstractThreadPool.java:558)
at java.lang.Thread.run(Thread.java:722)
Caused by: java.net.URISyntaxException: Illegal character in path at index 7: Product Objects.jar
at java.net.URI$Parser.fail(URI.java:2829)
at java.net.URI$Parser.checkChars(URI.java:3002)
at java.net.URI$Parser.parseHierarchical(URI.java:3086)
at java.net.URI$Parser.parse(URI.java:3044)
at java.net.URI.<init>(URI.java:595)
at java.net.URI.create(URI.java:857)
... 79 more

#]
Comment by Hong Zhang [ 19/Sep/12 ]

Jeremy, thanks for looking into this. I remember when I was attempting to make changes to support jar with space in it, the changes were pretty involving and extensive. So let's go with another route this time, trying to see if we could come up with a good error message.

Comment by Jeremy_Lv [ 20/Sep/12 ]

add a friendly messages about spaces in the names of jar files.
please check it.

Comment by Hong Zhang [ 20/Sep/12 ]

Thanks for looking into this. A few comments:

1. I revisited this part of the code today, and I think the check will be best made in this method of ApplicationArchivist for unsupported module uri:

public boolean readModulesDescriptors(Application app, ReadableArchive appArchive)
This is where we have already parsed the application.xml and begin to read the modules of the application. We should check for module URI (to see if contains space, if yes, throw an exception which will fail the deployment) in the beginning of this for loop,
for (ModuleDescriptor aModule : sortedModules) {
if (aModule.getArchiveUri().indexOf(SPACE_CHAR) != -1)

{ // throw exception }

...

please try it to see if it works for the test cases or not.

2. We should fail the deployment instead of proceeding so user could correct it before runs into any other cryptic errors later on.

3. The error message needs to be i10ned, please put the error string in the LocalStrings.properties when throwing the exception to fail the deployment. And the error message should be something like "Unsupported module URI

{0}

, it contains space(s)" so user knows why it failed and how they could fix it.

Comment by Jeremy_Lv [ 21/Sep/12 ]

Thanks for your patient suggestion. I'm agree with your modification and I will test about it before I check in.

Comment by Jeremy_Lv [ 21/Sep/12 ]

Hong:
I have reattached the modification source and test results to the JIRA.
All of the QL tests and DEV tests can be passed.
I will check in the code soon.
Shall I closed this issue as fixed?

Comment by Jeremy_Lv [ 21/Sep/12 ]

Sending E:\GF_MAIN\SOURCE_0921\appserver\deployment\dol\src\main\java\com\sun\enterprise\deployment\archivist\ApplicationArchivist.java
Sending E:\GF_MAIN\SOURCE_0921\appserver\deployment\dol\src\main\java\com\sun\enterprise\deployment\archivist\LocalStrings.properties
Transmitting file data .
Committed revision 56079.

Comment by Hong Zhang [ 21/Sep/12 ]

yes, you can close the issue as fixed, thanks.





Generated at Sun Jul 05 10:49:07 UTC 2015 using JIRA 6.2.3#6260-sha1:63ef1d6dac3f4f4d7db4c1effd405ba38ccdc558.