gradlew appengineUpdate not working anymore

76 views
Skip to first unread message

Serge Rehem

unread,
Sep 18, 2020, 4:57:06 PM9/18/20
to Gaelyk
Hi,

The command gradlew appengineUpdate seems to not be working anymore,

This is the error message:
Application deployment failed. Message: Deployments using appcfg are no longer supported. See https://cloud.google.com/appengine/docs/deprecations

I tried use gcloud app deploy, but got another error message:
ERROR: (gcloud.app.deploy) Gradle source deployment is not supported for Java8 GAE project.

Do you have plans to fix gradlew file? (I have an web app with some paying customers using Gaelyk at geradordecertificados.com)

Here my build.gradle file:
apply plugin: 'war'
apply plugin: 'gaelyk'
apply plugin: 'appengine-geb'

def compatibilityVersion = 1.8
sourceCompatibility = compatibilityVersion
targetCompatibility = compatibilityVersion

buildscript {
    repositories {
        maven {
maven {
//mavenCentral()
        //jcenter()
    }

    dependencies {
        classpath 'org.gradle.api.plugins:gradle-gaelyk-plugin:0.6'
        classpath 'org.gradle.api.plugins:gradle-appengine-geb-plugin:0.4'
    }
}

repositories {
maven {
maven {
    //mavenCentral()
    //jcenter()
}

appcfg {
    oauth2 = true
}

dependencies {
appengineSdk 'com.google.appengine:appengine-java-sdk:1.9.59'

    def gaeVersion = '1.9.64'
    def groovyVersion = '2.4.15'

    compile "org.codehaus.groovy:groovy-all:${groovyVersion}"

    compile files("lib/appengine-api-1.0-sdk-1.9.64.jar")apply plugin: 'war'
apply plugin: 'gaelyk'
apply plugin: 'appengine-geb'

def compatibilityVersion = 1.8
sourceCompatibility = compatibilityVersion
targetCompatibility = compatibilityVersion

buildscript {
    repositories {
        maven {
maven {
//mavenCentral()
        //jcenter()
    }

    dependencies {
        classpath 'org.gradle.api.plugins:gradle-gaelyk-plugin:0.6'
        classpath 'org.gradle.api.plugins:gradle-appengine-geb-plugin:0.4'
    }
}

repositories {
maven {
maven {
    //mavenCentral()
    //jcenter()
}

appcfg {
    oauth2 = true
}

dependencies {
appengineSdk 'com.google.appengine:appengine-java-sdk:1.9.59'

    def gaeVersion = '1.9.64'
    def groovyVersion = '2.4.15'

    compile "org.codehaus.groovy:groovy-all:${groovyVersion}"

    compile files("lib/appengine-api-1.0-sdk-1.9.64.jar") // need to provide sdk localy
    compile "com.google.appengine:appengine-api-labs:$gaeVersion"

    compile "com.google.appengine.tools:appengine-gcs-client:0.7"

    compile 'org.sitemesh:sitemesh:3.0.1'

    compile 'org.gaelyk:gaelyk:2.2.0'

    compile "org.apache.pdfbox:pdfbox:1.8.7"

    compile "com.madgag.spongycastle:core:1.50.0.0"

compile "joda-time:joda-time:2.10"

compile 'com.sendgrid:sendgrid-java:2.0.0'

    compile "com.xlson.groovycsv:groovycsv:1.3"

compile files("lib/itextg-5.5.10.jar")
    compile files("lib/pkix-1.52.0.0.jar")
    compile files("lib/prov-1.52.0.0.jar")

    testCompile 'org.gaelyk:gaelyk-spock:0.4'
    testCompile "com.google.appengine:appengine-api-stubs:$gaeVersion",
            "com.google.appengine:appengine-testing:$gaeVersion"

    functionalTestCompile 'org.seleniumhq.selenium:selenium-firefox-driver:2.40.0'
    functionalTestCompile 'org.gebish:geb-spock:0.9.2'

    appengineSdk "com.google.appengine:appengine-java-sdk:$gaeVersion"
    compile "com.google.appengine:appengine-api-labs:$gaeVersion"

    compile "com.google.appengine.tools:appengine-gcs-client:0.7"

    compile 'org.sitemesh:sitemesh:3.0.1'

    compile 'org.gaelyk:gaelyk:2.2.0'

    compile "org.apache.pdfbox:pdfbox:1.8.7"

    compile "com.madgag.spongycastle:core:1.50.0.0"

compile "joda-time:joda-time:2.10"

compile 'com.sendgrid:sendgrid-java:2.0.0'

    compile "com.xlson.groovycsv:groovycsv:1.3"

compile files("lib/itextg-5.5.10.jar")
    compile files("lib/pkix-1.52.0.0.jar")
    compile files("lib/prov-1.52.0.0.jar")

    testCompile 'org.gaelyk:gaelyk-spock:0.4'
    testCompile "com.google.appengine:appengine-api-stubs:$gaeVersion",
            "com.google.appengine:appengine-testing:$gaeVersion"

    functionalTestCompile 'org.seleniumhq.selenium:selenium-firefox-driver:2.40.0'
    functionalTestCompile 'org.gebish:geb-spock:0.9.2'

    appengineSdk "com.google.appengine:appengine-java-sdk:$gaeVersion"
}

-------------------------------------------
and here my appengine-web.xml:
<appengine-web-app xmlns="http://appengine.google.com/ns/1.0">
    <application>geradordecertificado</application>
    
    <version>v13</version>

  <runtime>java8</runtime>

    <!-- Enable concurrent requests by default to serve requests in parallel -->
    <threadsafe>true</threadsafe>

    <!-- If all your templates and groovlets are encoding in UTF-8 -->
    <!-- Please specify the settings below, otherwise weird characters may appear in your templates -->
    <system-properties>
        <property name="file.encoding" value="UTF-8"/>
        <property name="groovy.source.encoding" value="UTF-8"/>
        <property name="java.util.logging.config.file" value="WEB-INF/logging.properties" />
    </system-properties>

    <!-- Uncomment this section if you want your application to be able to receive XMPP messages -->
    <!-- And create a file named jabber.groovy in /WEB-INF/groovy -->
    <!-- Similarily, if you want to receive incoming emails -->
    <!-- And create a file named email.groovy in /WEB-INF/groovy -->
    <!--
    <inbound-services>
        <service>xmpp_message</service>
        <service>mail</service>
    </inbound-services>
    -->

    <!-- It it advised to keep this parameter to true -->
    <!-- as per the release of SDK 1.2.8, -->
    <!-- this should speed up cold startups of applications by 10% -->
    <precompilation-enabled>true</precompilation-enabled>
    
    <static-files>
        <exclude path="/WEB-INF/**.groovy" />
        <exclude path="**.gtpl" />
    </static-files>
    
    <sessions-enabled>true</sessions-enabled>
</appengine-web-app>

Thanks, 
Serge

Guillaume Laforge

unread,
Sep 19, 2020, 4:59:59 AM9/19/20
to gae...@googlegroups.com
Hi Serge,

To be honest, Gaelyk isn't maintained anymore (at least, it hasn't been in a while).
Did you try updating the various plugin versions already?

Guillaume

--
--
You've received this message because you've subscribed to the Gaelyk Google Group.
To send an email to the group, please write to: gae...@googlegroups.com
To unsuscribe from this group: gaelyk+un...@googlegroups.com
To show more options: http://groups.google.fr/group/gaelyk?hl=en

---
You received this message because you are subscribed to the Google Groups "Gaelyk" group.
To unsubscribe from this group and stop receiving emails from it, send an email to gaelyk+un...@googlegroups.com.
To view this discussion on the web visit https://groups.google.com/d/msgid/gaelyk/80c9b87b-5e8a-4e5a-bc5e-923684265235n%40googlegroups.com.


--
Guillaume Laforge
Apache Groovy committer
Developer Advocate @ Google Cloud Platform

Wilson MacGyver

unread,
Sep 19, 2020, 12:54:38 PM9/19/20
to gae...@googlegroups.com
But Gaelyk is still very functional for us :) at least till we stop using app engine one day 

--
Omnem crede diem tibi diluxisse supremum.

Guillaume Laforge

unread,
Sep 19, 2020, 1:01:39 PM9/19/20
to gae...@googlegroups.com
It didn't even need maintenance since it's been working so far 😆

Vladimír Oraný

unread,
Sep 19, 2020, 2:26:42 PM9/19/20
to Gaelyk, Scott Murphy
Try to ask Scott Murphy (in copy), the current maintainer. He might face the same issue as you.

V

Dne so 19. zář 2020 19:01 uživatel Guillaume Laforge <glaf...@gmail.com> napsal:

Kunal Dabir

unread,
Sep 21, 2020, 9:50:18 AM9/21/20
to Gaelyk
That's great to know. Your blog used to run on it right? 

I think the tooling changes for app-engine may cause some issues. I have not checked recently :(

Great to see replies from you and Vladimir :)

Guillaume Laforge

unread,
Sep 21, 2020, 9:57:49 AM9/21/20
to gae...@googlegroups.com
My blog still runs on / with Gaelyk :-)
But I haven't redeployed it in a while, so haven't experienced the problem below.

Serge Rehem

unread,
Sep 22, 2020, 8:47:05 AM9/22/20
to Gaelyk
Ok, i made it work. I don't know if it the best way, but done is better then perfect.

I used gradlew appengineRun and copied all jar files inside explodedApp ... WEB-INF/lib folder to /src/main/webapp/WEB-INF/lib. 
Without it, I had some gae ClassNotFoundException.

To deploy, instead of gradlew appengineUpdate, I used:
gcloud app deploy ./src/main/webapp/WEB-INF/appengine-web.xml --version=v13 --no-promote 

I also needed to convert* datastore-indexes.xml to index.yaml and run:
gcloud app deploy index.yaml  

I hope this register can help some of you to deploy your gaeylk apps next time.

[]s
Serge


----
Here's my build.gradlew:
apply plugin: 'war'
apply plugin: 'gaelyk'
apply plugin: 'appengine-geb'

def compatibilityVersion = 1.8
sourceCompatibility = compatibilityVersion
targetCompatibility = compatibilityVersion

buildscript {
repositories {
maven {
            url "https://repo1.maven.org/maven2/"
        }
        maven {
            url "https://jcenter.bintray.com/"
        }
}

dependencies {
classpath 'org.gradle.api.plugins:gradle-gaelyk-plugin:0.6'
classpath 'org.gradle.api.plugins:gradle-appengine-geb-plugin:0.4'
}
}

repositories {
    maven {
        url "https://repo1.maven.org/maven2/"
    }
    maven {
        url "https://jcenter.bintray.com/"
    }
}

appcfg {
oauth2 = true
}

dependencies {
def gaeVersion = '1.9.64'
def groovyVersion = '2.4.15'

compile "org.codehaus.groovy:groovy-all:${groovyVersion}"

compile files("lib/appengine-api-1.0-sdk-${gaeVersion}.jar")
compile files("lib/appengine-api-labs:${gaeVersion}.jar")
compile files("lib/gaelyk-2.2.0.jar")

compile "com.google.appengine.tools:appengine-gcs-client:0.7"

compile 'org.sitemesh:sitemesh:3.0.1'

Alan Rodrigues

unread,
Oct 29, 2020, 3:14:10 PM10/29/20
to Gaelyk
Hello Serge
Your tips helped me, i updated the app successfuly.
But i'm getting the error below when hitting the app:
javax.servlet.UnavailableException: Closs loading error for holder
The error show for classes that sit at app_root/src/main/groovy/packge_structure.../FilterX
I had to put filters there for some reason that i don't recall now, but it always worked fine.
If i move the filters to app_root/src/main/webapp/WEB-INF/groovy, it doesn't work, i get the same error on dev mode then.
It seems to me the command gcloud leaves out that directory for classes that previsouly where going in when using gradle appengineUpdate command.
Any tips on how to resolve this?

Alan Rodrigues

unread,
Oct 29, 2020, 4:08:02 PM10/29/20
to Gaelyk
I just want to say i fixed it by generating a jar file of the classes in that directory and sitting it on the lib directory.
Error gone, classes were there, though my environment is a bit fragile now, because i need to remember to keep the jar updated manually.
But anyhow, working is better then any other

Reply all
Reply to author
Forward
0 new messages