Friday, August 10, 2012
Capture AJAX callbacks
$('#your_form').bind('ajax:error', function{ alert('Ajax failed!')} )
Get form input hash
var params = {}; $.each($('#your_form').serializeArray(), function(i, field) {params[field.name] = field.value;});
Thursday, August 9, 2012
Setup Git server on Linux
- Setup ssh login
- ssh [your_name]@[server_name] mkdir .ssh
- scp ~/.ssh/id_rsa.pub [your_name]@[server_name]:.ssh/authorized_keys
- Install Git:
- ssh [server_name]
- sudo apt-get update
- sudo apt-get install git-core
- If a shared repository is need, create a git user:
- sudo adduser git
- ... cont on setup ssh login.
- Add repository
- Login as your_name or git
- mkdir myrepo.git
- cd myrepo.git
- git --bare init
- Setup development machine
- git remote add origin [server_name]:myrepo.git
- git push origin master
- Done
Friday, August 3, 2012
What people does the industry need?
http://www.google.com/about/jobs/
http://www.facebook.com/careers/
http://twitter.com/Jobs
http://aws.amazon.com/careers/
http://pivotallabs.com/jobs/welcome
http://instagram.com/about/jobs/
http://careers.microsoft.com/
http://www.linkedin.com/company/linkedin/careers
http://jobs.37signals.com/
https://jobs.github.com/
http://jobs.heroku.com/
http://www.engineyard.com/company/careers/
http://www.w3.org/Consortium/Recruitment/
...
http://www.facebook.com/careers/
http://twitter.com/Jobs
http://aws.amazon.com/careers/
http://pivotallabs.com/jobs/welcome
http://instagram.com/about/jobs/
http://careers.microsoft.com/
http://www.linkedin.com/company/linkedin/careers
http://jobs.37signals.com/
https://jobs.github.com/
http://jobs.heroku.com/
http://www.engineyard.com/company/careers/
http://www.w3.org/Consortium/Recruitment/
...
Saturday, July 28, 2012
Setup development environment on Ubuntu Desktop 12.04
Macvim/Gvim + Janus (+ ctags)
https://github.com/carlhuda/janus/
Setup procedures on fresh installed OS:
$ sudo apt-get install vim-gnome
$ sudo apt-get install git
$ sudo apt-get install rake
$ sudo apt-get install curl
$ sudo apt-get install ack
$ sudo apt-get install exuberant-ctags
$ curl -Lo- http://bit.ly/janus-bootstrap | bash
https://github.com/carlhuda/janus/
Setup procedures on fresh installed OS:
$ sudo apt-get install vim-gnome
$ sudo apt-get install git
$ sudo apt-get install rake
$ sudo apt-get install curl
$ sudo apt-get install ack
$ sudo apt-get install exuberant-ctags
$ curl -Lo- http://bit.ly/janus-bootstrap | bash
Tuesday, July 24, 2012
Thursday, July 19, 2012
Rename multiple files using regular expression
$> for i in *.avi; do j=`echo $i | sed 's/find/replace/g'`; mv "$i" "$j"; done
Wednesday, July 18, 2012
Ruby on Rails development notes, tips, practices
Development
- Performance tuning tools:
- New Relic
- Useful tips:
- Use rails console to counter check the SQL statements being executed.
Testing
- Unit tests should be written in a way that adding new records in test fixtures shouldn't affect the previous test results.
- New test fixtures should be added in a way that they should link to existing fixture data so as to avoid breaking existing test cases.
Quality Assurance
- Besides unit, functional and integration test within rails framework. Create automated browser test using tools like "Selenium" over test/real data.
Maintenance
- Avoid using unnecessary code reflection. It's not good for performance and maintenance.
Tuesday, July 17, 2012
Selected web resources and news feeds
- www.programmableweb.com - Keeping you up to date with APIs, mashups and the Web as platform.
- highscalability.com - Building bigger, faster and more reliable websites.
- aws.amazon.com - Amazon web services.
- linux.vbird.org - Comprehensive linux guide .... in Chinese.
- channel9.msdn.com - The microsoft community.
- engineering.twitter.com - Twitter's engineering blog.
(to be cont.)
Labels:
Industry
System design tips
General tips for develop web based system.
- Action Audits - Keep track of user actions. In Rails, system may log controller actions and corresponding params and response of every single request.
- Bug/Error tracking - Every error triggered in system should be notified to developers.
- Timestamps - Always keep creation, update and any other timestamps on every records in database.
(to be cont.)
Labels:
Practices
General guidelines for team software development
Development Environment
- Source control - e.g. Git (preferred choice) , Csv, Svn
- May use internal server or public source controls (e.g. Github/ Unfuddle)
- Team members should receive notification whenever there's new push/commit to the server repository.
- Knowledge base - Wiki
- Team members should try to contribute on:
- Project documentations
- Technical know-hows
- Workflow control for agile development. Some choices:
- Simple and easy to use - Pivotal Tracker
- More comprehensive one - Atlassian JIRA
- Continuous integration - Build and test server. For example:
- Jenkins - For Ruby on Rails developments
- CuriseControl.NET - For .NET developments
- Test Automation
- Browser test - Selenium IDE
General Coding Practices
- DRY - Don't repeat yourself. Never copy and paste same (similar) block of code in multiple places within the project. Instead, common functionalities should be "extracted" to a single access point like a helper function or by other means.
- Coding conversions - Team members should follow a single set of coding conversion.
- Try to keep each line under 120 to 150 chars.
- Code with comments.
- Should always keep the code clean and easy for maintenance.
- Should keep small code source files. Every source code file should in general not more than 500 or even 300 lines (excluding large blocks of comments).
- Should keep small functions - not more than 30 to 50 lines.
- Should keep functions as private/protected as possible. Only expose a function to public whenever necessary.
- Every single function/method should be unit tested.
- Regular code coverage test.
- Developers may keep a work diary to log everyday's work done.
Daily Collaboration Practices
- Team members MUST complete test (unit, functional, integration test) and make sure there's no unexpected error before pushing code to repository.
- The build server (e.g. Jenkins/CuriseControl.NET) should run complete test whenever there's code update on repository. In this way, whoever broke any tests can be clearly identified.
- If there's unexpected errors (except explicit NotImplementedError) reported by build server, whom pushed the related code should fix the errors ASAP.
- Responsibilities - whenever a feature raised a issue/bug need to be fixed/enhanced, the team member(s) who contributed to that feature should be have the priority to follow the case.
- Communications
- Better communications between team members always save development time and avoid unnecessary bugs.
- Always let other team members know what you're working on.
- Pending or unfinished feature can be marked as "NotImplementedException" and let the corresponding test fail. Then commit code to repository.
- Any bug reported from QA Engineers should state as much details as possible including the environment and steps to reproduce a bug.
- Code review
- Team members should review each others' code.
- For any problem spotted, one should inform the author of that code. In addition, adding unit tests to indicate the problem may also helps.
- It there's no QA team in the group. Developer should write additional test cases for each other! It's always better for a developer to find a bug before the end users!
- All developers should stand by when a new release is deployed to production.
- Business logic and any updates should be kept in a centralized repository such as work flow control or wiki.
- Every developer should try their best to commit/push the work done on that day before leaving the office.
Source Control Usage Practices
- New project feature should be developed on a separated branch. Then merge back to master/main trunk when finished and tested.
- Project releases should be tagged.
Labels:
Favourite,
Management,
Practices
Sunday, July 15, 2012
The Passionate Programmer
Marketing
- Both ends of the technology adoption curve might prove to be lucrative.
- You can't compete on price. In fact, you can't afford to compete on price.
- Supply and demand. Exploit market imbalances.
- Don't just know how to program. Now is the time to think about business domains you invest your time in.
- Be the worst guy in every band you're in.
- The people around you affect your own performance. Choose your crowd wisely.
- I haven't been given the opportunity...? Seize the opportunity!
- Be a generalist. Generalists are rare...and, therefore, precious.
- Your skill should transcend technology platforms.
- Be a specialist. Too many of us seem to believe that specializing in something simply means not knowing about other things.
- Don't invest on single technology or platform. Vendor - centric views are typically myopic.
- Passionate. Work because you couldn't not work.
Investment
- Learning. Don't wait to be told. Ask!
- Learn the business you work for. You can't creatively help a business until you know how it works.
- Find a teacher. It's ok to depend on someone. Just make sure it's the right person.
- Be a teacher. To find out whether you really know something, try teach it to someone else.
- Be a teacher. Mentors tend not to get laid off.
- Practice. Practice at your limits.
- Implementation. If you want to feel you own a process, help implement it.
- Stand on shoulder of Giant. Mine existing code for insights.
- Use existing code to reflect on your own capabilities.
Execution
- It's now. What can we do? Right Now?
- Mind reading. The mind - reading trick, if done well, leads to people depending on you.
- Daily report. Have an accomplishment to report every day.
- Don't forget whom you work for. Your managers' successes are your successes.
- Satisfaction. Be ambitious, but don't wear it on your sleeve.
- Get job well done today. How much more fun could you make your job?
- What's your value? Ask, "Was I worth it today?"
- Beware of being blinded by your won success.
- Enjoy Maintenance. Maintenance can be a place of freedom and creativity.
- Concentrate on 8 working hours per day. Projects are marathons, not sprints.
- Learn from failure. Every wrong note is but one step away from a right one.
- Stressful times offer the best opportunities to build loyalty.
- Say "No". Saying "Yes" to avoid disappointment is just lying.
- Don't panic. Heroes never panic.
- Say it, implement it, demonstrate it. Status reports can help you market yourself.
Sales
- Don't ignore feelings. Performance appraisals are never objective.
- Communication is important. Your customers are afraid of you.
- Communication and documentation. You are what you can explain.
- Show up. Learn about your colleagues.
- The right language to the right people. Market your accomplishments in the language of your business.
- Change the world. Have a mission. Make sure people know it.
- Let people hear your voice.
- Have your own brand. Your name is your name.
- Google never forgets.
- Publish your code. Anyone can use Rails. Few can say Rails contributor.
- Be a master.
- Relationships. Fear gets between us and the pros.
Leading technologies
- Outdated technologies. Your shiny new skills are already obsolete.
- You are not your job.
- Endlessness. Focus on doing, not on being done.
- Create yourself a product roadmap.
- Notice the market. Watch the alpha geeks.
- Developer, review themselves.
- Monkey catching trap. Rigid values make you fragile.
- Avoid waterfall career plannings.
- Daily improvement.
- Independent.
Monday, July 9, 2012
Git daily usage cheat sheet
| Task | Command |
|---|---|
| Initialize a new git repository |
git init
|
| View local branches | git branch |
| Create new local branch | git branch [new_branch_name] |
| Delete local branch | git branch -d [branch_name] |
| Switch to a branch | git checkout [branch_name] |
| Add files to git | git add . |
| Undo all current changes. | git checkout . |
| Commit changes | git commit -a -m "Log message" |
| Show git logs | git log |
| Push local to remote | git push origin [branch_name] |
| Pull from remote | git pull origin [branch_name] |
| Merge branch | git merge [from_branch] |
| Show diff | git diff |
| Show all branches | git branch -a |
| Fix a tagged release |
git checkout -b [tag_name]_fixes [tag_name]
OR (for getting a remote branch)
git checkout -b [new_local_branch] origin/[remote_branch]
e.g. git checkout -b myfeature origin/myfeature
|
| Create a new tag | git tag [tag_name] |
| Push tags to remote | git push --tags |
| Overwrite existing tag | git tag -f [tag_name] |
| Delete tag |
git tag -d 12345
git push origin :refs/tags/12345
|
| Merge individual commits | git cherry-pick [commit_hash] |
| Stashing |
git stash
git stash apply
git stash list
|
| Create an empty repository | git --bare init |
| Adding a remote repository |
git remote add origin [server_name]:[directory_name]
|
Checkout a single file on another branch:
$ git checkout branch_name file_full_path
More on: http://gitref.org/index.html
$ git checkout branch_name file_full_path
More on: http://gitref.org/index.html
Labels:
Cheatsheet,
Favourite,
Git
Capistrano cheat sheet
| Description | Command |
|---|---|
| List cap details | cap -T |
| backup database | cap bullitt db:backup:adhoc |
| Deployment without migration | cap bullitt deploy |
| Deployment with migrations | cap bullitt deploy:migrations |
Labels:
Cheatsheet,
Favourite,
Rails
Linux system full backup
$>tar --exclude /proc --exclude /mnt --exclude /tmp --exclude
/backupdata -jcvp -f /backupdata/system.tar.bz2 /
/backupdata -jcvp -f /backupdata/system.tar.bz2 /
Add new drive to linux
Procedure:
- Locate the new device. e.g. $> ls /dev/sdb
- Create partition. $> fdisk /dev/sdb
- m - help
- n - new partition
- p - list partitions
- d - delete partition
- Reboot
- Format partition. $> mkfs -t ext3 /dev/sdb1
- Edit /etc/fstab to mount on startup. /dev/sdb1 /mnt/sdb1 ext3 defaults 1 2
- Done
Friday, June 22, 2012
Setup Ubuntu Server 12.04 on Lenovo S10 Thinkstation
Environment:
- Lenovo S10 Thinkstation
- Intel Matrix Storage RAID 1 : 500G HDD x 2
- Ubuntu Server 12.04 LTS
Problem: During the installation, in the step for installing GRUB on master boot record. It prompts for a dev like /dev/sda, /dev/sdb, ... and gave a default /dev/mapper. What should be the right dev?
Solution: /dev/mapper/isw_beajfgdjeh_LENOVO
This volumn name should appear in the previous step. So, keep this for GRUB.
Comment on Sep 28, 2012
Intel Matrix RAID is consider to be not stable for production use. Use RAID controller instead for production.
Comment on Sep 28, 2012
Intel Matrix RAID is consider to be not stable for production use. Use RAID controller instead for production.
Labels:
Linux
Wednesday, March 28, 2012
Twitter bootstrap - UI
By nerds, for nerds.
Built at Twitter by @mdo and @fat, Bootstrap utilizes LESS CSS, is compiled via Node, and is managed through GitHub to help nerds do awesome stuff on the web.
Made for everyone.
Bootstrap was made to not only look and behave great in the latest desktop browsers (as well as IE7!), but in tablet and smartphone browsers via responsive CSS as well.
Packed with features.
A 12-column responsive grid, dozens of components, javascript plugins, typography, form controls, and even a web-based Customizer to make Bootstrap your own.
http://twitter.github.com/bootstrap/
Built at Twitter by @mdo and @fat, Bootstrap utilizes LESS CSS, is compiled via Node, and is managed through GitHub to help nerds do awesome stuff on the web.
Made for everyone.
Bootstrap was made to not only look and behave great in the latest desktop browsers (as well as IE7!), but in tablet and smartphone browsers via responsive CSS as well.
Packed with features.
A 12-column responsive grid, dozens of components, javascript plugins, typography, form controls, and even a web-based Customizer to make Bootstrap your own.
http://twitter.github.com/bootstrap/
Tuesday, February 28, 2012
Github - Source control
Free public repositories, collaborator management, issue tracking, wikis, downloads, code review, graphs and much more…
https://github.com/
Saturday, January 28, 2012
Phusion Passenger - Deployment
Easy and robust deployment of Ruby on Rails applications on Apache and Nginx Webservers.
http://www.modrails.com/
http://www.modrails.com/
Wednesday, December 28, 2011
Capistrano - Deployment
Capistrano is an open source tool for running scripts on multiple servers; its main use is deploying web applications. It automates the process of making a new version of an application available on one or more web servers, including supporting tasks such as changing databases.
http://capistranorb.com/
Monday, November 28, 2011
Financial ERP - In-house web-based system
Team
- 2 developers
- 2 outsourcing developers
- 1 QA
- Manage the whole SDLC
- Gather user requirements
- Create and prioritize requested features
- System design
- Implementation
- Code reviews
- Deployment
- User demo
- UAT
- Maintenance
- Bug fix
- Ruby on Rails
- Macvim
- Pivotal Tracker - Agile development
- Unfuddle - Git source control
- Apache
- Capistrano
- JQuery, CSS
- Phusion Passenger
- Selenium
- Chef solo
- Shell scripts
- PostgreSQL
- & more gems...
Ruby on Rails
Ruby on Rails is a breakthrough in lowering the barriers of entry to programming.
Powerful web applications that formerly might have taken weeks or months
to develop can be produced in a matter of days.
Powerful web applications that formerly might have taken weeks or months
to develop can be produced in a matter of days.
http://rubyonrails.org/
Nginx
Nginx (pronounced engine-x) is a free, open-source, high-performance HTTP server and reverse proxy, as well as an IMAP/POP3 proxy server. Igor Sysoev started development of Nginx in 2002, with the first public release in 2004. Nginx now hosts nearly 12.18% (22.2M) of active sites across all domains. Nginx is known for its high performance, stability, rich feature set, simple configuration, and low resource consumption.
http://wiki.nginx.org/Main
Unfuddle
Software Project Management
https://unfuddle.com/
Pivotal Tracker
Build better software, faster.
Collaborative, lightweight agile project management tool, brought to you by the experts in agile software development.
Increase Visibility and Collaboration
Bring everyone, even distributed teams into the same virtual room. Enable a more efficient way to agree on priorities and stay aligned with the entire team.
Plan Based on Realistic Estimates
Stay on target with Tracker's continuous, automatic prediction of milestone completion dates, based on your team's performance.
Deliver on Customer Feedback
Get the right product to the market sooner, based on continuous feedback and prioritization. Respond to changing needs and new requirements easily.
Transform How You Build Software
Supercharge your agile project teams with focused, real time collaboration. Accelerate agile adoption with a simple, proven process.
http://www.pivotaltracker.com/
Saturday, October 29, 2011
Allow uploading large files on IIS 7.0
Solve the Uploadify IO Error.
In IIS 7.0, the default upload limit is 30M.
%windir%/system32/inetsrv/config/applicationhost.config
<system.webServer>
<security>
<requestFiltering >
<requestLimits maxAllowedContentLength="1073741824" ></requestLimits>
</requestFiltering>
</security>
</system.webServer>
In IIS 7.0, the default upload limit is 30M.
%windir%/system32/inetsrv/config/applicationhost.config
<system.webServer>
<security>
<requestFiltering >
<requestLimits maxAllowedContentLength="1073741824" ></requestLimits>
</requestFiltering>
</security>
</system.webServer>
Saturday, October 22, 2011
Configure IIS 7.0 for Restful web application
When deploys a Restful web application to IIS 7.0 on Windows server 2008, it would certainly returns 404 when trying to access any restful service in the application.
This is because by default the restful request is handled by "StaticFile" handler in IIS.
The quickest way to solve the problem is change the settings in "StaticFile". (Screenshot #1)
- Select the "Executable" be "...\v4.0...\aspnet_isapi.dll"
- Un-check the "Check if file exists" option.
In addtion to that, make sure the application is running on v4.0 classic (Screenshot #3) or you may see a log in Screenshot #2



This is because by default the restful request is handled by "StaticFile" handler in IIS.
The quickest way to solve the problem is change the settings in "StaticFile". (Screenshot #1)
- Select the "Executable" be "...\v4.0...\aspnet_isapi.dll"
- Un-check the "Check if file exists" option.
In addtion to that, make sure the application is running on v4.0 classic (Screenshot #3) or you may see a log in Screenshot #2



Wednesday, September 28, 2011
ASP.NET MVC
ASP.NET MVC gives you a powerful, patterns-based way to build dynamic websites that enables a clean separation of concerns and that gives you full control over markup for enjoyable, agile development. ASP.NET MVC includes many features that enable fast, TDD-friendly development for creating sophisticated applications that use the latest web standards.
http://www.asp.net/mvc
http://www.asp.net/mvc
Apache Hadoop - Distributed computing
What Is Apache Hadoop?
The Apache™ Hadoop® project develops open-source software for reliable, scalable, distributed computing.
The Apache Hadoop software library is a framework that allows for the distributed processing of large data sets across clusters of computers using simple programming models. It is designed to scale up from single servers to thousands of machines, each offering local computation and storage. Rather than rely on hardware to deliver high-avaiability, the library itself is designed to detect and handle failures at the application layer, so delivering a highly-availabile service on top of a cluster of computers, each of which may be prone to failures.
http://hadoop.apache.org/
The Apache™ Hadoop® project develops open-source software for reliable, scalable, distributed computing.
The Apache Hadoop software library is a framework that allows for the distributed processing of large data sets across clusters of computers using simple programming models. It is designed to scale up from single servers to thousands of machines, each offering local computation and storage. Rather than rely on hardware to deliver high-avaiability, the library itself is designed to detect and handle failures at the application layer, so delivering a highly-availabile service on top of a cluster of computers, each of which may be prone to failures.
http://hadoop.apache.org/
Amazon web service - Cloud services
Amazon Web Services offers a complete set of infrastructure and application services that enable you to run virtually everything in the cloud: from enterprise applications and big data projects to social games and mobile apps.
One of the key benefits of cloud computing is the opportunity to replace up-front capital infrastructure expenses with low variable costs that scale with your business.
http://aws.amazon.com/
Wednesday, December 29, 2010
Debug SQL Stored Procedure
In general, any database stored procedure can be debugged by inserting printouts within the procedure. First, create a debug table to store the printouts. e.g.
your_debug_table {
id [int]
message [string]
timestamp [datetime]
}
Then, in your stored procedure, print messages to debug table. e.g.
your_stored_procedure {
...
insert into your_debug_table (message) values (your_message);
...
}
Keywords: MySQL, Oracle, PostgreSQL, MS SQL Server, Stored Procedure, Debug
your_debug_table {
id [int]
message [string]
timestamp [datetime]
}
Then, in your stored procedure, print messages to debug table. e.g.
your_stored_procedure {
...
insert into your_debug_table (message) values (your_message);
...
}
Keywords: MySQL, Oracle, PostgreSQL, MS SQL Server, Stored Procedure, Debug
Tuesday, December 28, 2010
JQuery - UI
jQuery is a new kind of JavaScript Library.
jQuery is a fast and concise JavaScript Library that simplifies HTML document traversing, event handling, animating, and Ajax interactions for rapid web development. jQuery is designed to change the way that you write JavaScript.
http://jquery.com/
jQuery is a fast and concise JavaScript Library that simplifies HTML document traversing, event handling, animating, and Ajax interactions for rapid web development. jQuery is designed to change the way that you write JavaScript.
http://jquery.com/
Tuesday, September 28, 2010
Firefox Extension Development
Extensions add new functionality to Mozilla applications such as Firefox, SeaMonkey and Thunderbird. They can add anything from a toolbar button to a completely new feature. They allow the application to be customized to fit the personal needs of each user if they need additional features, while keeping the applications small to download.
Extensions are different from plugins, which help the browser display specific content like playing multimedia files. Extensions are also different from search plugins, which plug additional search engines in the search bar.
https://developer.mozilla.org/en-US/docs/Extensions
JIRA - Project management
Your Development Process, Your rules
JIRA is the project tracker for teams planning, building and launching great products.
Thousands of teams choose JIRA to capture and organize issues, work through action items, and stay up-to-date with team activity.
http://www.atlassian.com/software/jira/overview
Saturday, August 28, 2010
Scrum - Agile development
Scrum is an iterative and incremental agile software development method for managing software projects and product or application development. Scrum has not only reinforced the interest in project management,[citation needed] but also challenged the conventional ideas about such management. Scrum focuses on project management institutions where it is difficult to plan ahead. Mechanisms of empirical process control, where feedback loops that constitute the core management technique are used as opposed to traditional command-and-control oriented management.[citation needed] It represents a radically new approach for planning and managing projects, bringing decision-making authority to the level of operation properties and certainties.
http://en.wikipedia.org/wiki/Scrum_(development)
Friday, July 30, 2010
Resharper for .Net development
ReSharper is a productivity extension to Visual Studio that helps maintain and improve C#, VB.NET, ASP.NET, ASP.NET MVC, XAML, XML, HTML, JavaScript, or CSS code in Visual Studio projects. It detects and removes errors and code smells; speeds up coding; provides rich navigation and search features, 40+ solution-wide refactorings and hundreds of code transformations, as well as many more great features for .NET developers.
http://www.jetbrains.com/
http://www.jetbrains.com/
Tuesday, June 29, 2010
Setup Restful service development environment on Visual Studio 2010
Setting up Visual Studio
Publish the solution to your local IIS in order to test the REST interface properly.
1. Build the Solution.
2. Right click on the Service Project and select "Publish".
3. Name the Publish Profile.
4. In the "Publish method" drop down list, select "Web Deploy".
5. In the "Service URL" box, enter "localhost".
6. In the "Site/application" box, enter "Default Web Site/v1".
7. Make sure that "Mark as IIS application on destination" is checked.
8. Click "Save" in the upper right hand corner.
9. Click "Publish".
IIS Settings
1. Security - Make sure that the "Directory Security" for the v1 Web Application is set to anonymous only. By default, both anonymous and windows authentication
will be enabled, but WCF/REST cannot have 2 different types of authenticaton modes enabled.
2. Default Web Site Application Settings
1. Bring up the properties window of the Default Web Site in your local IIS manager.
2. Click on the "Home Directory" tab and then on the "Configuration..." button.
3. On the "Mappings" tab, you will need to add a new application mapping.
1. Click on "Add"
2. For the "Executable" field, browse to the .Net 4.0 ASPNET_ISAPI dll (usually here "C:\WINDOWS\Microsoft.NET\Framework\v4.0.30319\aspnet_isapi.dll")
3. In the "Extension" field, type ".*"
4. Make sure that "Script engine" is checked.
5. MAKE SURE THAT "Check that file exists" IS NOT CHECKED!
6. Click "Ok". NOTE: If the "Ok" button is still disabled, click back in the "Executable" box, and the "Ok" should be enabled.
4. Restart IIS (run the "iisreset" command).
Publish the solution to your local IIS in order to test the REST interface properly.
1. Build the Solution.
2. Right click on the Service Project and select "Publish".
3. Name the Publish Profile.
4. In the "Publish method" drop down list, select "Web Deploy".
5. In the "Service URL" box, enter "localhost".
6. In the "Site/application" box, enter "Default Web Site/v1".
7. Make sure that "Mark as IIS application on destination" is checked.
8. Click "Save" in the upper right hand corner.
9. Click "Publish".
IIS Settings
1. Security - Make sure that the "Directory Security" for the v1 Web Application is set to anonymous only. By default, both anonymous and windows authentication
will be enabled, but WCF/REST cannot have 2 different types of authenticaton modes enabled.
2. Default Web Site Application Settings
1. Bring up the properties window of the Default Web Site in your local IIS manager.
2. Click on the "Home Directory" tab and then on the "Configuration..." button.
3. On the "Mappings" tab, you will need to add a new application mapping.
1. Click on "Add"
2. For the "Executable" field, browse to the .Net 4.0 ASPNET_ISAPI dll (usually here "C:\WINDOWS\Microsoft.NET\Framework\v4.0.30319\aspnet_isapi.dll")
3. In the "Extension" field, type ".*"
4. Make sure that "Script engine" is checked.
5. MAKE SURE THAT "Check that file exists" IS NOT CHECKED!
6. Click "Ok". NOTE: If the "Ok" button is still disabled, click back in the "Executable" box, and the "Ok" should be enabled.
4. Restart IIS (run the "iisreset" command).
IIS Configuration for web service on Windows XP
Set IIS configuration to accept *.
.* is not allowed when ADD.
Click the INSERT button instead.
Saturday, April 17, 2010
Web service API - Rovi Cloud Service
http://developer.rovicorp.com/
(It's not so 'cloud' indeed but a web data service)
Team:
> 20 developers (US + HK)
> 5 QA (US + HK)
Responsibilities on backend data service support:
(It's not so 'cloud' indeed but a web data service)
Team:
> 20 developers (US + HK)
> 5 QA (US + HK)
Responsibilities on backend data service support:
- Feasibility studies
- Prototyping
- Implementation
- Data caching - Memcached/db
- Web Service APIs
- API Explorer
- Microsoft .Net
- Windows server 2008
- Memcached/db servers
- C#
- ASP.NET
- MS SQL Server
- Scrum
- JIRA
- Visual Studio 2008
- CruiseControl.Net
Sunday, February 28, 2010
Ubuntu Server
Performance and versatility
Fast, secure, deploy-anywhere technology for fast-moving companies
Secure, fast and powerful, Ubuntu helps you make the most of your infrastructure. Whether you want to deploy a web farm or deploy a cloud, Ubuntu Server supports the most popular hardware and software.
Our regular release cycle helps you keep pace with the latest tech developments. And our lean initial install, with thousands of easy-to-find packages, makes it a great solution for simple deployment and management at scale.
http://www.ubuntu.com/business/server/overview
Saturday, January 30, 2010
CruiseControl - Continuous integration
CruiseControl is both a continuous integration tool and an extensible framework for creating a custom continuous build process. It includes dozens of plugins for a variety of source controls, build technologies, and notifications schemes including email and instant messaging. A web interface provides details of the current and previous builds. And the standard CruiseControl distribution is augmented through a rich selection of 3rd Party Tools.
http://cruisecontrol.sourceforge.net/
Thursday, January 28, 2010
Memcached - NoSQL
What is Memcached?
Free & open source, high-performance, distributed memory object caching system, generic in nature, but intended for use in speeding up dynamic web applications by alleviating database load.
Memcached is an in-memory key-value store for small chunks of arbitrary data (strings, objects) from results of database calls, API calls, or page rendering.
Memcached is simple yet powerful. Its simple design promotes quick deployment, ease of development, and solves many problems facing large data caches. Its API is available for most popular languages.
http://memcached.org/
Free & open source, high-performance, distributed memory object caching system, generic in nature, but intended for use in speeding up dynamic web applications by alleviating database load.
Memcached is an in-memory key-value store for small chunks of arbitrary data (strings, objects) from results of database calls, API calls, or page rendering.
Memcached is simple yet powerful. Its simple design promotes quick deployment, ease of development, and solves many problems facing large data caches. Its API is available for most popular languages.
http://memcached.org/
Sunday, January 10, 2010
Meeting Room Reservation System
Team:
- 1 Software Engineer
- 1 Firmware Engineer
- 1 QA Engineer
- System design
- Database design
- Gather business requirements
- Server implementation
- UI implementation
- Deployment
- Maintenance
- Project management
- Used in Satellite office with 10+ meeting rooms.
- Provides online meeting room reservation service.
- Send confirmation, reminder emails.
- Show schedules and current status on meeting room LCD display.
- Realtime news and weather display.
- Visual Studio
- C#
- ASPX
- AJAX
- JQuery
- MySQL
- CSUnit
- SVN
Monday, September 28, 2009
Log4net - Logging
What is Apache log4net™
The Apache log4net library is a tool to help the programmer output log statements to a variety of output targets. log4net is a port of the excellent Apache log4j™ framework to the Microsoft® .NET runtime. We have kept the framework similar in spirit to the original log4j while taking advantage of new features in the .NET runtime. For more information on log4net see the features document.
http://logging.apache.org/log4net/
The Apache log4net library is a tool to help the programmer output log statements to a variety of output targets. log4net is a port of the excellent Apache log4j™ framework to the Microsoft® .NET runtime. We have kept the framework similar in spirit to the original log4j while taking advantage of new features in the .NET runtime. For more information on log4net see the features document.
http://logging.apache.org/log4net/
Monday, June 29, 2009
SMS Advertising System
Team:
- 2 Software Engineers
- 1 QA Engineer
Responsibilities:
- System design
- Database design
- Implementation
- SMS server connection
- Deployment
- Maintenance
- Project management
Features:
- Supports 10K+ members.
- Merchant advertisement submission.
- Automatic sends advertisement SMS
Thursday, May 28, 2009
SQLite
SQLite is a software library that implements a self-contained,
serverless, zero-configuration, transactional SQL database engine.
SQLite is the most widely deployed SQL database engine in the world. The
source code for SQLite is in the public domain.
http://www.sqlite.org/
serverless, zero-configuration, transactional SQL database engine.
SQLite is the most widely deployed SQL database engine in the world. The
source code for SQLite is in the public domain.
http://www.sqlite.org/
Monday, December 8, 2008
Philips 10-feet TV-Guide
Team:
- 2 Developers
- UI implementation
Features:
- 10-Feet TV-Guide on Philips TV
- Map keys on remote control
Development Details:
- Visual Studio
- ASPX
- AJAX
- Javascript
Monday, September 29, 2008
CDN - Content Delivery Network
A content delivery network (CDN) is a large distributed system of servers deployed in multiple data centers in the Internet. The goal of a CDN is to serve content to end-users with high availability and high performance. CDNs serve a large fraction of the Internet content today, including web objects (text, graphics, URLs and scripts), downloadable objects (media files, software, documents), applications (e-commerce, portals), live streaming media, on-demand streaming media, and social networks.
Reference: Wiki
Sunday, September 28, 2008
CSUnit
What Is csUnit?
csUnit is a free and open source unit testing tool for the .NET
Framework. Unit testing is tightly associated with test-driven
development (TDD), refactoring, and other practices from agile software
development approaches such as Extreme Programming or Scrum.
http://www.csunit.org/
csUnit is a free and open source unit testing tool for the .NET
Framework. Unit testing is tightly associated with test-driven
development (TDD), refactoring, and other practices from agile software
development approaches such as Extreme Programming or Scrum.
http://www.csunit.org/
Microsoft .Net
.NET is an integral part of many applications running on Windows and provides common functionality for those applications to run. This download is for people who need .NET to run an application on their computer. For developers, the .NET Framework provides a comprehensive and consistent programming model for building applications that have visually stunning user experiences and seamless and secure communication.
http://www.microsoft.com/net
http://www.microsoft.com/net
Friday, September 12, 2008
NUnit
What Is NUnit?
NUnit is a unit-testing framework for all .Net languages. Initially ported from JUnit, the current production release, version 2.6, is the seventh major release of this xUnit based unit testing tool for Microsoft .NET. It is written entirely in C# and has been completely redesigned to take advantage of many .NET language features, for example custom attributes and other reflection related capabilities. NUnit brings xUnit to all .NET languages.
http://www.nunit.org/
NUnit is a unit-testing framework for all .Net languages. Initially ported from JUnit, the current production release, version 2.6, is the seventh major release of this xUnit based unit testing tool for Microsoft .NET. It is written entirely in C# and has been completely redesigned to take advantage of many .NET language features, for example custom attributes and other reflection related capabilities. NUnit brings xUnit to all .NET languages.
http://www.nunit.org/
Tuesday, January 29, 2008
Debug ASP.NET web service deployed to IIS on Visual Studio
Debug -> Attach process -> Select the process that runs IIS.
Saturday, September 29, 2007
Cygwin - Linux like environment on Windows
Cygwin is:
a collection of tools which provide a Linux look and feel environment for Windows.
a DLL (cygwin1.dll) which acts as a Linux API layer providing substantial Linux API functionality.
Friday, September 28, 2007
Crypto++ Library - C++ library
Crypto++ Library is a free C++ class library of cryptographic schemes.
http://www.cryptopp.com/
http://www.cryptopp.com/
Thursday, September 28, 2006
Cornell CS
List of Computer Science Course Offered in Cornell.
http://www.cs.cornell.edu/Courses/ListofCSCourses/index.htm
http://www.cs.cornell.edu/Courses/ListofCSCourses/index.htm
Microsoft SQL Server
Microsoft SQL Server Overview
Enable a modern data platform with SQL Server 2012—get built-in mission critical capabilities and enable breakthrough insights across the organization with familiar analytics tools and enterprise-ready Big Data solutions. Common architecture and tools enable Hybrid IT infrastructures which help move your business forward and unlock new business models.
http://www.microsoft.com/sqlserver/en/us/default.aspx
Enable a modern data platform with SQL Server 2012—get built-in mission critical capabilities and enable breakthrough insights across the organization with familiar analytics tools and enterprise-ready Big Data solutions. Common architecture and tools enable Hybrid IT infrastructures which help move your business forward and unlock new business models.
http://www.microsoft.com/sqlserver/en/us/default.aspx
Thursday, August 17, 2006
TV Listing Data Delivery Service System
Team:
- 2 - 5 developers
- 2 QA
- Maintenance
- Feature enhancement
- Data pre-process backend
- Data serialization
- Data delivery backend
- Operator front-end
- Reader, packetizer implementation.
- Windows Server NT, 2003
- C++, COM+
- ASP
- Oracle
Saturday, April 15, 2006
Secured VNC on Windows plaform
- Cgywin
- SSH server
- VNC server
- SSH connection
- Port forward
Tuesday, September 20, 2005
Mobile TV-Guide System
Team:
- 3 Software Engineers
- QA Team
- Outsource Vendor
Responsibilities:
Features:- Protocol design
- System design
- Database design
- Gather features requirements
- Implementation
- Coordinate with vendor - mPortal
- System optimization
- System maintenance
- Provide deployment packages
- Platform migration
- Manage development life cycle
- Documentations
- Field test and fine tuning
- Setup production servers in Tulsa, US (1 x Load Balancer, 2 x Data Server, 2 x App Server)
- Support US market (100K+ Subscribed users)
- Mock service for Japan, Euro market.
- Provide TV listings data on Mobile devices.
- Stores user bookmarks on server.
- Program recommendations.
- Set SMS watch reminder to mobile.
- Supports remote recording on home TV recorder.
- Supports advertisement submission.
- Connection to SlingBox.
- Connection to Toshiba DVR.
- Visual C++, Visual Studio
- Windows NT, Server 2003
- C++, C#
- COM+
- ASP, ASPX
- Web Services
- MS SQL Server
- Oracle database
- DOM parser
- SOAP
- Test-Driven Development
- NUnit, CSUnit
- Log4Net
- XMLParser
- Proprietary binary communication protocol.
- J2ME
- Nokia Phone, Emulator
- Motorola Phone, Emulator
- CVS
Field Tests:
- CA, US (94103)
- CES - LV, US
Remarks:
- Business requirements comes from US team.
- Handles US Daylight saving issues.
Friday, June 25, 2004
Japan Web G-Guide
Team:
- 2 Software Engineers
- 1 QA Engineer
- Implementation
- Documentations
- Support Web G-Guide on Japan.
- 10K+ Featured Recorders.
- Provides TV listings data on web.
- Supports remote TV recording.
- Communicate with Panasonic servers.
Development Details:
- Visual C++
- Windows NT
- COM+ - dlls to communicate with database, remote servers.
- ASP - serve web UI
- Cryptography - Crypto++
- Oracle database - provide listings data
- CVS
Tuesday, June 17, 2003
Research on Semantic Web
Team
- 1 developer
- Research project
- Java
- MySQL
- HTML
- Javascript
- Servlet
- Apache web server
- MVC
Sunday, September 29, 2002
Network Programming and System Design
Client-server system design; interprocess communication; sockets; blocking and nonblocking I/O; multi-threaded process; iterative and concurrent server designs; system throughput bottlenecks; object-oriented programming (Java); case studies: FTP, RPC, Web.
Reference: CUHK MScIE
Saturday, September 28, 2002
Optical Communication and Lightwave Networks
Optical fiber and transmission characteristics, optical sources (lasers and light-emitting diodes) and transmitters, photodetectors and optical receivers, optical passive and active components: couplers, filters, switches, modulators, EDFA and Raman amplifiers, etc., optical system design, lightwave systems and networks: undersea systems, optical multi-access network design, SONET/SDH, fiber-in-the-loop, passive optical networks, optical network management.
Reference: CUHK MscIE
System Administration and Network Security
This is a 10-12 week workshop for students to gain hands-on experience in system administration and network security. Students are expected to spend at least 3 hours per week on the experiments, and each student will be assigned a Linux-based computer. The computer can be accessed via Internet so that experiments can be carried out at home. Selected topics include the set up of DNS and mail servers, the set up of certificate and secured web server for e-commerce applications, the use of network monitoring tools such as SNMP, TOP, MRTG, and tepdump, the set up of firewall, intrusion detection, and hacking techniques.
Reference: CUHK MscIE
Wireless Communication System
Physical characteristics of radio channels, cellular coverage, noise and interferences; radio modem technologies; channel assignment by frequency, time, or code division; handoffs and mobility management; wide area wireless network case studies: GSM and 3G; local area wireless network case studies: IEEE 802.11 and IEEE 802.15; principles of satellite communications, introduction to GPS system. (Not for students who have taken IERG4100)Physical characteristics of radio channels, cellular coverage, noise and interferences; radio modem technologies; channel assignment by frequency, time, or code division; handoffs and mobility management; wide area wireless network case studies: GSM and 3G; local area wireless network case studies: IEEE 802.11 and IEEE 802.15; principles of satellite communications, introduction to GPS system.
Reference: CUHK MscIE
Multimedia and Distributed Networks
Multimedia technology and trends, overview of compression techniques, multimedia storage server design, multimedia network architectures and protocols, operating system support for multimedia applications, multimedia traffic analysis, multimedia system design such as buffer design, traffic shaping, scheduling and congestion control. Advanced Internet protocols such as RSVP and RTP. Research papers on distributed multimedia and advanced Internet protocols.
Reference: CUHK MscIE
Computer Networks
Overview of the OSI reference model; local area network; internetworking components (switches, bridges, routers, etc.); Internet protocols; socket interface; presentation and application protocols; network administration and management; network security; network system case studies.
Reference: CUHK MscIE
Artificial Intelligence
Artificial intelligence (AI) is the intelligence of machines and the branch of computer science that aims to create it. AI textbooks define the field as "the study and design of intelligent agents" where an intelligent agent is a system that perceives its environment and takes actions that maximize its chances of success. John McCarthy, who coined the term in 1955, defines it as "the science and engineering of making intelligent machines."
Reference: Wiki
Neural network
The term neural network was traditionally used to refer to a network or circuit of biological neurons.[1] The modern usage of the term often refers to artificial neural networks, which are composed of artificial neurons or nodes. Thus the term has two distinct usages:
Biological neural networks are made up of real biological neurons that are connected or functionally related in a nervous system. In the field of neuroscience, they are often identified as groups of neurons that perform a specific physiological function in laboratory analysis.
Artificial neural networks are composed of interconnecting artificial neurons (programming constructs that mimic the properties of biological neurons). Artificial neural networks may either be used to gain an understanding of biological neural networks, or for solving artificial intelligence problems without necessarily creating a model of a real biological system. The real, biological nervous system is highly complex: artificial neural network algorithms attempt to abstract this complexity and focus on what may hypothetically matter most from an information processing point of view. Good performance (e.g. as measured by good predictive ability, low generalization error), or performance mimicking animal or human error patterns, can then be used as one source of evidence towards supporting the hypothesis that the abstraction really captured something important from the point of view of information processing in the brain. Another incentive for these abstractions is to reduce the amount of computation required to simulate artificial neural networks, so as to allow one to experiment with larger networks and train them on larger data sets.
Reference: Wiki
Computer Graphics
Computer graphics are graphics created using computers and, more generally, the representation and manipulation of image data by a computer with help from specialized software and hardware.
The development of computer graphics has made computers easier to interact with, and better for understanding and interpreting many types of data. Developments in computer graphics have had a profound impact on many types of media and have revolutionized animation, movies and the video game industry.
Reference: Wiki
Machine Vision
Machine vision (MV) is the technology and methods used to provide imaging-based automatic inspection and analysis for such applications as automatic inspection, process control, and robot guidance in industry. The scope of MV is broad.
Reference: Wiki
Reference: Wiki
Wednesday, February 20, 2002
Document Management System
Team:
- 2 Developers
- Product design
- Implementation
- Documentations
- Stores documents on intranet web based system
- Support small~mid size company with 5 - 50 users.
- Support viewing different document formats
- Support markup on documents
- Document version control
Development Details:
- J2SE
- Servlets
- MySQL database
- MS Source safe
Thursday, September 28, 2000
OpenGL
The Industry's Foundation for High Performance Graphics.
http://www.opengl.org/
http://www.opengl.org/
DirectX SDK
Overview
This DirectX SDK release contains updates to tools, utilities, samples, documentation, and runtime debug files for x64 and x86 platforms.
For additional information please see Microsoft DirectX Developer Center along with reviewing the Readme for last-minute updates.
Users wishing to install the DirectX runtime for the purposes of playing a game should instead install the DirectX Websetup. See related resources at the bottom of this page.
J2EE
Java Platform, Enterprise Edition (Java EE) 6 is the industry standard for enterprise Java computing. Utilize the new, lightweight Java EE 6 Web Profile to create next-generation web applications, and the full power of the Java EE 6 platform for enterprise applications. Developers will benefit from productivity improvements with more annotations, more POJOs, simplified packaging, and less XML configuration.
http://www.oracle.com/technetwork/java/javaee/overview/index.html
Apache Server
The Number One HTTP Server On The Internet
The Apache HTTP Server Project is an effort to develop and maintain an open-source HTTP server for modern operating systems including UNIX and Windows NT. The goal of this project is to provide a secure, efficient and extensible server that provides HTTP services in sync with the current HTTP standards.
http://httpd.apache.org/
Saturday, September 28, 1996
Matlab
MATLAB® is a high-level language and interactive environment for numerical computation, visualization, and programming. Using MATLAB, you can analyze data, develop algorithms, and create models and applications. The language, tools, and built-in math functions enable you to explore multiple approaches and reach a solution faster than with spreadsheets or traditional programming languages, such as C/C++ or Java™.
You can use MATLAB for a range of applications, including signal processing and communications, image and video processing, control systems, test and measurement, computational finance, and computational biology. More than a million engineers and scientists in industry and academia use MATLAB, the language of technical computing.
http://www.mathworks.com/products/matlab/
Mathematica
What Is Mathematica?
Almost any workflow involves computing results, and that's what Mathematica does—from building a hedge fund trading website or publishing interactive engineering textbooks to developing embedded image recognition algorithms or teaching calculus.
Mathematica is renowned as the world's ultimate application for computations. But it's much more—it's the only development platform fully integrating computation into complete workflows, moving you seamlessly from initial ideas all the way to deployed individual or enterprise solutions.
http://www.wolfram.com/mathematica/
Subscribe to:
Posts (Atom)
