[google-appengine] Re: How to change the version of Jetty in my Google App Engine

2022-07-28 Thread 'Andrés Márquez' via Google App Engine


To update the Jetty version to the latest one, I would suggest updating the 
Cloud SDK to the latest version. Based on the documentation [1], the most 
recent release of Cloud SDK is version 395.0.0 (2022-07-26) and according 
to the release notes [2], the latest Java SDK version is 1.9.98 and latest 
Jetty version is 11.0.11[3]

I would recommend trying to upgrade the Cloud SDK by following this 
documentation [4] so the Jetty version is updated to the latest one.

[1] https://cloud.google.com/sdk/docs/release-notes

[2] https://cloud.google.com/appengine/docs/standard/java/release-notes
[3] https://www.eclipse.org/jetty/download.php

[4] https://cloud.google.com/sdk/docs/components#updating_components

On Thursday, July 28, 2022 at 11:35:33 AM UTC-5 
mwal...@bluesparktechnologies.com wrote:

> Within IntelliJ I have a Google App Engine Standard Local Server running. 
> I'm in the process of updating to Java 17 and also all of my 3rd party 
> libraries and have moved to GAE 2.0.5 and Jetty 11.0.11 in all of my 
> project's pom files. However, when I start up the server I see: 
>
> INFO:oejs.Server:main: jetty-9.4.46.v20220331 
>
> and I'm getting failures that seem to confirm the above, that an older 
> version of Jetty is being used. Where can I update the Jetty version that 
> the app engine uses? 
>
> Here's the stack trace. The latest versions should be using 
> jakarta.ws.rs.Path instead of javax.
>
> java.lang.TypeNotPresentException: Type javax.ws.rs.Path not present at 
> java.base/sun.reflect.annotation.TypeNotPresentExceptionProxy.generateException(TypeNotPresentExceptionProxy.java:47)
>  
> at 
> java.base/sun.reflect.annotation.AnnotationInvocationHandler.invoke(AnnotationInvocationHandler.java:89)
>  
> at jdk.proxy2/jdk.proxy2.$Proxy2.value(Unknown Source) at 
> org.eclipse.jetty.annotations.AnnotationConfiguration.createServletContainerInitializerAnnotationHandlers(AnnotationConfiguration.java:579)
>  
> at 
> org.eclipse.jetty.annotations.AnnotationConfiguration.configure(AnnotationConfiguration.java:343)
>  
> at org.eclipse.jetty.webapp.WebAppContext.configure(WebAppContext.java:498) 
> at 
> org.eclipse.jetty.webapp.WebAppContext.startContext(WebAppContext.java:1409) 
> at 
> org.eclipse.jetty.server.handler.ContextHandler.doStart(ContextHandler.java:916)
>  
> at 
> org.eclipse.jetty.servlet.ServletContextHandler.doStart(ServletContextHandler.java:288)
>  
> at org.eclipse.jetty.webapp.WebAppContext.doStart(WebAppContext.java:524) 
> at 
> org.eclipse.jetty.util.component.AbstractLifeCycle.start(AbstractLifeCycle.java:73)
>  
> at 
> org.eclipse.jetty.util.component.ContainerLifeCycle.start(ContainerLifeCycle.java:169)
>  
> at 
> org.eclipse.jetty.util.component.ContainerLifeCycle.doStart(ContainerLifeCycle.java:110)
>  
> at 
> org.eclipse.jetty.server.handler.AbstractHandler.doStart(AbstractHandler.java:97)
>  
> at 
> org.eclipse.jetty.util.component.AbstractLifeCycle.start(AbstractLifeCycle.java:73)
>  
> at 
> org.eclipse.jetty.util.component.ContainerLifeCycle.start(ContainerLifeCycle.java:169)
>  
> at org.eclipse.jetty.server.Server.start(Server.java:423) at 
> org.eclipse.jetty.util.component.ContainerLifeCycle.doStart(ContainerLifeCycle.java:110)
>  
> at 
> org.eclipse.jetty.server.handler.AbstractHandler.doStart(AbstractHandler.java:97)
>  
> at org.eclipse.jetty.server.Server.doStart(Server.java:387) at 
> org.eclipse.jetty.util.component.AbstractLifeCycle.start(AbstractLifeCycle.java:73)
>  
> at 
> com.google.appengine.tools.development.jetty9.JettyContainerService.startContainer(JettyContainerService.java:366)
>

-- 
You received this message because you are subscribed to the Google Groups 
"Google App Engine" group.
To unsubscribe from this group and stop receiving emails from it, send an email 
to google-appengine+unsubscr...@googlegroups.com.
To view this discussion on the web visit 
https://groups.google.com/d/msgid/google-appengine/5d2c976c-3fd4-4286-8f82-0154ab7cf704n%40googlegroups.com.


[google-appengine] Can a single App Engine Standard Java 11/17 web process handle multiple concurrent requests?

2022-07-28 Thread William Linna
Hello,

I'm using App Engine Standard with Java 11. My app is packaged as a JAR and 
it doesn't use legacy bundled services. I have set manual scaling to 1. Now 
my question is can that one instance handle multiple concurrent requests? 
According to the documentation, it seems like it cannot.

https://cloud.google.com/appengine/docs/standard/java-gen2/how-requests-are-handled

   - By default, each web server processes only one request at a time. To 
   dispatch multiple requests to each web server in parallel, mark your 
   application as threadsafe by adding a true 
   

 
   element to your appengine-web.xml file.

However, that appengine-web.xml only appears in examples with legacy 
bundled services. I haven't seen any documentation on how to set up 
appengine-web.xml for JAR-packaged apps, only for WAR-packaged apps. 
manual_scaling doesn't allow setting max_concurrent_requests either. 
app.yaml doesn't support threadsafe-setting.

This is different from envs such as PHP and Go where docs explicitly state 
that "An instance can handle multiple requests concurrently.".

What should I do? I can't use multiple instances, because I depend on a 
little bit of state, which is what manual scaling is supposed to afford me.

   - Instances remain in memory and state is preserved across requests. 

-- 
You received this message because you are subscribed to the Google Groups 
"Google App Engine" group.
To unsubscribe from this group and stop receiving emails from it, send an email 
to google-appengine+unsubscr...@googlegroups.com.
To view this discussion on the web visit 
https://groups.google.com/d/msgid/google-appengine/87e34e4f-faa1-4246-afab-e731a69b5df1n%40googlegroups.com.


[google-appengine] Re: Traffic hitting deleted Google App Engine versions

2022-07-28 Thread 'Richard Garbutt' via Google App Engine
To be clear:

> This project only has one service with one version and two instances

The problem is traffic *hitting versions that have been deleted*

We are migrating away from App Engine due to this issue.
On Wednesday, 27 July 2022 at 00:02:01 UTC+1 Osvaldo Lopez Acuña wrote:

> You could report this issue here[1]. You could also make sure you deleted 
> those versions[2]. Take a look at this post[3] where it is explained how to 
> clean up an App Engine project.
>
> [1]:https://issuetracker.google.com/issues/new?component=187191
>
> [2]:https://cloud.google.com/sdk/gcloud/reference/app/versions/delete
> [3]:
> https://medium.com/google-cloud/app-engine-project-cleanup-9647296e796a  
>
> On Tuesday, July 26, 2022 at 11:46:20 AM UTC-5 ric...@getregistered.com 
> wrote:
>
>> Hi All,
>>
>> We're seeing some very strange behaviour with error reporting showing 
>> traffic sporadically hitting a deleted version of the application. It seems 
>> like around 25% of requests hit this incorrect, phantom instance.
>>
>> To be specific we are running a rails application and we are seeing 
>> errors consistent with a previous version of `schema.rb` being loaded by 
>> the application.
>>
>> We build and deploy fresh docker containers for each deployment using 
>> cloudbuild.
>>
>> This project only has one service with one version and two instances. The 
>> last deployment was five days ago and we are still seeing errors.
>>
>> Has anyone encountered something similar? This really seems like an issue 
>> with App Engine routing to stale instances.
>>
>> Regards,
>>
>> Richard Garbutt
>>
>

-- 
You received this message because you are subscribed to the Google Groups 
"Google App Engine" group.
To unsubscribe from this group and stop receiving emails from it, send an email 
to google-appengine+unsubscr...@googlegroups.com.
To view this discussion on the web visit 
https://groups.google.com/d/msgid/google-appengine/d35dfbd4-f57b-4a6d-8281-ecab5126eb3cn%40googlegroups.com.


[google-appengine] How to change the version of Jetty in my Google App Engine

2022-07-28 Thread 'Mike Wallace' via Google App Engine


Within IntelliJ I have a Google App Engine Standard Local Server running. 
I'm in the process of updating to Java 17 and also all of my 3rd party 
libraries and have moved to GAE 2.0.5 and Jetty 11.0.11 in all of my 
project's pom files. However, when I start up the server I see: 

INFO:oejs.Server:main: jetty-9.4.46.v20220331 

and I'm getting failures that seem to confirm the above, that an older 
version of Jetty is being used. Where can I update the Jetty version that 
the app engine uses? 

Here's the stack trace. The latest versions should be using 
jakarta.ws.rs.Path instead of javax.

java.lang.TypeNotPresentException: Type javax.ws.rs.Path not present at 
java.base/sun.reflect.annotation.TypeNotPresentExceptionProxy.generateException(TypeNotPresentExceptionProxy.java:47)
 
at 
java.base/sun.reflect.annotation.AnnotationInvocationHandler.invoke(AnnotationInvocationHandler.java:89)
 
at jdk.proxy2/jdk.proxy2.$Proxy2.value(Unknown Source) at 
org.eclipse.jetty.annotations.AnnotationConfiguration.createServletContainerInitializerAnnotationHandlers(AnnotationConfiguration.java:579)
 
at 
org.eclipse.jetty.annotations.AnnotationConfiguration.configure(AnnotationConfiguration.java:343)
 
at org.eclipse.jetty.webapp.WebAppContext.configure(WebAppContext.java:498) 
at 
org.eclipse.jetty.webapp.WebAppContext.startContext(WebAppContext.java:1409) 
at 
org.eclipse.jetty.server.handler.ContextHandler.doStart(ContextHandler.java:916)
 
at 
org.eclipse.jetty.servlet.ServletContextHandler.doStart(ServletContextHandler.java:288)
 
at org.eclipse.jetty.webapp.WebAppContext.doStart(WebAppContext.java:524) 
at 
org.eclipse.jetty.util.component.AbstractLifeCycle.start(AbstractLifeCycle.java:73)
 
at 
org.eclipse.jetty.util.component.ContainerLifeCycle.start(ContainerLifeCycle.java:169)
 
at 
org.eclipse.jetty.util.component.ContainerLifeCycle.doStart(ContainerLifeCycle.java:110)
 
at 
org.eclipse.jetty.server.handler.AbstractHandler.doStart(AbstractHandler.java:97)
 
at 
org.eclipse.jetty.util.component.AbstractLifeCycle.start(AbstractLifeCycle.java:73)
 
at 
org.eclipse.jetty.util.component.ContainerLifeCycle.start(ContainerLifeCycle.java:169)
 
at org.eclipse.jetty.server.Server.start(Server.java:423) at 
org.eclipse.jetty.util.component.ContainerLifeCycle.doStart(ContainerLifeCycle.java:110)
 
at 
org.eclipse.jetty.server.handler.AbstractHandler.doStart(AbstractHandler.java:97)
 
at org.eclipse.jetty.server.Server.doStart(Server.java:387) at 
org.eclipse.jetty.util.component.AbstractLifeCycle.start(AbstractLifeCycle.java:73)
 
at 
com.google.appengine.tools.development.jetty9.JettyContainerService.startContainer(JettyContainerService.java:366)

-- 
You received this message because you are subscribed to the Google Groups 
"Google App Engine" group.
To unsubscribe from this group and stop receiving emails from it, send an email 
to google-appengine+unsubscr...@googlegroups.com.
To view this discussion on the web visit 
https://groups.google.com/d/msgid/google-appengine/3ec6a90b-9617-480e-9771-3a39f941c576n%40googlegroups.com.


[google-appengine] Re: gcloud auth login fails

2022-07-28 Thread solsTiCe d'Hiver

Out of dispair and boredom, I tried a few things, and finally I just 
changed the language in the login page where you accept the Google Cloud 
SDK permissions. I changed it to english (UK);

I was, then, instantaltly logged in.

WTF !
Le mercredi 27 juillet 2022 à 19:06:37 UTC+2, solsTiCe d'Hiver a écrit :

>
> I don't have an admin at end. I odn't have any admin t perform those steps.
>
> Because like I said, I am just a lambda user of Google App Engine 
> (free-tier mostly). meaning, no entreprise or organisation, just me.
> Le mercredi 27 juillet 2022 à 19:00:07 UTC+2, concep...@google.com a 
> écrit :
>
>>
>> Please ask your admin to perform those steps.
>> On Monday, July 25, 2022 at 6:14:06 PM UTC-5 solstic...@gmail.com wrote:
>>
>>>
>>> Previously, I had a free Google Workspace account, and that's why it 
>>> might have worked.
>>> Since, free Google Workspace was ended, I terminated that account. It 
>>> was linked to my main gmail address.
>>>
>>> If I try to follow the tutorial in the link you gave, I have to login 
>>> with an admin account. It seems I don't have any, do I?
>>> Le mardi 26 juillet 2022 à 00:59:36 UTC+2, concep...@google.com a 
>>> écrit :
>>>
 For each organizational unit, there can only be one active enrollment 
 token. If you need to pause enrollment, you can permanently revoke the 
 token for a specific organizational unit and regenerate a new one.


 https://support.google.com/chrome/a/answer/9301891#zippy=%2Crevoke-and-regenerate-enrollment-token:~:text=For%20each%20organizational%20unit%2C%20there%20can%20only%20be%20one%20active%20enrollment%20token.%20If%20you%20need%20to%20pause%20enrollment%2C%20you%20can%20permanently%20revoke%20the%20token%20for%20a%20specific%20organizational%20unit%20and%20regenerate%20a%20new%20one
 .

 On Friday, July 22, 2022 at 4:52:59 AM UTC-5 solstic...@gmail.com 
 wrote:

> Hi,
> I mistakingly removed my gcloud config, and token/cookies on my 
> desktop. Private user here;
>
> Now, I can't `gcloud auth login` anymore with my default gmail account.
> I got an error at the last step of authentification "an error occured".
>
> I have to use the default account for each project. This is annoying.
>
> Why ?  Why do I do wrong ? Is it a feature ?
>
> Thanks
>


-- 
You received this message because you are subscribed to the Google Groups 
"Google App Engine" group.
To unsubscribe from this group and stop receiving emails from it, send an email 
to google-appengine+unsubscr...@googlegroups.com.
To view this discussion on the web visit 
https://groups.google.com/d/msgid/google-appengine/e93b4783-67a1-4951-bd83-76972bf8730bn%40googlegroups.com.