Hi,
I think I’m missing something fundamental.
I’ve created myself an interceptor “preProcess” to check for security credentials which then:
setNextEvent( event=“security.login”, prePostExempt=true)
…and displays a login page.
When a login is attempted (again by my “preProcess” interceptor), this leads to:
runEvent( event=“security.loginattempt”);
The loginAttempt function, then performs the check:
prc.User = UserService.newCriteria().isTrue(“Active”).eq(“Username”,rc._username).eq(“Password”,rc._password).get();
This all appears to be operating correctly
[However, at this point I would like to say, please let me know anything that’s incorrect.]
I then prepare a non-ORM model called AJAXReturn (essentially just a structure) to send the details back to the browser in a standard form. In this instance, I don’t actually want to send the user details back to the browser - I just want to test the technique of loading data coming from a query into a structure and returning it.
However, prc.User seems to be far too big - Java heap error. This seems to be true as the log shows that serialize(prc.User) contains an property called “”$FORMATTER_CUSTOM"" which starts a very long string:
“”$FORMATTER_CUSTOM"":evaluateJava("“rO0ABXNyABpqYXZhLnRleHQuU2ltcGxlRGF0ZUZvcm1hdEJDydqTlDWQAgAFSQAVc2VyaWFsVmVyc2lvbk9uU3RyZWFtTAATZGVn…”
My first idea was to create a User.cfc and copy all the relevant variables across from prc.User. But I didn’t think there was any need for this, when using the Virtual Service layer.
Any suggestions - or is this completely the wrong tree to be barking up?
AJAXReturn.cfc (816 Bytes)
security.cfc (2.98 KB)
BaseEntity.cfc (785 Bytes)
UserService.cfc (1.04 KB)