Yet another "File Name Too Long" workaround :-(
Normal day - was just gonna add one more check to my nice .where{} closure. But when I did, everything blew up in my face - and I'm sitting here with no eyebrows.The file will no longer compiles!
#grails test-app
/home/finn/src/stratos/stratos/target/classes/no/nsb/stratos/MyService$_updateAllWithChanges_closure5_closure7_closure8_closure9_closure10_closure12_closure14_closure16.class (File name too long)
When I commented back in the validTo everything went melt-down.
List
status.ok==false &&
status.validFrom <= new Date() &&
status.station != null &&
channelCode=="FOO" &&
language == "eng"
}.list()
I can't figure out why this happens! The filename isn't over the Linux file length limit.
List<DistributionText> gsmList = DistributionText.createCriteria().list {
status {
eq("enabled", true)
eq("ok", false)
le("validFrom", new Date())
ge("validTo", new Date())
isNotNull("station")
}
eq("channelCode", "FOO")
eq("language", "eng")
}
I kinda like better the Groovy DSL/where to this Hibernate syntax, so if you find out how to get around the File Name Too Long, please leave a comment.
I would recommend you to try Long Path Tool program to fix this problem
ReplyDelete