diff --git a/appserver/extras/docker-images/tests/pom.xml b/appserver/extras/docker-images/tests/pom.xml index a3e787204cf..7f1825404a9 100644 --- a/appserver/extras/docker-images/tests/pom.xml +++ b/appserver/extras/docker-images/tests/pom.xml @@ -85,7 +85,7 @@ org.junit.jupiter junit-jupiter-engine - 5.12.0 + 5.11.4 test diff --git a/appserver/tests/payara-samples/samples/concurrency/pom.xml b/appserver/tests/payara-samples/samples/concurrency/pom.xml index dfbf3966783..9ae08430820 100644 --- a/appserver/tests/payara-samples/samples/concurrency/pom.xml +++ b/appserver/tests/payara-samples/samples/concurrency/pom.xml @@ -58,7 +58,7 @@ UTF-8 false 1.9.1.Final - 5.12.0 + 5.11.4 3.0.alpha4 3.0.4 3.3.3 @@ -133,7 +133,7 @@ maven-compiler-plugin - 3.14.0 + 3.13.0 maven-surefire-plugin diff --git a/appserver/web/weld-integration/src/main/java/org/glassfish/weld/DeploymentImpl.java b/appserver/web/weld-integration/src/main/java/org/glassfish/weld/DeploymentImpl.java index 620314edebf..7c14b890c05 100644 --- a/appserver/web/weld-integration/src/main/java/org/glassfish/weld/DeploymentImpl.java +++ b/appserver/web/weld-integration/src/main/java/org/glassfish/weld/DeploymentImpl.java @@ -159,6 +159,7 @@ public DeploymentImpl(ReadableArchive archive, this.archiveFactory = archiveFactory; this.context = context; this.injectionManager = injectionManager; + this.contextId = moduleName != null? moduleName : archive.getName(); // Collect /lib Jar BDAs (if any) from the parent module. // If we've produced BDA(s) from any /lib jars, return as @@ -177,7 +178,6 @@ public DeploymentImpl(ReadableArchive archive, this.appName = "CDIApp"; } - this.contextId = moduleName != null? moduleName : archive.getName(); createModuleBda(archive, ejbs, context, contextId); } @@ -274,7 +274,9 @@ private Set filterBDAs(Set bdas, List } private void addBeanDeploymentArchives(RootBeanDeploymentArchive bda) { - rootBDAs(bda).add(bda); + if (bda.getModuleBDAType() != BDAType.UNKNOWN) { + rootBDAs(bda).add(bda); + } } private Set rootBDAs(RootBeanDeploymentArchive bda) { diff --git a/appserver/web/weld-integration/src/main/java/org/glassfish/weld/WeldDeployer.java b/appserver/web/weld-integration/src/main/java/org/glassfish/weld/WeldDeployer.java index d049c743e07..ed947dd3295 100644 --- a/appserver/web/weld-integration/src/main/java/org/glassfish/weld/WeldDeployer.java +++ b/appserver/web/weld-integration/src/main/java/org/glassfish/weld/WeldDeployer.java @@ -398,9 +398,12 @@ public WeldApplicationContainer load(WeldContainer container, DeploymentContext beanDeploymentArchive.getServices().add(EEModuleDescriptor.class, eeModuleDescriptor); } } + if (beanDeploymentArchive instanceof BeanDeploymentArchiveImpl + && ((BeanDeploymentArchiveImpl) beanDeploymentArchive) + .getBDAType() != WeldUtils.BDAType.UNKNOWN) { + bundleToBeanDeploymentArchive.put(bundle, beanDeploymentArchive); + } } - - bundleToBeanDeploymentArchive.put(bundle, beanDeploymentArchive); } applicationInfo.addTransientAppMetaData(WELD_DEPLOYMENT, deploymentImpl); diff --git a/appserver/web/weld-integration/src/main/java/org/glassfish/weld/services/InjectionServicesImpl.java b/appserver/web/weld-integration/src/main/java/org/glassfish/weld/services/InjectionServicesImpl.java index 876512cab91..a2f36f6cc1e 100644 --- a/appserver/web/weld-integration/src/main/java/org/glassfish/weld/services/InjectionServicesImpl.java +++ b/appserver/web/weld-integration/src/main/java/org/glassfish/weld/services/InjectionServicesImpl.java @@ -41,6 +41,7 @@ package org.glassfish.weld.services; +import com.sun.enterprise.deployment.Application; import com.sun.enterprise.deployment.BundleDescriptor; import com.sun.enterprise.deployment.EjbBundleDescriptor; import com.sun.enterprise.deployment.EjbDescriptor; @@ -155,7 +156,7 @@ public void aroundInject(InjectionContext injectionContext) { String targetClassName = targetClass.getName(); Object target = injectionContext.getTarget(); - if ( isInterceptor( targetClass ) + if ( isInterceptor( targetClass ) && !(bundleContext instanceof Application) && (componentEnv != null && !componentEnv.equals(injectionEnv)) ) { // Resources injected into interceptors must come from the environment in which the interceptor is // intercepting, not the environment in which the interceptor resides (for everything else!) @@ -214,7 +215,7 @@ public void aroundInject(InjectionContext injectionContext) { } else { injectionManager.injectInstance(target, compEnvManager.getComponentEnvId(injectionEnv),false); } - } else { + } else if (!(bundleContext instanceof Application)){ if ( target == null ) { injectionManager.injectClass(targetClass, injectionEnv, false); } else { @@ -234,7 +235,7 @@ public void aroundInject(InjectionContext injectionContext) { @Override public void registerInjectionTarget(InjectionTarget injectionTarget, AnnotatedType annotatedType) { - if ( bundleContext instanceof EjbBundleDescriptor ) { + if ( bundleContext instanceof EjbBundleDescriptor || bundleContext instanceof Application ) { // we can't handle validting producer fields for ejb bundles because the JNDI environment is not setup // yet for ejbs and so we can't get the correct JndiNameEnvironment to call getInjectionInfoByClass. // getInjectionInfoByClass caches the results and so causes subsequent calls to return invalid information. diff --git a/core/pom.xml b/core/pom.xml index af75a679258..73445381e63 100644 --- a/core/pom.xml +++ b/core/pom.xml @@ -166,7 +166,7 @@ false 3.4.2 3.4.1 - 3.14.0 + 3.13.0 true 3.5.2 3.3.1 @@ -198,7 +198,7 @@ 1.3 0.2.12 - 4.3.0 + 4.2.2 diff --git a/nucleus/admin/template/pom.xml b/nucleus/admin/template/pom.xml index c98d07535a5..70856011300 100644 --- a/nucleus/admin/template/pom.xml +++ b/nucleus/admin/template/pom.xml @@ -97,7 +97,16 @@ +-- + saying Payara is running etc when nothing is deployed to root. --> + + org.glassfish.docs + basedocs + 4.1.payara-p3 + zip + false + glassfish/lib/templates/** + + fish.payara.server.internal.ejb ejb-http-endpoint diff --git a/nucleus/admin/template/src/main/resources/docroot/index.html b/nucleus/admin/template/src/main/resources/docroot/index.html index 3e0341cf6ef..53650026859 100755 --- a/nucleus/admin/template/src/main/resources/docroot/index.html +++ b/nucleus/admin/template/src/main/resources/docroot/index.html @@ -31,14 +31,14 @@

Hello from Payara - your server is now running!

To replace this page, overwrite the file index.html in the document root folder of this server. The document root folder for this server is the docroot subdirectory of this server's domain directory.

-

To manage a server on the local host with the default administration portgo to the Administration Console.

+

To manage a server on the local host with the default administration portgo to the Administration Console.

Payara Server Documentation

-

For more information about Payara Server, documentation and additional resources see the Payara documentation

+

For more information about Payara Server, documentation and additional resources see the Payara documentation

Welcome to the Payara Community

-

As a member of the continuously growing and evolving open source community, you can benefit from some great support offered by other Payara Server users, and get involved yourself by posting feedback on the latest features and enhancements - or by making suggestions for future releases! And if you want to take it one step further, you can also become an official Payara Contributor. If you’d like to be a part of Payara Server's development, or simply get some help and advice from the community, check out our Community page for some useful information and links.

+

As a member of the continuously growing and evolving open source community, you can benefit from some great support offered by other Payara Server users, and get involved yourself by posting feedback on the latest features and enhancements - or by making suggestions for future releases! And if you want to take it one step further, you can also become an official Payara Contributor. If you’d like to be a part of Payara Server's development, or simply get some help and advice from the community, check out our Community page for some useful information and links.

Subscribe to the Payara Tech Blog

-

The Payara Tech Blog is packed with technical articles on Payara Server, Payara Micro, GlassFish, Java EE, Jakarta EE, microservices and more. For some expert hints and tips, demos, overviews and news delivered directly to your inbox, subscribe to the Payara Blog here.

+

The Payara Tech Blog is packed with technical articles on Payara Server, Payara Micro, GlassFish, Java EE, Jakarta EE, microservices and more. For some expert hints and tips, demos, overviews and news delivered directly to your inbox, subscribe to the Payara Blog here.

Are You Running Payara Server in Mission Critical Production Environments?

Payara Server Enterprise supports reliable and secure deployments of Jakarta EE (Java EE) applications in any environment: on premise in the cloud, or hybrid.

Our 10-year software lifecycle ensures longevity of your Payara Server investment.

@@ -51,12 +51,12 @@

Are You Running Payara Server in Mission Critical Production Environments?Migration & Project Support, 24x7, or 10x5 support options included in your Enterprise subscription
  • Delivered by the experienced and dedicated team
  • -

    Learn More About Payara Enterprise or contact the team.

    +

    Learn More About Payara Enterprise or contact the team.

    diff --git a/nucleus/core/kernel/src/main/java/com/sun/enterprise/v3/server/ApplicationLifecycle.java b/nucleus/core/kernel/src/main/java/com/sun/enterprise/v3/server/ApplicationLifecycle.java index b3eb8bcb7cc..f354c1e26f5 100644 --- a/nucleus/core/kernel/src/main/java/com/sun/enterprise/v3/server/ApplicationLifecycle.java +++ b/nucleus/core/kernel/src/main/java/com/sun/enterprise/v3/server/ApplicationLifecycle.java @@ -212,14 +212,7 @@ public class ApplicationLifecycle implements Deployment, PostConstruct { protected Logger logger = KernelLoggerInfo.getLogger(); final private static LocalStringManagerImpl localStrings = new LocalStringManagerImpl(ApplicationLifecycle.class); - private final ThreadLocal> currentDeploymentContext // - = new ThreadLocal>() { - - @Override - protected Deque initialValue() { - return new ArrayDeque<>(5); - } - }; + private final ThreadLocal currentDeploymentContext = new ThreadLocal<>(); protected DeploymentLifecycleProbeProvider deploymentLifecycleProbeProvider = null; @@ -291,7 +284,6 @@ public ApplicationDeployment prepare(Collection sniffers, fin events.send(new Event<>(Deployment.DEPLOYMENT_START, context), false); eventSpan.close(); - currentDeploymentContext.get().push(context); final ActionReport report = context.getActionReport(); final DeployCommandParameters commandParams = context.getCommandParameters(DeployCommandParameters.class); final String appName = commandParams.name(); @@ -358,6 +350,7 @@ public void actOn(Logger logger) { } }; + currentDeploymentContext.set(context); try (DeploymentSpan topSpan = tracing.startSpan(DeploymentTracing.AppStage.PREPARE); SpanSequence span = tracing.startSequence(DeploymentTracing.AppStage.PREPARE, "ArchiveMetadata")) { if (commandParams.origin == OpsParams.Origin.deploy @@ -604,7 +597,7 @@ public void actOn(Logger logger) { if (report.getActionExitCode() != ActionReport.ExitCode.SUCCESS) { context.postDeployClean(false /* not final clean-up yet */); events.send(new Event<>(Deployment.DEPLOYMENT_FAILURE, context)); - currentDeploymentContext.get().pop(); + currentDeploymentContext.remove(); } } ApplicationDeployment depl = new ApplicationDeployment(appInfo, context); @@ -625,6 +618,7 @@ public void initialize(ApplicationInfo appInfo, Collection sn // time the containers are set up, all the modules have been prepared in their // associated engines and the application info is created and registered if (loadOnCurrentInstance(context)) { + currentDeploymentContext.set(context); try (SpanSequence span = tracing.startSequence(DeploymentTracing.AppStage.INITIALIZE)){ notifyLifecycleInterceptorsBefore(ExtendedDeploymentContext.Phase.START, context); appInfo.initialize(); @@ -646,9 +640,9 @@ public void initialize(ApplicationInfo appInfo, Collection sn } else { events.send(new Event<>(Deployment.DEPLOYMENT_SUCCESS, appInfo)); } + currentDeploymentContext.remove(); } } - currentDeploymentContext.get().pop(); } @Override @@ -2713,6 +2707,6 @@ public Thread newThread(Runnable r) { @Override public ExtendedDeploymentContext getCurrentDeploymentContext() { - return currentDeploymentContext.get().peek(); + return currentDeploymentContext.get(); } } diff --git a/nucleus/deployment/common/src/main/java/org/glassfish/deployment/common/DeploymentContextImpl.java b/nucleus/deployment/common/src/main/java/org/glassfish/deployment/common/DeploymentContextImpl.java index 235ecdcc119..573f185fa7a 100644 --- a/nucleus/deployment/common/src/main/java/org/glassfish/deployment/common/DeploymentContextImpl.java +++ b/nucleus/deployment/common/src/main/java/org/glassfish/deployment/common/DeploymentContextImpl.java @@ -289,7 +289,7 @@ public synchronized ClassLoader getClassLoader(boolean sharable) { // return the final classloader if (sharableTemp != null && sharableTemp.get() != cloader) { try { - PreDestroy.class.cast(sharableTemp).preDestroy(); + PreDestroy.class.cast(sharableTemp.get()).preDestroy(); } catch (Exception e) { // ignore, the classloader does not need to be destroyed }