https://grails.org/ logo
Join Slack
Powered by
# questions
  • b

    bilgehan

    04/22/2025, 9:38 AM
    Hi, Just wondering — is https://github.com/Grails-Plugin-Consortium affiliated with the official Grails team? If so, are there any plans to update the plugins for Grails 7? We’re looking to move our Grails 3.3 apps to Grails 7. We rely a lot on SOAP services, and the CXF plugins (both server and client) seem to be the only thing holding us back.
    t
    j
    • 3
    • 4
  • g

    gopichand.bhaskaruni

    04/29/2025, 7:15 PM
    Hello, we are upgrading our project from Grails 5.2.5 to 6.2.3, getting this error while running functional tests, did anyone faced this issue? any solutions?
    Copy code
    Execution failed for task ':citss-web:compileFunctionalTestGroovy'.
    > Unrecoverable compilation error: startup failed:
      General error during instruction selection: java.lang.NoClassDefFoundError: org.openqa.selenium.interactions.HasInputDevices
      
      java.lang.RuntimeException: java.lang.NoClassDefFoundError: org.openqa.selenium.interactions.HasInputDevices
    j
    • 2
    • 6
  • g

    gopichand.bhaskaruni

    05/02/2025, 7:01 PM
    Hi, anyone else facing this issue? the functional tests are also running along with integration tests when I run the integration test command, this is happening after upgrading grails version to 6.2.3, anyone solved this?
    d
    • 2
    • 1
  • p

    pablo.pazos

    05/04/2025, 6:52 PM
    Happy Sunday gents! Quick question: which version of the db-migration plugin should be used for Grails 5.3.3?
    g
    • 2
    • 7
  • p

    pablo.pazos

    05/12/2025, 12:26 AM
    Happy Sunday gents, quick question, for GORM derived properties (https://grails.github.io/legacy-gorm-doc/6.0.x/hibernate/manual/index.html#ormdsl 8.2.11. Derived Properties), does anybody know why they don't work with domain attribute names and instead the actual column names should be used? (e.g. domain fields are camelCase and fields in formulas should be snake_case). Thanks!
    m
    • 2
    • 2
  • u

    user

    05/12/2025, 7:40 AM
    Hi All, I navigated from the grails.org/documentaion.html to the
    Spring Security Core
    link in that page. But when I click on it, I see that it takes me to https://grails.github.io/grails-spring-security-core/ and it shows page not found. Can someone guide me how else can I find the documentation? I found this https://apache.github.io/grails-spring-security/latest/ is this an alternative link?
    j
    u
    u
    • 4
    • 3
  • u

    user

    05/12/2025, 1:48 PM
    Hi All, I apologize if this question has been asked and clarified before, but I was wondering if Grails 6.2.x supports Java 17 or are there some known issues using Java 17 with this version of Grails. Thanks.
    g
    j
    +5
    • 8
    • 8
  • a

    Alex Kramer

    05/12/2025, 8:28 PM
    Has anyone run into an issue with running Intellij and finding that the environment variables that are configured in the Run Configuration are not being passed to the running task? My project is on Grails 4, Gradle Wrapper 5.x.
    j
    d
    • 3
    • 5
  • m

    muser

    05/13/2025, 10:11 AM
    I'm writing here to ask if anyone knows of any Grails project that can be used to create administration panels using current technologies like filamentphp does (https://filamentphp.com/) The thing is that I've been working for a long time with a scaffolding made with Grails 2.5.5, derived from the original scaffolding. I need to abandon it now, due to security issues and obsolete software (jquery, angularjs, java 8...). With the current development that is being done with Grails 7, I think we are experiencing the rebirth of the framework. I am in love with Grails, but... If the framework had a screen builder based on cutting-edge technologies like TailwindCSS, HTMX, AlpineJS... where the screens were defined in a way similar to what Laravel does with FilamentPHP, I think it would be very nice and would attract new developers. If you still don't know what FilamentPHP is, take a look at some videos and the documentation: In English:

    https://www.youtube.com/watch?v=Ai_BlcWzUUQ▾

    In Spanish:

    https://www.youtube.com/watch?v=G8-8z0ThiUE▾

    Official documentation: https://filamentphp.com/docs/3.x/panels/resources/getting-started
    j
    • 2
    • 1
  • j

    jfelrod1960

    05/14/2025, 4:17 PM
    Hey everyone! Is there a more recent book on Grails development? Seems like all the books I'm finding are very old. If not then can you direct me to some good sources on the web. Something other than the Grails home site? I appreciate your time. Thank you!
    j
    j
    +2
    • 5
    • 18
  • u

    user

    05/15/2025, 3:07 PM
    Is there a scheduled posted somewhere for the weekly dev meeting?
    j
    u
    • 3
    • 2
  • p

    pablo.pazos

    05/16/2025, 2:18 AM
    Gents, quick question: I have a fairly simple query withCriteria() but I keep getting empty results. class Version { LocatableIndex data // nullable } class LocatableIndex { LocatableIndexVersioning versioning } class LocatableIndexVersioning { Date validUntil } That's my model (simplified) then I do: Version.withCriteria { or { isNull('data') and { isNotNull('data') data { versioning { gt('validUntil', date_version_at_time) } } } } } Even if I have Version's with null data, I keep receiving null results while I expect those to be part of the result because of the OR isNull('data')
    g
    • 2
    • 8
  • p

    pablo.pazos

    05/16/2025, 2:36 AM
    I have modified the query to get results for the second part of the main OR, and I'm getting all the results, but not the ones that match isNull('data'), I'm not sure but this feels like a bug: Version.withCriteria { or { isNull('data') <<<< match no data and { isNotNull('data') data { versioning { lt('validUntil', date_version_at_time) } } } } }
  • p

    pablo.pazos

    05/16/2025, 2:36 AM
    This is the generated SQL query: select this_.id as id1_63_2_, this_.version as version2_63_2_, this_.byte_size as byte_siz3_63_2_, this_.uid as uid4_63_2_, this_.file_type as file_typ5_63_2_, this_.file_location as file_loc6_63_2_, this_.lifecycle_state as lifecycl7_63_2_, this_.commit_audit_id as commit_a8_63_2_, this_.preceding_version_uid as precedin9_63_2_, this_.contribution_id as contrib10_63_2_, this_.hash as hash11_63_2_, this_.data_id as data_id12_63_2_, data_alias1_.id as id1_42_0_, data_alias1_.version as version2_42_0_, data_alias1_.time_committed as time_com3_42_0_, data_alias1_.last_updated as last_upd4_42_0_, data_alias1_.uid as uid5_42_0_, data_alias1_.data_indexed as data_ind6_42_0_, data_alias1_.template_id as template7_42_0_, data_alias1_.time_created as time_cre8_42_0_, data_alias1_.archetype_id as archetyp9_42_0_, data_alias1_.versioning_id as version10_42_0_, data_alias1_.lname_id as lname_i11_42_0_, data_alias1_.ehr_uid as ehr_uid12_42_0_, data_alias1_.sync_master as sync_ma13_42_0_, data_alias1_2_.end_time as end_time2_9_0_, data_alias1_2_.location as location3_9_0_, data_alias1_2_.subject_id as subject_4_9_0_, data_alias1_2_.start_time as start_ti5_9_0_, data_alias1_2_.category as category6_9_0_, data_alias1_2_.composer_id as composer7_9_0_, data_alias1_3_.source_id as source_i2_54_0_, data_alias1_3_.target_id as target_i3_54_0_, data_alias1_4_.performer_id as performe2_57_0_, data_alias1_5_.actor_type as actor_ty2_1_0_, data_alias1_6_.is_queryable as is_query2_35_0_, data_alias1_6_.is_modifiable as is_modif3_35_0_, data_alias1_6_.subject_id as subject_4_35_0_, data_alias1_7_.parent_id as parent_i2_36_0_, case when data_alias1_1_.id is not null then 1 when data_alias1_2_.id is not null then 2 when data_alias1_3_.id is not null then 3 when data_alias1_4_.id is not null then 4 when data_alias1_5_.id is not null then 5 when data_alias1_6_.id is not null then 6 when data_alias1_7_.id is not null then 7 when data_alias1_.id is not null then 0 end as clazz_0_, versioning2_.id as id1_43_1_, versioning2_.version as version2_43_1_, versioning2_.last_version as last_ver3_43_1_, versioning2_.valid_until as valid_un4_43_1_ from version this_ inner join locatable_index data_alias1_ on this_.data_id=data_alias1_.id left outer join party_identity_index data_alias1_1_ on data_alias1_.id=data_alias1_1_.id left outer join composition_index data_alias1_2_ on data_alias1_.id=data_alias1_2_.id left outer join party_relationship_index data_alias1_3_ on data_alias1_.id=data_alias1_3_.id left outer join role_index data_alias1_4_ on data_alias1_.id=data_alias1_4_.id left outer join actor_index data_alias1_5_ on data_alias1_.id=data_alias1_5_.id left outer join ehr_status_index data_alias1_6_ on data_alias1_.id=data_alias1_6_.id left outer join folder_index data_alias1_7_ on data_alias1_.id=data_alias1_7_.id inner join locatable_index_versioning versioning2_ on data_alias1_.versioning_id=versioning2_.id where ( this_.data_id is null or ( this_.data_id is not null and ( ( versioning2_.valid_until<? ) ) ) )
    s
    p
    • 3
    • 8
  • p

    pablo.pazos

    05/16/2025, 2:36 AM
    Any clues?
  • u

    user

    05/16/2025, 2:22 PM
    I'm new to Grails and I'm curious to know how do you manage CVEs and upgrades to fix them. I'm not even sure this is the right channel to ask this kind of questions. I'm packaging in a Docker container the application my team is developing and the security scanner we use (trivy) reports a few issues. All of those issues are in dependencies and are solved. Even if I'm still learning I'm available to help.
    j
    u
    +6
    • 9
    • 15
  • j

    jeffscottbrown

    05/16/2025, 2:23 PM
    @jeffscottbrown has left the channel
    partygrails 1
  • p

    pablo.pazos

    05/16/2025, 9:41 PM
    Hi all, I did something wrong today in Grails which allowed to revel private info in a REST API. Basically I registered a json marshaller, and used { instead of [, and the whole application, configuration, environment variables, etc was printed out as JSON.
    Copy code
    it.registerObjectMarshaller(AuditDetails) { audit ->
                def a = [
                   system_id: audit.systemId,
                   committer: audit.committer, // PartyProxy
                   time_committed: {
                      value: audit.timeCommitted
                   }
                ]
                if (audit.changeType) a << [changeType: audit.changeType.toString()] // TODO: transform to coded text
                return a
             }
    that printed EVERYTHING out!
    Copy code
    "time_committed": {
    			"audit": {
    				"_ref": "../..",
    				"class": "com.cabolabs.ehrserver.openehr.common.generic.AuditDetails$HibernateProxy$quMc648M"
    			},
    			"delegate": {
    				"delegate": {
    					"delegate": {
    						"PS": "/",
    						"configurationService": {
    							"applicationContext": {
    								"active": true,
    								"applicationListeners": [ ....
  • p

    pablo.pazos

    05/16/2025, 9:42 PM
    When I say everything I mean everything! all classes, all internal stuff like controllers, services, ...
  • p

    pablo.pazos

    05/16/2025, 9:43 PM
    that small typo can actually wreak havoc
    j
    • 2
    • 3
  • r

    rss

    05/19/2025, 5:44 PM
    Why Grails Spring Security validation and logout filter always applies? I'm using Grails 6.2.0 with the Spring Security Core 6.1.2 and Spring Security Rest 5.0.0 plugins. I configured the filters as recommended in the documentation (or at least how I understood it): grails.plugin.springsecurity.filterChain.chainMap = [ // public endpoints [pattern: "/api/register", filters: 'none'], [pattern: "/api/public/**",...
  • a

    Alex Z.

    05/21/2025, 2:23 AM
    What happened with the OAuth Provider plugin? I’m upgrading from Grails 4 to 6 and realizing that there is nothing to upgrade the plugin to and nothing to replace it with. Is this true or am I missing something?
    s
    j
    • 3
    • 8
  • r

    rss

    05/28/2025, 3:04 AM
    Handle request with .gsp in URL In Grails 6.2.3, I have to handle request with .gsp extension like http://localhost:8080/report/view.gsp?a=b I can't map this URL to controller, action. It will always return error 404. I test URL with many other extensions and they are all work without any modification to UrlMappings.groovy. For example http://localhost:8080/report/view.gspx?a=b http://localhost:8080/report/view.abc http://localhost:8080/report/view.xyz This question suggests it should work, but it from Grails-3.3. <a...
  • u

    user

    05/29/2025, 12:04 PM
    Hi All, I created a new DomainClass that looks like this,
    Copy code
    class Node {
    	UUID id
        String anotherId
    
        static belongsTo = [Parent: parent]
    }
    and when I do
    findByAnotherId(String anotherId)
    it fails with
    org.hibernate.QueryException: could not resolve property: name of: com.example.cs.Node
    But when I add another field to the domain with
    String Name
    everything seems to work fine. Why is that so? Is this expected behaviour that all domain classes must have a name?
    m
    u
    +3
    • 6
    • 6
  • s

    spencer

    05/29/2025, 8:31 PM
    Is anyone using OpenID Connect with Grails 5 or 6? It's not completely clear in the documentation or examples if the current Grails Spring Security Plugin's oauth2 support will work with OIDC or not. The ReadMe linked here https://github.com/apache/grails-spring-security/blob/7.0.x/plugin-oauth2/README.md reference a 7 year old Okta (who we happen to be using) demo project. Before I spend time trying this, has anyone had success with OIDC?
  • p

    pablo.pazos

    05/30/2025, 11:24 PM
    @jdaugherty is there any reason why the v7.0.0-M4 was updated multiple times on GitHub? Shouldn't it be M5, M6 etc?
    j
    p
    • 3
    • 8
  • p

    pablo.pazos

    06/02/2025, 9:31 PM
    gents, quick question, I was checking if it was possible to manage postgres patitions in gorm and stumbled upon this unmaintained plugin https://github.com/gpc/grails-postgresql-extensions . Is there any desire to maintain it in the future?
    j
    s
    • 3
    • 4
  • t

    thomassd

    06/02/2025, 10:33 PM
    It was a handy plugin; I used it years ago to leverage the PostGIS extension in a mapping application.
  • u

    user

    06/04/2025, 3:57 PM
    Mixing Springboot components in a Grails application: We have a legacy Grails application of significant size using Grails 6.2.x and Java 17. We are trying to convert this application into a Springboot application (rest of our applications are all Springboot, this being the only exception). The approach we are thinking of taking is to incrementally do this conversion. So take one or two Grails controllers and services at a time and convert them into Springboot. And we are hoping that we would be able to run the application as a mix of the two for a while until we complete this conversion. I was wondering if anyone else here has the experience of converting a Grails application into a Springboot application and can share their wisdom/learnings etc. Thanks.
    u
    j
    u
    • 4
    • 4
  • p

    pablo.pazos

    06/06/2025, 9:41 PM
    Good evening! I have a question about improving this exception:
    Copy code
    org.springframework.orm.hibernate5.HibernateSystemException: The EntityInsertAction was vetoed.; nested exception is org.hibernate.action.internal.EntityActionVetoException: The EntityInsertAction was vetoed.
    That happens in Grails 5 when a domain instance is saved but an associated instance didn't validate. The weird thing is that instead of getting a Grails/GORM validation exception, we get an exception from Hibernate that doesn't help much to telling the dev what's going on. This happens to me from time to time and I continue finding the same question again and again on SO https://stackoverflow.com/questions/73624214/entityactionvetoexception-the-entityinsertaction-was-vetoed/79656508#79656508 Wouldn't it be better that Grails/GORM catches that and re-throws a validation exception telling the dev which instance in which associations isn't valid and maybe including where that's not valid? (like null value on a nullable:false field, etc). An alternative would be to add this to every controller, maybe adding the instance.errors.allErrors to the exception
    def handleVetoed (HibernateSystemException e)
    {
    throw new ValidationException(e)
    }