Alex Keh Alex.Keh@oracle.net
(works with)Christian.Shay@Oracle.Net
cshay.blogspot.com
11g Client Supports Source Control with TFS 2008 or VS
- Will Work on 10 and 9 Version of oracle DBs
Can Debug with VS using Oracle SQL Developer
- Need Oracle Dev Tools for VS
- http://otn.oracle.com/dotnet to download tools
- Oracle Developer Tools for Visual Studio
- Oracle Data Provider for .Net
- Oracle Providers for ASP.net - Add users to Db as OracleUser
- .Net SP - Dev VB.net STPs in Oracle
Oracle Plugin for DBPro will probably be in Rosario
Support for LINQ - No date - say its 2-4x slower running. Trying to make sure its right before releasing
This was an interesting discussion on what people are looking for to connect to oracle. Everyone agreed that using the Oracle data Provider was the best choice to connect to Oracle as All others were missing stuff, or had incompatibilities with Oracle. Looks like we can check in any work in we create in Oracle to TFS with 11g client, that will be nice
Thursday, June 19, 2008
Lesson Learned Unit Testing
Lesson #1: Write tests using the 3A pattern
Arrange - Set up the test harness
Act - Run the thing you actually want to test
Assert - Verify the results
Benefits
Readability
Consistency
Liabilities
More verbose
Might need to introduce local variables
Lesson #2: Keep your tests close
Tests should be as close as possible to the production code
Keep in Same assembly
Treat them like production code
Liabilities
Should you ship your tests?
Lesson #3: ExpectedException leads to uncertainty
Violates 3A
Record Excpetion Instead
Problem:Don’t know which line of code threw the exception. Test can pass for the wrong reason
Test For Exact Exception if doing this
Benefits
Readability
Identify and isolate the code you expect to throw
Liabilities
Act and Assert are together
Lesson #4: Small fixtures
Your code should be a book for people to understand
Break Unit tests up into easy to read section
Benefits
Smaller, more focused test classes
Liabilities
Potential code duplication
May consider duplicating code if it’s for the purpose of communication
Lesson #5: Don’t use SetUp or TearDown
You can end up with a test that doesn’t need anything from the SetUp method.
If SetUp takes a long time, you’d be paying the price for every test, even those that don’t need all of it
Put duplicated code into a method, and calling it at the beginning of each test
Benefits
Readability (if it removes duplication)
Test isolation
Liabilities
Duplicated initialization code
Lesson #6: Don’t use abstract base test classes
Shouldn't be a problem as VSTS doesn't allow them
Interesting Stuff hopefully we can make good use of this in our unit tests
Arrange - Set up the test harness
Act - Run the thing you actually want to test
Assert - Verify the results
Benefits
Readability
Consistency
Liabilities
More verbose
Might need to introduce local variables
Lesson #2: Keep your tests close
Tests should be as close as possible to the production code
Keep in Same assembly
Treat them like production code
Liabilities
Should you ship your tests?
Lesson #3: ExpectedException leads to uncertainty
Violates 3A
Record Excpetion Instead
Problem:Don’t know which line of code threw the exception. Test can pass for the wrong reason
Test For Exact Exception if doing this
Benefits
Readability
Identify and isolate the code you expect to throw
Liabilities
Act and Assert are together
Lesson #4: Small fixtures
Your code should be a book for people to understand
Break Unit tests up into easy to read section
Benefits
Smaller, more focused test classes
Liabilities
Potential code duplication
May consider duplicating code if it’s for the purpose of communication
Lesson #5: Don’t use SetUp or TearDown
You can end up with a test that doesn’t need anything from the SetUp method.
If SetUp takes a long time, you’d be paying the price for every test, even those that don’t need all of it
Put duplicated code into a method, and calling it at the beginning of each test
Benefits
Readability (if it removes duplication)
Test isolation
Liabilities
Duplicated initialization code
Lesson #6: Don’t use abstract base test classes
Shouldn't be a problem as VSTS doesn't allow them
Interesting Stuff hopefully we can make good use of this in our unit tests
Monday, June 9, 2008
Subtle Power of Data minig Algorithms
Microsoft gives 9 Different Data Mining algorithms with SQL server
How much Data is enough
- As Many as is a valid Model
- OverTraining of data possible by Bad parameters
- Too much Data can make a bland mode
What is a Valid Model
- Accuracy use Lift & Profit Charts, Scatter Plots, or Classification Matrix
- Reliability - Cross Validation
- Usefulness - Requires Human eye
How to decide which prediction is most accurate
- Lift chart - Bigger the number better the score
- Scatter plots - need a lot of data
- Clustering is not good for predicting, but is good for trending
- Naive Bayes - Oldest, usually least accurate
- Decision Trees - used for classification and association
- Regression - Look for Regressor- use to predict regression
- Neural NetWork - Finds Pattersn when all others fails...Difficult to interpret results
Fold - Partitions - Want models that are exactly the same
- Make subsets of data
- Chose model with least standard deviation
Control "Depth of Insight"
- Select based on most important columns or column values
How much Data is enough
- As Many as is a valid Model
- OverTraining of data possible by Bad parameters
- Too much Data can make a bland mode
What is a Valid Model
- Accuracy use Lift & Profit Charts, Scatter Plots, or Classification Matrix
- Reliability - Cross Validation
- Usefulness - Requires Human eye
How to decide which prediction is most accurate
- Lift chart - Bigger the number better the score
- Scatter plots - need a lot of data
- Clustering is not good for predicting, but is good for trending
- Naive Bayes - Oldest, usually least accurate
- Decision Trees - used for classification and association
- Regression - Look for Regressor- use to predict regression
- Neural NetWork - Finds Pattersn when all others fails...Difficult to interpret results
Fold - Partitions - Want models that are exactly the same
- Make subsets of data
- Chose model with least standard deviation
Control "Depth of Insight"
- Select based on most important columns or column values
IDE Tips & Tricks in vs2008 (Some work in 2005)
1) can use objects outside solutions
2) Repeat Search - F3 - Highlight a word then Crtl -F3
3) Box Selection - Alt -Shift...use direction arrows...select stuff in a box...does not highlight items at beginning of 2nd line
4) Cycle Paste - Ctrl -shift U...Cycles though what is on clipboard...Will need to turn off copy in Text -> Editor -> Properties
5) Toolbox General Tab (looks like I missed writing notes on this 1)
6) Snippet - Tab - Tab.... uses key words to help find snippet you want
- Code Snippet Editor - add,remove, import snippets
7)Command window - ctrl I, find Combo box can be used for parameters for commands demos showed finding routine in combo...press F9 (while still in combo) puts a break point at beginning of routine
8) right click - tab...Close all windows but this one in VS
9) Ctrl -Tab...brings up list of all files open
10) Change font size -- Properties, Environment, fonts and colors...can pick environment font for your machine
11) Different window layouts
- Full screen Mode Shift-Alt-Enter
- File mode (missed command)
12) Misc File Project - Finds code not in Project, will add to solution
13) Open Visual studio where you want...can set what happens when you start visual studio, can set to open last solution worked on
14) Trace Points - Built in Trace statements that log on your behalf (to debug window)
- Right click a line -- choose add tracepoint
15) Conditional breakpoints - Break points that are conditional now have a "+" in their brown circle at start of line
16) remove unsused "Using" statemnts... Right Click file - Remove unused using is a choice
17) Watch Window - can have 4 instances of watch windows up at 1 time, can change values of items your watching as your code is running
18) Datatips - Can change values of items as you hover over them
19) Immediate window
20) Recording Macros -- Tools-Macros-record temporary macro
2) Repeat Search - F3 - Highlight a word then Crtl -F3
3) Box Selection - Alt -Shift...use direction arrows...select stuff in a box...does not highlight items at beginning of 2nd line
4) Cycle Paste - Ctrl -shift U...Cycles though what is on clipboard...Will need to turn off copy in Text -> Editor -> Properties
5) Toolbox General Tab (looks like I missed writing notes on this 1)
6) Snippet - Tab - Tab.... uses key words to help find snippet you want
- Code Snippet Editor - add,remove, import snippets
7)Command window - ctrl I, find Combo box can be used for parameters for commands demos showed finding routine in combo...press F9 (while still in combo) puts a break point at beginning of routine
8) right click - tab...Close all windows but this one in VS
9) Ctrl -Tab...brings up list of all files open
10) Change font size -- Properties, Environment, fonts and colors...can pick environment font for your machine
11) Different window layouts
- Full screen Mode Shift-Alt-Enter
- File mode (missed command)
12) Misc File Project - Finds code not in Project, will add to solution
13) Open Visual studio where you want...can set what happens when you start visual studio, can set to open last solution worked on
14) Trace Points - Built in Trace statements that log on your behalf (to debug window)
- Right click a line -- choose add tracepoint
15) Conditional breakpoints - Break points that are conditional now have a "+" in their brown circle at start of line
16) remove unsused "Using" statemnts... Right Click file - Remove unused using is a choice
17) Watch Window - can have 4 instances of watch windows up at 1 time, can change values of items your watching as your code is running
18) Datatips - Can change values of items as you hover over them
19) Immediate window
20) Recording Macros -- Tools-Macros-record temporary macro
Social Networks Sucesses and Pitfalls
A place to facilitate conversations, conversations about your company will happen weather you do this or not, now get to control somewhat how they go.
Useful to mine data from people who visit and register
Used internally to to find experts in the company
Employees coming straight from college are used to using this type of application to collaborate and share ideas
Need to beware folks becoming professional bloggers - and spend a lot of time just answering questions
Gives people a venue to find answers before they get too frustrated
More openness - Makes company seem more friendly
Can use internal blogs to help folks internally ask questions
Setup forums to answer questions - Forums are nice as they are easily searchable, so same answers are not given over and over
Have forums setup to send emails to people when new question are posted, so response to questions isn't too long.
People are using blogs to post meeting notes so people can read them ask and respond to questions from the meeting
Hvew to be prepared to have people invest their time, even force them if nessecary to make sure the content doesn't go stagnant (talking about blogs)
Useful to mine data from people who visit and register
Used internally to to find experts in the company
Employees coming straight from college are used to using this type of application to collaborate and share ideas
Need to beware folks becoming professional bloggers - and spend a lot of time just answering questions
Gives people a venue to find answers before they get too frustrated
More openness - Makes company seem more friendly
Can use internal blogs to help folks internally ask questions
Setup forums to answer questions - Forums are nice as they are easily searchable, so same answers are not given over and over
Have forums setup to send emails to people when new question are posted, so response to questions isn't too long.
People are using blogs to post meeting notes so people can read them ask and respond to questions from the meeting
Hvew to be prepared to have people invest their time, even force them if nessecary to make sure the content doesn't go stagnant (talking about blogs)
Team Build Muscleman
The main reason to do Continuous integration builds is to know when something broke the application. You can add test list to the build project and have them run everytime you build the app.
2008 enhancements - Build Explorer and Build Notifications
To override setting in Build projects, use the .rsp file and put the changes you want in there, or go further and build at command line and put changes in command line
- Warning need to control how many builds you keep or they will start to take up considerable amount of disk space
- Can use the SDC tools to repopulate ad DB on Deploy if desired
- IF using SDC, add to project so you can add to source control
- use message text ="" So you can search build out put as build output can be thousands of lines long
- in target dependsontarget="section" tag To run 1st before this target
- Highly recommend TFSSideKicks (Attrice.com)
- 2005 builds will not seamless migrate to 2008.. They will need modifications
- Use Custom build steps so you get feedback when a part of the build is running
- Keep Test in Different projec, but same solution in Source control, this will make it so you can run them when you build
- They reccomend not team building to production, but it is ok to do dev and QA
- WIX (Windowsn installer for XML)
- WIX protects are another type of Project in VS
- use this to build MSi's
- Its an addon, can get from www.sourceforge.com\releases
2008 enhancements - Build Explorer and Build Notifications
To override setting in Build projects, use the .rsp file and put the changes you want in there, or go further and build at command line and put changes in command line
- Warning need to control how many builds you keep or they will start to take up considerable amount of disk space
- Can use the SDC tools to repopulate ad DB on Deploy if desired
- IF using SDC, add to project so you can add to source control
- use message text ="" So you can search build out put as build output can be thousands of lines long
- in target dependsontarget="section" tag To run
- Highly recommend TFSSideKicks (Attrice.com)
- 2005 builds will not seamless migrate to 2008.. They will need modifications
- Use Custom build steps so you get feedback when a part of the build is running
- Keep Test in Different projec, but same solution in Source control, this will make it so you can run them when you build
- They reccomend not team building to production, but it is ok to do dev and QA
- WIX (Windowsn installer for XML)
- WIX protects are another type of Project in VS
- use this to build MSi's
- Its an addon, can get from www.sourceforge.com\releases
Sunday, June 8, 2008
Thank You
Thank you for the opportunity to attend TechEd 2008 this past week. I found some better ways to do things and got to see the new improvements that are coming our way. I enjoyed talking with other developers in the industry, exchanging ideas, and being able to ask questions. The week was exhausting, but I really did learn a lot.
Here are some photos from the week.





Here are some photos from the week.

Subscribe to:
Posts (Atom)