I am not an expert but here are few Do's and Don't s based on my experience:
Do's
- Make use of Loggers
- Use different level of Logger Level based upon data you want to print
- Each method must have the "Entering" and "Exiting" statements
- Must print atleast "User Login" in Entering Statement
- Use organization specific package and class names
- Maintain minimum jar files
- Make minimum use of class variables
- Make minimum OIM API instances or Database Connection
- Each class and method must have Java Comments
- Make use of Try/Catch and Throws/Throw for Error Handling
- Use meaningful names for variables and java class
- Make use of Lookups, System Properties for storing configurable parameters
- Close the OIM API Instances and Database at the end of Operation
- Must print the error message before throw statement and inside catch block
Don't:
- Do not hard code anything
- Do not use System.out.println in Java Code
- Do not print password in Java Code
No comments:
Post a Comment