Skip to end of metadata
Go to start of metadata

You are viewing an old version of this page. View the current version.

Compare with Current View Page History

« Previous Version 18 Current »

[11:58:46 CDT(-0500)] <fairwinds> serac: hi
[11:58:53 CDT(-0500)] <serac> howdy
[11:59:21 CDT(-0500)] <fairwinds> serac: I have a question about bean initialization and properties
[11:59:32 CDT(-0500)] <serac> shoot
[12:01:11 CDT(-0500)] <fairwinds> k, what I am finding is that if I call a bean within the initialization of another bean I will get a null pointer error
[12:01:43 CDT(-0500)] <serac> Got some source to share?
[12:01:55 CDT(-0500)] <fairwinds> serac: yup. give me a sec to paste something
[12:08:08 CDT(-0500)] <fairwinds> serac: https://gist.github.com/a629b86d095547db5b31
[12:08:24 CDT(-0500)] <fairwinds> serac: I will paste my config
[12:08:54 CDT(-0500)] <serac> Where are you referencing other components in that source that would cause NPE?
[12:08:56 CDT(-0500)] <serac> cf line #
[12:09:32 CDT(-0500)] <fairwinds> just a sec I will get config up so you can see
[12:10:56 CDT(-0500)] <fairwinds> https://gist.github.com/8c502eaeba246c794951
[12:11:09 CDT(-0500)] <fairwinds> one more, give me one more sec
[12:12:36 CDT(-0500)] <fairwinds> https://gist.github.com/1f7baf19bced2a32c2bd
[12:13:55 CDT(-0500)] <fairwinds> serac: k, now that I have stuff there. Line 64 in setDatabase
[12:14:35 CDT(-0500)] <serac> You should not be doing anything other than simple property validation in setters.
[12:14:54 CDT(-0500)] <fairwinds> serac: Yeah, I guess that is my trouble
[12:14:56 CDT(-0500)] <serac> You want to implement InitializingBean and put the stuff that actually creates the connection in the afterPropertiesSet() method.
[12:14:56 CDT(-0500)] <fairwinds> (smile)
[12:15:23 CDT(-0500)] <fairwinds> ah, that is what I was going to ask if there was such a thing
[12:15:27 CDT(-0500)] <serac> So everything after the first line would go in afterPropertiesSet();
[12:15:56 CDT(-0500)] <serac> You must implement InitializingBean to clue Spring in to treat that method specially and invoke it after all beans are wired up.
[12:16:07 CDT(-0500)] <fairwinds> ah, great, you are a wealth of knowledge. I am not a very good Java programmer yet (smile)
[12:16:52 CDT(-0500)] <fairwinds> serac: exactly what I needed to know here
[12:16:54 CDT(-0500)] <serac> Spring is such a superset of Java that it's hardly the same league, so don't be too frustrated with Spring issues like this.
[12:21:11 CDT(-0500)] <fairwinds> serac: no, I am happy go lucky so it doesn't get me too crazy. I realize I am a bit beyond my normal day stuff so I will have to ask a few questions to succeed with this. I am doing well though. I have a much cleaner AuthHandler and finishing up two TicketRegistries. I have abstracted a few things like CouchDBHTTPRequest, CouchDBConnection and utility for calculating hashes
[12:21:34 CDT(-0500)] <serac> Yeah, so far looks really nice.
[12:23:22 CDT(-0500)] <fairwinds> serac: I will show you my auth handler, it is very small compared to what it was
[14:42:37 CDT(-0500)] <EricDalquist> hey there, just double checking on the git stuff that you guys know that Jasig has an organization setup on Github already
[14:42:51 CDT(-0500)] <serac> Jen Bourey mentioned it.
[14:43:06 CDT(-0500)] <serac> We need to investigate how to hook into it tho.
[14:43:32 CDT(-0500)] <EricDalquist> I believe the idea is that your primary git repo would be under than organization
[14:43:43 CDT(-0500)] <EricDalquist> since there are nice organization level access controls
[14:43:51 CDT(-0500)] <serac> Yeah, what I'm thinking.
[14:44:03 CDT(-0500)] <serac> Lack of familiarity is making the details a little hazy tho.
[14:44:03 CDT(-0500)] <EricDalquist> that allow jasig infrastructure to retain super-user access to projects if needed
[14:44:11 CDT(-0500)] <serac> Sounds beneficial.
[14:44:12 CDT(-0500)] <EricDalquist> just email the infra list with git usernames and we can give people admin access
[14:44:56 CDT(-0500)] <serac> I'll make a note of that on the Jira issue where we're tracking this conversion, https://issues.jasig.org/browse/CAS-997.
[14:45:46 CDT(-0500)] <serac> Can you echo the exact list name so I get it right?
[14:47:15 CDT(-0500)] <EricDalquist> infrastructure@lists.ja-sig.org
[14:49:10 CDT(-0500)] <EricDalquist> https://github.com/jasig.
[14:49:12 CDT(-0500)] <EricDalquist> https://github.com/jasig
[14:50:01 CDT(-0500)] <serac> Thanks

  • No labels