I am new to Spring and at my job a new Java Developer came on my team which is just me (backend web developer) and my boss who is the front end guy. She insisted we switch the framework I was using to Spring as that is all she is good with so my boss agreed. I had from last Monday and still have till the Monday coming up before I am assigned a development task using Spring MVC.
I really need help you guys. If ever, right now is the most important time for me to get where I need to be. I do have some questions and any advice outside of my questions you may be able to give or learning points on topic would be extremely appreciated.
Springs Dependency Injection: I get how this helps loosely couple my code BUT how do you use it? Specifically, (Class Person and Class Dog) How do I inject the Dog into Person and how will this work and how will this help me? What will I be able to do "in detail" when this happens?
Another DI Question: The example I have above with the class Person and class Dog --> how can this line of thinking be applied to the MVC model?
Application Context Question: If I am not using the Main method and am rendering responses through a Controller, will I need to get the Application Context like I would in the Main()? (I am only going of some tutorials I watched)? The Application Context was not retrieved in the Controller.
Spring Framework Class Liibraries: Where can I find the source code for each class/method in Spring 3.2.0
Constructor and Setter based Injection
How to (with examples and explanations) do Constructor Based Injections AND Setter Based Injections? --> How would I use it when I did it as well?
Last Question When I was using let's say Servlets and JSP's, it was simple via 3 tier development. User fills in form or something, maps to servlet, then servlet validates form, invokes logic and renders response. QUESTION PART: Based on how it works in my explanation of Servlets / JSP's, what will I need to look at differently and work with differently using Spring? This means that if I need to create a DAO object in my servlet and pass it a Registration object to persist by utilizing the NEW key word and building the construct, HOW would I do this 'same' example in terms of Spring? Could you provide an example maybe and a detailed explanation on this specifically.
You guys (and gals), I really appreciate this more than anything. This could be my job on the line if I can't get where I need to be and fast (with Spring). Thank you to anyone willing to take the time and help me. ALL feedback is open here.
I believe the failure in this scenario is the decision to start using a new framework that not all team members are familiar with. Especially when you're expected to start using it for development within a week or so. Does your boss know that you do not know how to use Spring? I'm surprised that a manager would dictate the usage of any tool knowing that some team members are not familiar with it, especially without providing training first.
Given that this new team member is the one insisting that you use Spring, when the rest of the team (you) are not familiar with it, then I would at least be asking her to provide some training on how to use Spring.
In any case you need to talk to your boss. Being assigned development tasks that are at risk of not being completed in time, or at all, will be no help to anyone. Best be up front about it now rather than later.
Tim Driven Development
posted 5 years ago
Yes, this past week my boss has allowed me to go through tutorials and do nothing else but study except the once a day quick task like completing some Test Cases, and a little JS work but I have until Monday to get good at Spring 3 MVC. 2 weeks total is enough time for me to grasp the overall concept which I did and learn a few ins and outs. Unfortunately there are many things I am missing on which are listed in my questions.
Could you answer any of them by any chance?
Yes, I can answer these questions.
No, I do not have time to do so.
What you have essentially asked here is "Teach me Spring DI and Spring MVC" which is a very large task indeed. Given that I, like everybody here, volunteer my time I'm afraid this is just too large a task for me to bite off. To get the most out of this site I suggest that you find some tutorials to work through to learn how to use Spring for DI and MVC (I recommend DI first) and then ask more specific questions as you go along. You will get a great response on The Ranch if your questions are along the lines of "I'm trying to achieve specific thing X, I've tried with code Y, but I'm getting result Z. What gives?".
Lastly, if you're at the mercy of your new gal's bequest then find out whether she's intending to use XML or Annotation based configuration for your Spring. No use learning the wrong thing.
Tim Driven Development
posted 5 years ago
I have used tutorials and I am not catching onto these concepts. You or anyone else doesn't have to answer them all, you can just pick one and write about it. I am not looking for a book I am looking for 1 quick brief explanation and/or example or each and that is it. I am not asking much.
I found "Spring In Action" useful in understanding the concepts behind core Spring. I think if tyou hunker down with the book, you might be able to understand core Spring in a few days. You might be able to catch up on MVC "on the job"
The happiness of your life depends upon the quality of your thoughts -Marcus Aurelius ... think about this tiny ad: