SPA Asp.Net Core Architecture - asp.net

I want to build web app with real time communications with other web app via WebSocket.
For making WS one connection it's better to build SPA app.
Unfortunattely Angular 2 + Asp.Net Core seems not to be clear and stable.
Furthermore I want to use Asp.Core libraries such as Identity
May be its better to use ViewComponents and reloads them according to WS messages without reloading View?
Any Idea about better app architecture?

Friend, you appear to be in way, way, way over your head. Let me just provide some very basic assistance to try and move you in the right direction.
If you are going to be using ASP.NET or ASP.NET CORE for real-time communications, you would likely use the ASP.NET SignalR library. SignalR (https://www.asp.net/signalr) supports Web Sockets but falls back to other techniques for older browsers which do not support them. It is very feature rich and integrates well with legacy ASP.NET or ASP.NET Core. (Microsoft provides versions for both.)
ASP.NET Core is stable now, but it is still not feature complete--particularly in regards to Entity Framework. However, for most green-field applications, that is to say, most new development, ASP.NET Core is a perfectly reasonable development choice. ASP.NET Core offers many great benefits--like the ability to deploy your .NET code on a Linux server. Application builds are much faster than legacy .NET (e.g. .NET 4.6).
Yes, ASP.NET Identity is a great choice for Identity Management (although I typically use IdentityServer4.) You will most certainly need to extend ASP.NET Identity to use it. (For example, most people extend AppUser with custom user properties. For a Single Page Application, you will probably also want to use JSON Web Tokens (JWT) (https://jwt.io/)). There are many other extensions to ASP.NET Identity you can (and probably will) make. They all require some basic familiarity with ASP.NET Identity's internal architecture. (I recommend the tutorials from Taiseer Joudeh. (http://bitoftech.net/category/asp-net-identity/) They are for ASP.NET 4.x but can be easily migrated to ASP.NET Core. The output of these tutorials can also form a really great foundation for your own identity system.
To develop a SPA (Single Page Application), you are going to want to use a front-end framework. By far, the two most popular frameworks are Google's Angular2 (http://angular.io) and Facebook's React (https://facebook.github.io/react/).
Based on what I am gathering from your post, you may not have much experience in these technologies. ASP.NET Core, SignalR, the (necessary) extension of ASP.NET Identity, Angular2/React, all have significant learning curves. By significant, I really mean SIGNIFICANT--which you can measure in months.
You will need to be familiar with Gulp to use as a Task runner under ASP.NET Core. I recommend using Visual Studio 2015 or Visual Studio 2017 for ASP.NET Core development. You can also get by quite nicely with Visual Studio Code.
Beyond that, there are a whole host of other tools you need to be familiar with to effectively develop for these platforms--particularly on the front-end.
For example, to do effective Angular2 development (which is my recommendation for SPA front ends), you are going are really going to need to know or be able to use all of the following: Git, ES6, TypeScript, RxJS, JSON, Node, NPM, angular-cli, Jasmine, Karma, Protractor, CSS, Sass/SCSS, Bootstrap or Angular Material, Webpack, Angular Universal, etc. There are actually quite a few other tools/libraries you will want to utilize, but this will give you a good enough starting point.
On the client front end, you will most assuredly not want want to use Visual Studio. It is a real pain to set up for front-end JavaScript development. (The Angular2 setup for Visual Studio 2015/2017 is a bear.) You will probably use Visual Studio Code, Sublime Text, Atom, or Webstorm.
Most organizations employ an entire team of people to work on SPA apps. Some of the team members may include the following: Graphic Designer, CSS Themer, Front-End Javascript Developer, Back-End Server Developer, DBA/Data Architect, Requirements Analyst, Build/Testing Specialist, Tester, Network Administrator, and Project Manager. Of course, in many projects, one person may fill multiple roles--or people may share roles. The key point is that SPA projects are complex enough that most projects have at least 2-3 team members--and often more. Even then, very experienced folks can still struggle to get those apps into production.
One question that I would also ask you is, "Do you really need a Single Page Application?" SPAs are great--really great! However, they require significantly more knowledge to develop and have much more complexity than other applications. If there is a good use case for developing an SPA, then more power to you. If not, then you might consider stepping back and doing something a little less ambitious until you get a better handle on what is possible.
I am not saying all of this to discourage you. I am simply trying to paint a realistic picture of what you need to be able to actually build and deploy a production SPA. I want you to know what you are getting yourself into and have somewhat of a guided path to success.
Good luck out there, my friend!
Update: Added more detail on my current tool-set from a letter to a friend.
I have a good friend who is wanting to become a Web developer. I recently laid out a road map to assist him in his studies. I am simply copying and pasting that road map (and my letter to him) here to provide some additional details on the tools that I use (and mentioned above) along with some hint on the relative effort required to use them. He is just starting out so my descriptions of the tools are relatively non-technical. These are merely the ones I use, so please don't flame me if I left out your favorites.
...I wanted to go ahead and offer you a roadmap of where we are going by giving you a preview of the tools that I actually am using right now in my "development stack." (A "development stack" is the list of tools a person uses to code, build, and deploy projects.) Eventually, you will probably be using most of these tools (with the possible exception of some of the back-end development tools) or others that come after and replace them. This "stack" represents the tools that many of he top developers tend to use--although every developer has his own favorites. If you are going to jump head-first into this Web development career, then I am assuming you are going to want to be the best--because that is where the most rewarding projects are to be found--and the most lucrative ones as well.
As you read this list, you will probably be a bit overwhelmed by the sheer number of tools. I do this everyday, and I am still a bit overwhelmed by it. First, let me say that I do not necessarily use every tool everyday, but I do use every one of these tools sometimes. They are all indispensable to have in your arsenal. Second, let me also say that I am not an expert in every tool. You won't need to be either. There will be some tools that you absolutely master, some tools for which you need a very strong working knowledge, and some tools you just need the basics to get you by.
As we go forward, I am going to help you move in a very organized way of learning these tools. There are thousands of tools out there--many of which are useless or inferior. Knowing which tools you actually need will help focus you and prevent a lot of wasted time as you learn and grow. Beyond that, I will help you to get acquire the right knowledge in the right order to make the learning process as efficient and comfortable as possible.
It is perfectly fine for you to go ahead and begin to get familiar with some of these tools on your own. If you visit a site page and it all looks like gibberish now, don't worry about it. In a short while, it will all begin to make sense.
One thing I would note is that new tools are being introduced everyday. The technology is constantly evolving. I fully expect that, by the time you reach a moderate level of proficiency (some months from now), some of these tools may have begun to fade or even have been replaced entirely by others. Regardless, having learned the current incarnation of a tool will allow you to easily master the replacement tool.
I have categorized the tools in a somewhat logical order and provided a description for each tool; a link to a website; the required mastery level (Basic [working knowledge]|Strong [working knowledge]|Expert); and the approximate learning curve (assuming you were studying these things full time) to reach the required level of proficiency. Please note that many of the tools (e.g. code editors) can be used to some minimum level with a much lesser learning curve.
Code Editors
The first thing you are going to need for development is a good code editor. All of these are free (or have free or unlimited evaluation editions). I generally use Visual Studio Code for my front-end (Browser / JavaScript) development and Visual Studio 2017/Visual Studio Code for my back-end development (server side development.)
In addition to the core application, all of these have extensive libraries of community plugins. You will want to familiarize yourself with the available plugins and choose the ones which suit your needs and interests.
Visual Studio Code - http://code.visualstudio.com/ - Expert, 1 Day
Sublime Text 3 - https://www.sublimetext.com/3 - Expert, 1 Day
Atom - https://atom.io/ - Strong, 4 Hours
Visual Studio 2017 - https://www.visualstudio.com/vs/community/ - Expert, 1 Week
Core Web Technologies
HTML 5 - The core markup language of the Web. The structure of of Web page is defined in HTML. This is fundamental to everything else we will learn. https://developer.mozilla.org/en-US/docs/Web/Guide/HTML/HTML5 - Expert, 1 Week
Cascading Style Sheets (CSS) 3 - While HTML defines the structure of Web pages, CSS defines the thematic or stylistic elements (e.g. color, typographic, spacing of elements, etc.) of a page. CSS provides the "look and feel" of a page. For many good reasons, the structual and stylistic elements are kept entirely separate. https://developer.mozilla.org/en-US/docs/Web/CSS, https://developer.mozilla.org/en-US/docs/Web/CSS/CSS3 - Expert, 2 Weeks
JavaScript / EcmaScript / ES5 - JavaScript is the primary development language for the front-end--that is, to say, the browser. It handles much of the "interactivity" on a Web page but also provides functionality for sending data to and receiving data from the server in the background. JavaScript is the essential ingredient in modern Web applications. - https://developer.mozilla.org/en-US/docs/Web/JavaScript, Expert, 1 Month
Core Web Technologies Plus
While the core technologies are essential for any Web development project, they are simply not enough for serious Web projects. A number of frameworks and related tools have been developed on top of these technologies to either extend their capabilities or simplify their implementation.
Bootstrap 3/4 - Bootstrap is a CSS framework that simplfies theming sites and also makes them much more standard. CSS theming can be very tricky and difficult. However, Bootstrap will greatly speed your development. The current version of Bootstrap is 3. Version 4 is in alpha. We will learn both as version 4 primarily extends (and further simplifies 3.) We will learn Bootstrap 3 also because it is helpful in learning Bootstrap 4 and most companies are still using it--so you will probably need to know it. http://getbootstrap.com/ - Expert, 1 Week
Sass / SCSS / Syntactically Awesome Style Sheets - CSS can be tricky, cumbersome, and very time consuming. Theming a website can take days or even a week or more. This is time that can be filled with much pain and many tears. Most of the frustrations in CSS come from the way different browsers implement (or fail to implement) the standards. Sass is known as a "CSS pre-processor" and helps to speed CSS development and also helps to fill in the gaps for functionality vendors failed to implement in a standard way. Sass (or its latest SCSS implementation) will eventually become your trusted and well-loved friend. http://sass-lang.com/
Google Fonts - Typography can make a mediocre Website really "pop." Google provides many free Web fonts that can be used easily in any site. https://fonts.google.com/ - Strong, 2 Hours
Font Awesome - Font Awesome provides many useful and standard icons which can be included on websites. You will make use of Bootstrap, Google Fonts, and Font Awesome in almost all your projects. They all work well together. - http://fontawesome.io/ - Strong, 2 Hours
ES6 / EcmaScript 6 / ES 2015 / EcmaScript 2015 - Plain old JavaScript (ES5) has some serious limitations. A newer version of the language was released in 2015 which adds some much needed functionality. Unfortunately, not all browsers support this latest version. Fortunately, there are translators (called transpilers (e.g. Babel)) which can allow us to write ES6 code and then translate it back into the older JavaScript that browsers understand. We will definitely be mastering JavaScript, ES6, and its successor (TypeScript, described below.) - http://es6-features.org/ - Expert, 2 Weeks
TypeScript - While one could consider ES6 to be a wrapper around plain JavaScript that provides additional functionalities, TypeScript can be viewed as a wrapper around ES6 which provides newer JavaScript functionality which was not part of the ES6 standard. In other words, TypeScript > ES6 > JavaScript (ES5). Just like with ES6, TypeScript can be translated (transpiled) back into either ES6 or ES5. Angular 2 uses TypeScript for its development. A mastery of TypeScript will not only be necessary for other Web development, but it is also necessary for learning and mastering Angular 2. NOTE: Eventually, all of functionality in TypeScript will make it's way into the browser (as will ES6) and the transpilation step will no longer be required. - Expert, 2 Weeks
Babel - Babel is the tool you will use to tranform or transpile ES6 to plain old ES5 JavaScript. The tool is very simple to use. Most of the time, this will be managed for you in the background (by your build system - Webpack or Gulp). Still, it is necessary to have a basic working knowledge of the tool. - https://babeljs.io/ - Basic - 4 Hours
(Google) Chrome Debugger OR Safari Web Tools - Both Google and Safari are based on a browser engine called Webkit (https://webkit.org/.) Both include essential (and almost identical) tools for debugging Web pages. You will need to absolutely master the Chrome Debugging tools, and this is something that will eventually happen with continued use. You'll spend some time initially getting familiar with these tools and will then proceed to a deeper more intimate knowledge of them as you use them. - https://developer.chrome.com/devtools - 1 Day
Web Frameworks
Angular 2 - Leading JavaScript framework provided by Google for developing "modern Web applications." Angular 2 is very much the future of the Web. It is fast and powerful. Angular 2 developers are also in extreme demand and are very well ($$$) paid. This is the first framework we will learn, and it has a fairly steep learning curve. We won't even begin to study it until we have a near mastery of JavaScript, ES6,and TypeScript. - http://angular.io. - Expert, 1-2 Months.
React - Leading framework provided by Facebook for developing "modern Web applications." Frankly, I am not a huge fan of React, but many developers love it. I think you definitely should learn it because 1) there are many React jobs, and 2) learning React is very easy if you already know Angular 2. It just makes you much more marketable. - http://www.typescriptlang.org/ - Expert, 1 Month.
In addition to just the core "Angular 2" framework, there are at least three other supplemental "power tools" you will need that help you to really be able to take Angular 2 to its full potential.
Angular-Cli - The Angular Command Line Interface (CLI) allows you to quickly generate boilerplate Angular 2 code files and perform a variety of useful tasks. I have found this tool to be indispensible, and it greatly enhances my productivity. - https://cli.angular.io/ - Expert, 1 Day
Angular Universal - Angular Universal is a tool for generating/rendering elements of Angular 2 on the server rather than in the client's browser. This can dramatically improve load times and making the page more search-engine friendly. Angular Universal is a key component of Search Engine Optimization (SEO) with Angular 2. - Strong, 1 Week
Reactive Extensions for JavaScript / RxJS - RxJS is a library that provides core functionality for building modern Web applications. It's foundation component is an entity called an "observable." For the moment, Observables would be bit challenging to explain other than to say this. An Observable kind of "subscribes" to a piece of data and then allows the system to "do something" when that data changes. While this may seem trivial, it is not. It opens the door to much other functionality. This is an advanced concept used in Angular 2--and one we will explore deeply concurrent with learning that framework. - https://github.com/Reactive-Extensions/RxJS - Strong, 3 Days
Core Tools
NodeJS - NodeJS is a Javascript "environment" based on the JavaScript engine found in Google Chrome. It allows you to run JavaScript applications outside of a Web browser. Most of the tools we will use involve NodeJS in one way or another. Initially, you will just need to develop a very basic familiarity with NodeJS, but you would be well served to deepen this knowledge over time. - https://nodejs.org/en/ - Basic, 4 Hours
Node Package Manager / NPM - The Node Package Manager (based on NodeJS) is the tool we use to download most of our other software and libraries. Almost every other package we have listed in this document is installed using NPM. It is a simple but indispensable tool. https://www.npmjs.com/ - Basic, 4 Hours
Task Runners
As noted in the ES6 and TypeScript descriptions, there are often multiple steps to get your original source code files into a format where they can be deployed into production--or even run/viewed locally in your browser. To get your ES6 files into old-style ES5 JavaScript, you will use Babel. To transpile your TypeScript files into ES6 or ES5, you will use the TypeScript compiler (tsc). You will want to perform these translations every time you modify a file. Beyond simply compiling, there are often many other tasks you will repetitively perform such as moving files from your source code directory to your "build" directory (the directory where you will run the files) on your PC. Sass also will be converting your SCSS files to standard CSS files. Suffice it to say, there are many repetitive tasks that you will not want to do manually. A "task runner" will do them for you.
Two task runners we will use are Gulp and Grunt. Gulp and Grunt allow you to define a series of tasks into some "command" and then have that command (optionally) run automatically for you whenever there are file changes. Gulp is the primary task runner you will use. Grunt is kind of falling by the wayside but is still in widespread enough use that you will need to be familiar with it. There are also many "plugins" for these systems you will also become familiar with and use.
Gulp - http://gulpjs.com/ - Expert, 1 Day
Grunt - http://gruntjs.com/ - Strong, 4 Hours
Build Systems
While Gulp and Grunt can help you build and deploy your Web sites / Web applications, there are two other systems which are particularly suited to this task. You will eventually need to become very familiar with both of them. Angular 2 uses Webpack.
SystemJS - https://github.com/systemjs/systemjs - Expert, 1 Day
Webpack - https://webpack.github.io/ - Expert, 2 Days
Docker - Docker is technology used for packing sites into containers and deploying the site as a unit. It is relatively new, but the entire market is moving to use it. You will be well served to know it. - https://www.docker.com/ - Working, 1 Day
Source Code Versioning and Control
Git - When developing websites, you will need to be able to track your changes and roll back to a previous version if something goes "horribly wrong"--which it often will. Git is, by far, the most popular version control system. Also, many websites (like GitHub) allow you to use it to pull down software from their sites (called repositories.) You will want to be very familiar with Git. - https://git-scm.com/ - Basic, 4 Hours
JavaScript Testing Tools
Testing is a critical part of any development. It also happens to be one of the most time consuming. You will eventually get familiar with a number of different test tools--all of which perform slightly different functions.
Jasmine - JavaScript Unit Test Framework - https://jasmine.github.io/ - Strong, 1 Day
Karma - JavaScript Test Runner - https://karma-runner.github.io/1.0/index.html - Strong, 1 Day
Protractor - End to end (e2e) test Framework for Angular - http://www.protractortest.org/ - Strong, 1 Day
Istanbul - Code coverage analyzer for JavaScript - https://github.com/gotwarlost/istanbul - Strong, 1 Day
.NET Development
Once you master client-side development, you may decide you want to learn server-side development as well--or you may feel perfectly comfortable continuing to focus on the client. Either is fine. Just for the sake of completeness, here are the tools I genereally use for server-side development.
ASP.NET Core - Microsoft's new server-side web framework which runs on Windows, Linux, and OS/X. The framework is very robust and highly performant. ASP.NET is used by many businesses for developing core line-of-business applications. For example, many banks use ASP.NET or ASP.NET Core to develop Internet banking websites. - https://www.asp.net/core
ASP.NET Identity - This is the Microsoft library for handling user and account management. This is actually a large part of the functionality in any Web application and has a number of very complicated pieces. ASP.NET Identity does most of the heavy lifting but is also very extensible. - https://www.asp.net/identity
ASP.NET SignalR - SignalR allows for real-time communications between a client (typically) and a browser--generally using a technologically called Websockets. Some example applications might be real-time chat, massively multiplayer online games, or a real-time stock ticker. - https://www.asp.net/signalr
Entity Framework 7 / Entity Framework Core - Much of the effort required to code back-end applications relates to storing and retrieving data from a database. Entity Framework abstracts much of that functionality and provides a much simpler way to store and retrieve data. https://www.asp.net/entity-framework, https://github.com/aspnet/EntityFramework
Microsoft SQL Server - Microsoft's database implementation. SQL Server works well with other Microsoft tools. It is great, and I have been using versions of it since 1995. However, I sometimes use MariaDB (https://mariadb.org/) and have been considering using PostgreSQL (https://www.postgresql.org/) or MongoDb (https://www.mongodb.com/) for some future projects. There is a free version of SQL Server available for development. All of the other database platforms mentioned are already open source. - https://www.microsoft.com/en-us/sql-server/sql-server-2016
Redis - Redis is a super-fast in-memory database. It is used by most of the high-end websites (including Facebook) for data-caching. Use of Redis in conjunction with SQL Server or MariaDb can greatly improve the overall performance of a website.
NUnit - NUnit is a unit test framework for .NET--which I used on the back-end. https://www.nunit.org/
Development Resources
There are a number of websites I access on a regular basis to assist me with development. The most important site is Stack Overflow which has over 12 million questions and answers on almost any development topic. It is an invaluable resource, and I use it every day. You will definitely want to create a free account there. I also frequently access GitHub to download various software and use Google to query thousands of other sites for specific information.
Stack Overflow - https://stackoverflow.com/
GitHub - https://github.com/

Related

What is a good easy to use framework for rapidly developing web apps with a C# backend?

I am after recommendations for a framework (or project template) for rapid application development using C# on the back-end. It must support the following:
User login/authentication
SPA
Responsive client
Easy to understand client and server (not a steep learning curve like AngularJS)
Clean/uncluttered project structure (both client and server). Some OOTB ASP.Net project templates are very cluttered (eg the the VS2012/2013 SPA MVC/Knockout/BackBone template) - maybe I could be convinced, but just looking at a new project it puts me off instantly.
Easy DB access.
Flexibility on the client (for custom functionality eg adding maps and other UI libraries like D3) - don't want a client framework that you have to wrangle to paint outside the lines.
Would appreciate any/all suggestions/opinions.
Thanks
Tim
Like anything in software, there are so many ways to do this. You are essentially asking for a complete system architecture. You could try to be more specific, but your question is going gather opinionated answers and this will probably end up getting closed.
But I'm bored and will throwin a couple of pennies before that happens:
C# most likely means you'll be going .NET on IIS (though maybe its docker on linux?? refer back to my first line above)
User login/authentication
If its IIS, you could be running Windows Auth, or if in an enterprise, Kerberos or Federation. Or if its going against social sites, maybe OAuth? This one depends on what authentication your users need and is really separate of the other areas below.
SPA / Responsive client / Easy to understand...
You listed some very popular frameworks (Angular/Knockout) used in modern SPAs. You may not like them but these are becoming industry standards. Responsive web is pretty much bootstrap or foundation. Though, angular material seems to be gaining popularity too.
Easy DB access.
Whats your definition of easy? Looking for an ORM? If so, Entity Framework is popular in .net apps. Or if you are more of an SQL person, maybe LINQ is easier. Many options here too.
Flexibility on the client ...
Though you may not like some of them, using popular frameworks means you get a lot of developer support behind it - and a lot more answers here on SO if you have problems. One man's sunset is another man's sunrise. What you consider difficult might be viewed as easy by another. Hard to say whats most flexible but going popular means you got more help.

MeteorJS Alternatives: Latency Compensation Frameworks and Libraries?

Effort:
I am building a word game based on a chat web-client where I need to make a server call on input chat text to validate it before broadcasting on the chat.
I am aware of Meteor providing latency compensation out of the box. But given its still in "early preview" makes me seek other alternatives.
What I tried:
Unfortunately my web search for "latency compensation framework library" doesn't yield anything other than Meteor (including non-personalized results).
Question: Are there any other alternatives that provide latency compensation -or- can make the job easier? I am hoping other developers might have encountered something useful/relevant.
Although Meteor is in 'early preview', its code is very close production ready and a lot of startups and other early adopters are using it for production-level code. You aren't going to find anything that gives you wings like Meteor because no such alternative exists.
As a hardcore Meteor convert and someone who's used many other frameworks, I recommend you to just try Meteor out. As they say, it only takes a weekend for you to build an app in Meteor and decide whether it's right for you.
Having said that, I will attempt to answer the question and list the distant-second alternatives to Meteor that you probably won't want to use:
Derby
Sails
What you're seeing right now in the various real-time full-stack Javascript web frameworks is the future of Web development, cutting down dozens of people and thousands of man-hours of work needed to develop a software project. There are some fast boats sailing that are leaving server-side rendering behind, and you should probably just get in one of them and get going.
RethinkDB uses term 'latency compensation'.
I've also tried to gather per-feature alternatives to Meteor
Meteor is a really cool framework. you can build the complex data driven application very easily using meteor.
But, this framework currently supports only the MongoDB as back-end database.
I have recently created full stack framework called Nooljs which is similar to the Meteor. Now I have open sourced it. It support all the database connections including MySql, ms-sql, and MongoDB. The complex data driven application can be created easily using this framework.
This has been developed using well known existing framework such as Angularjs, Node, express-js, and socket-io.
Easy to build complex data driven JavaScript applications with minimum coding.
Support multiple data connections suck as Ms-sql, MySQL, PostgreSQL, and Mondodb.
Real time framework build top of Express-js and Socket-io
The client side is powered by the Angularjs.
The layout can be build using the Angularjs tags and elements.
Modularized layout to simplify the complex web pages.
Can be mixed both Express-js and Socket-io

Whether to use CMS or not

I've started to wondering whether ASP.NET Webforms/MVC even have a place in the web developers toolbox anymore... It seems that CMS systems like Umbraco have replaced the web developers job. Yes I know that those CMS systems are built with ASP.NET Webforms/MVC - however is there even any reason for learning those things if all you gonna do is to use a CMS system anyway? - Also I cant find any situation where a CMS system can be replaced by your own web application.
My question is therefore: Is there any reason for learning Webforms/MVC when using a CMS?
EDIT:
My question might be more like: When should I use a CMS, and when should I go and build my own web app?
The problem with CMS solutions, and I mean all CMS solutions (not just Umbraco, or other .NET solutions, but in any language) is that you will always pay a price for using them. You may gain more from the time-savings afforded by using the CMS, but there are trade-offs to consider:
You will sacrifice a great deal of flexibility
You could pay a significant performance penalty. Many CMSs load a large amount of modules and code to service every request, and much of this is not relevant to a particular page function. (though some CMSs are more monstrously heavy than others!)
The future of your project is tied to yet another vendor, and their own choices
Very often, you rule out the possibility of using other databases that might have better fit your customer's needs (Umbraco doesn't support PostgreSQL, Kentico only supports SQL Server)
Once you start using a CMS you will be tied into satisfying the architectural decisions and API of the CMS framework, and you could eventually be backed into a corner.
This can be particularly problematic if your 'site' is more of a web application than a pure content delivery site. In such cases it can make more sense to choose to build using the full flexibility of the web application framework, rather than risk getting backed into an architectural corner.
On the other hand, if you are building a web site that has potentially hundreds of pages, with a lot of user-contributed content and is much less of a web application, then often a CMS is the way to go, and makes a lot of sense. But remember, you now have two frameworks and two APIs to learn and manage (your platform's framework and the CMS framework).
Writing a CMS is like invading Afghanistan.
Everybody gets a turn but nobody wins.
I don't think that Stack Overflow could have been built with a CMS. Does that answer your question? =)
Update
To answer your updated question.
If you want a regular corporation web containing news, articles, forum etc: Go ahead and use a CMS.
If you need to build a more custom web site like stackoverflow, a web interface for a system or anything like that: Built it using MVC etc.
I personally use a CMS for our corparate website and a MVC framework to build user and administration interfaces for our products.
Not every problem needs a CMS. In the same way not every problem needs a bespoke MVC/webforms website. It depends on what your requirements are. You pick the technology to solve the problem.
Build vs buy is the hardest decision to make. As a developer build always looks best. You can do better than that pile of carp they want to buy. Nevermind that you're reinventing the wheel, axel, cart, etc. To users/management buy always looks best. They don't have to think to hard about what they want and can have it now, not 3 months later after you write it. They forget it'll cost the same again to customise & make it impossible to upgrade.
I'll stop ranting now.
Umbraco is a pretty bare minimum CMS. To customize it (e.g. Version 7+) you'll need to know Heavy MVC, JSON, XML, Sql, etc.
In fact a Site built on Umbraco 7+ is entirely based on MVC views you set yourself and assign to SurfaceControllers (which are MVC controllers) and all you are really getting is the ability for users to edit things about your pages and have Umbraco manage it for you in a DB.
In short you still need experienced web developers to build a site on Umbraco, they just save a lot of time by not having to build the entire backend from scratch.
You use Umbraco to organize Document Types that define what Templates (MVC Views) are used for rendering different types of documetns (e.g. Web Pages) and then you built the template from the ground up with 100% control over the HTML, Css, and Javascript that get's output.
Imo Umbraco is more of a Framework like Django than a complete CMS.
Sure you can build a site in Umbraco and not customize anything, but it would be a pretty cheesey site.
The whole point to Umbraco is to give skilled .Net Developers a good platform for building a site on top of it, but they still have to build it.
Now sharepoint would be more of a complete CMS out of the box that you can do a lot with, but let's see a few problems with SharePoint...
Resource Heavy, eats 50+ Gig's to install
Eats 16 GB of ram just to boot it up (Sharepoint 2013)
Requires Sql Server 2008 R2 or equivalent (enterprise license, $$ chaching)
Requires Windows Server ($$chaching)
It's a monster basically, if all you need is a user editable blod platform... man what a waste of money. Foundation is free, but doesn't include things like the Blog Site Template, so you buy a server enterprise license ($$ big cachinge, 40,000$+ in some scenarios...)
Agreed. A CMS like Umbraco provides a (very) good out-of-the-box solution for the most basic applications. Any sort of specialized purpose is going to require additional programming knowledge. Anymore, though, and your major, if not primary need is going to be a good understanding of the business need. I think we're getting away from building the Legos themselves and on to building the neat toys with the Legos. Cheers!
A CMS (or similar application framework) will provide you with a lot of functionality out of the box, and many of them also have a good library of plug-ins. But you'll still need to write WebForms/MVC code if you want to add any custom features.

ASP.Net or WPF (C#)? [closed]

Closed. This question is opinion-based. It is not currently accepting answers.
Want to improve this question? Update the question so it can be answered with facts and citations by editing this post.
Closed 8 years ago.
Improve this question
Our team is divided on this and I wanted to get some third-party opinions.
We are building an application and cannot decide if we want to use .Net WPF Desktop Application with a WCF server, or ASP.Net web app using jQuery. I thought I'd ask the question here, with some specs, and see what the pros/cons of using either side would be. I have my own favorite and feel I am biased.
Ideally we want to build the initial release of the software as fast as we can, then slow down and take time to build in the additional features/components we want later on. Above all we want the software to be fast. Users go through records all day long and delays in loading records or refreshing screens kills their productivity.
Application Details:
I'm estimating around 100 different screens for initial version, with plans for a lot of additional screens being added on later after the initial release.
We are looking to use two-way communication for reminder and event systems
Currently has to support around 100 users, although we've been told to allow for growth up to 500 users
We have multiple locations
Items to consider (maybe not initially in some cases but in future releases):
Room for additional components to be added after initial release (there are a lot of of these... perhaps work here than the initial application)
Keyboard navigation
Performance is a must
Production Speed to initial version
Low maintenance overhead
Future support
Softphone/Scanner integration
Our Developers:
We have 1 programmer who has been learning WPF the past few months and was the one who suggested we use WPF for this.
We have a 2nd programmer who is familiar with ASP.Net and who may help with the project in the future, although he will not be working on it much up until the initial release since his time is spent maintaining our current software.
There is me, who has worked with both and am comfortable in either
We have an outside company doing the project management, and they are an ASP.Net company.
We plan on hiring 1-2 others, however we need to know what direction we are going in first
Environment:
General users are on Windows 2003 server with Terminal Services. They connect using WYSE thin-clients over an RDP connection. Admin staff has their own PCs with XP or higher. Users are allowed to specify their own resolution although they are limited to using IE as the web browser.
Other locations connects to our network over a MPLS connection
Based on that, what would you choose and why?
I am especially interested in hearing from developers who have experience with both ASP.Net and WPf.
Reasons to choose WPF:
Much faster and easier development than ASP.NET and jQuery
Much easier to implement quick incremental background loading of data
Much easier to implement client-side caching of commonly used data (important for remote offices)
More efficient data transfer from server (can use advanced WCF features unavailable to web browser)
Keyboard navigation better, since you can easily define shortcuts, etc, and not be limited by browser
Maintenance overhead much better using MVVM pattern
Softphone integration easy
Reasons to choose ASP.NET and jQuery:
None that I can see
In your scenario I would definitely choose WPF.
First of all, I would sit down and write the business requirements and specifications. It really doesn't matter what tech you use - proper planning will affect your project timeline more than technology choice. This is especially true for an in-house custom built app.
As far as development, I would take the requirements and lay out the backend functionality. I would actually implement the backend in WCF, regardless of the client technology - that way you could use best of both worlds if needed (for example for phone integration you could write a stand-alone WPF app). ASP.NET with jQuery can easily use WCF services (JSON or XML version) together with desktop client.
As far as development of the client forms, this highly depends on developers experience and your future plans. I am not going to go into advantages/disadvantages of developing web software here - there are a ton of articles in the last 10 years about cloud/web based software (for example salesforce). I would rather concentrate on deliverables - what is your team most comfortable with today and in the future. There's a huge difference between WPF and web development, from development standpoint, and it requires completely different experience.
Why not consider a hybrid solution - Silverlight
With Silverlight you get most of the goodness and statefullness of WPF (with almost exactly the same XAML and code), plus you get the deployment characteristics of ASP.NET
Many people consider Silverlight the next step after ASP.NET/AJAX, and it would definitely deliver all of the benefits of WPF relevant to your scenario.
WPF is the way to go, without a doubt. I agree with all that #Ray Burns has said.
Because:
You will get a richer, slicker, faster application.
It will be easier to build1.
Softphone/Scanner (i.e. hardware) integration is going to require browser plugins etc. and this can be a nightmare with a browser based application.
Keyboard navigation is still better with native applications.
IME Maintenance is easier with WPF applications.
Definitely use WCF to provide the backend via The Entity Framework, see The Entity Framework In Layered Architectures. You can do have a better integration with the backend in a native application because it can be called inline - no need for callbacks or ajax. I've built components for WPF that are linked via EF to the business logic to provide aware controls for simple stuff like validation. It's stunningly good to drop a customer name field onto a form and it just works.
To add additional components you need to build it with a proper well thought out plugin architecture. This is the same in both environments. I've got some thoughts on this I jotted down in my journal entitled Designing a plugin architecture for an application
When building a WPF application you will be writing in one language (e.g. C#) + markup (XAML). When building asp.net you endup with two languages + markup, as you always have to code some Javascript.
So, based on your requirements it has be to WPF / WCF (EF). A web based application will be a lot more work, more complexity, and not be as nice.
About 12 months ago I was fortunate enough to be given a free hand to choose the technology for a new application. I spent almost a month evaluating all of the options and came to the conclusion that it had to be C#, WPF, Entity Framework. After writing the application I can confirm that it was the right choice...
1. It will still be easier even if your programmers have to learn WPF first. WPF is much better thought out, great and lovely. very lovely. It just works right.
Hi
I think The question at issue is Windows-application or Web application(WPF for win-app VS asp for web-app), Which one is better for you and your project?. In this case your platform is network and your program must work on the net. so for this usage Web-app is better but there are a lot points existing which can make decisions hard. Network platform has great challenge.(according to my personal experience)
Working with web-app by asp.net is nearly hard. you must try to handle many thing's for web-app(request time, session management, even poor UI in comparison to WPF, j-query, etc ). Remember this is not as easy as simple web site.
But win-app is good for network with this condition: "local network"(mpls is almost the same). Absolutely developing win-app is easier than web-app ("At least number of users expert in net-program developing"). for this case WPF has many good things(UI , command, etc) also has many challenging point(like multi-threading and lack of expert developer in this field ) . I'm rather with wpf than asp but decisions is yours
And chalk point to good thing Silverlight but if you want to use this you must look at prism framework : http://compositewpf.codeplex.com/
I have recently developed a project separately with asp and silverlight(prism framework). developing silver-light version is too hard and takes more time than asp.net version but at the end SL-ver have great look nothing else!
Burns pointed to good issues about wpf. also consider Artemiy's post. your environment conditions is same for both of them. WPF/ASP can work with scanner and soft-phone cuz the base of both is on C# and .net library
Finally what ever your decisions is you must hire advance developer at least develop one business-app for the network platform.
Is your app a desktop app or web app.
If Desktop wpf is best.
If web based asp.net is best.
Don't front load your development with your get it up quick scenario. That never works well and results in a sloppy deployment. Take your time, cover all the steps (Business Requirements, System Design, Program Design, Code, TEST and TEST some more, Deployment)
Some points to be made for ASP.NET:
The pool of ASP.NET developers is much larger then the pool of WPF developers.
Which means you can probably find qualified ASP.NET developers easier.
ASP.NET is probably more future proof, chances of WPF getting large changes and being hard to port to later versions is probably larger.
Also keep in mind that the focus of MS seems to be on Silverlight so there might be a consolidation down the road which makes WPF obsolete.
More mature eco system of ASP.NET makes for more out of the box solutions to use to solve problems.
With multiple locations you might be able to skip a few layers and go directly to a website?

Moving towards Ruby on Rails from ASP.NET

I am ASP.NET developer from last 5 years and still loving it. There are lots of good voices in air about Ruby on Rails. I want to ask to community, Is there any worth trying to learn Ruby On Rails as a ASP.NET web developer on following point of view.
Scalability
Documentation
Community Support
Hosting Solutions
Deployment
ETC.
I'd take a gander as ASP.NET MVC. This way you can stick with the .NET Framework yet still get some of the things you probably want out of RoR.
ASP.NET MVC is very lightweight and easy to scale with some of the APIs it provides (SQL storage for sessions or even Microsoft Velocity).
ASP.NET MVC has lots of support from the community and thus has lots of documentation and feedback from the community and Microsoft itself.
Lots. Check out http://www.codeplex.com/ASPNET for more information.
Well, ASP.NET MVC is bin-deployable. So as long as your host supports ASP.NET 3.5 there's nothing else you need. They don't need to have ASP.NET MVC installed in any sort of way. So if you wanted to, you could easily use a shared host.
Deployment is very easy with ASP.NET MVC and with the changes coming to Visual Studio 2010 for easier deployment of web sites via "Packages." I currently maintain 2 ASP.NET MVC sites and find it with bin-deployment to be just the same as a regular ASP.NET WebForms site.
I'm now in your shoes, because I'm learning RoR after commercially developing in .NET for 5 years.
Here is my two cents:
Scalability: I believe that rails can scale quite well, there are numerous options available, such as mongrel clusters on linux.
This one is a bit worse than on .NET. But the community is very good and you'll never find yourself searching for a good way to go.
See above (it is excellent)
Hosting is not a problem: numerous hosting options available.
I find transition from development to test and then to production better thought of in Ror than in ASP.NET.
I fully agree with Chad's post.
I was half way through development of an app in rails and now i've done a complete 360 and have reconsidered after delving deep into ASP.NET MVC for my day job commitments.
I am now changing courses and looking into ASP.NET MVC for all my personal projects, I think both are honestly remarkably comparable now as I think MS has had a good hard look at Ruby on Rails' feature set and ensured they could match features very closely. After all, if you couple a project with LINQ 2 SQL / EF, ASP.NET MVC and potentially Dynamic Data (if you need that sort of thing), I really can't think of any compelling reasons to choose Rails over .NET, however I CAN choose reasons to select .NET over rails - after all hands down the rich debugging experience with VS.NET, rich intellisense and watcher/quickwatch support plus the ASP.NET MVC framework supports Html Action Helpers, Model Binders, support and encouragement for unit testing, and now with the inclusion of JQuery and JSON results, you're virtually unstoppable.
I suppose besides obviously hosting/licensing costs, Ruby language preference and other personal preferences such as it being open source etc, It's really your choice.
1) Scalability
Rails is just as scalable as any other web-application stack. The only difference is that your single server might get overloaded, and require splitting to 2 servers sooner than it would in .NET due to the slower performance of the ruby runtime. In practice this is not a problem.
2) Documentation
Microsoft do provide better documentation for the core libraries than Ruby or Rails, but the ruby/rails ones are still on the whole very good. I'd consider ruby/rails to be the winner here for the simple fact that you can always view the source for everything. No amount of documentation is a substitute for being able to actually see what's happening.
3) Community Support
I've been nothing but impressed by the community support around rails. I don't know what else to say there.
4) Hosting Solutions
Since phusion passenger got released, It seems to be easier these days to find rails hosting than it is to find ASP.net hosting. This is only going to sway more towards rails as time goes by for the simple fact that hosting companies do not have to pay royalties towards microsoft to deploy rails on linux servers.
5) Deployment ETC.
Capistrano (the most common deployment solution for rails) beats everything else hands down.
Well I dont know anything about the Scalability part, but personaly i started learning Ruby On Rails from ASP.NET a while ago. I really had a hard time finding some good documentation - the class documentation on Rails site was really poor in my eyes, and I had a simple question about what arguments you could put into an actionlink. But maybe it was just me who never found the right place. But personally i think that the ASP.NET documentation is better than rails - at least buy a book, i think thats a good way to go.
Number 3. Im pritty sure that there is very good Community Support for rails you just have to find the right forum or other media that suites your liking - maybe this what was I did wrong.
Number 4. There is alot of hosting solutions for Rails, but not as much as ASP.NET or PHP. I think you have to research this your self, and find out, if there is anything that suites your likeing.
Number 5. Ruby should be very easy to deploy, it has a notion of a development, test and production database. It uses migrations, so updates in the database schema is seamless - thats very cool. It is scripting, so it should be a matter of xcopy from the development computer to the production server.
The reason you should choose Ruby on Rails is if you like the MVC pattern. The MVC pattern is genius, and ruby is a great language when you learn it. Maybe take a dive into the ASP.NET MVC, and see what its like - then maybe move to Rails. Then you only have to learn a new language, and not a new arhitecture, framework and language at the same time.
Remmember this is from a ASP.NET Developer who sniffed to Rails, but gave up, doe to the lack of ability to find really good documentation, and there was always some strange errors, from the editor or Rails - but thats properbly a newbie thing :)
But if you have time, by all means learn it. Some developers say that we should learn one new language per year, and Ruby is a great candidate for that.

Resources