Skip to main content

Posts

Distributed session management in ASP.NET Core MVC Application

Introduction In this article, I am going to explain what are simple steps if you want to use distributed sessions in order to make your ASP.NET Core application load balanced. Assumption I am assuming that you already have created default project for ASP.NET core MVC app using visual studio. Sessions Session object is used in order to save or store user data for configurable amount of time. It uses dictionary on server side to store data and session id can be used as key to manage data back and forth. There are two types of sessions: 1. In Memory 2. Distributed In case of in memory session, session are stored in memory of a server and if you are using two servers, other server will not have access to it as it is saved in memory of server 1. It is discouraged for load balanced applications. While distributed sessions are stored in centralized place where both servers have access and it is considered to be more useful and reliable mechanism to store data in...
Recent posts

ASP.NET CORE File Upload along with Complex Object with AJAX

Problem Area: In one of my project, my requirement was to Post File along Complex object to server using AJAX. I could not find ready made solution targeting both things in a single project so I decided to share this solution with you guys to try it out as well. HTML: <input type="file" id="uploadEditorImage" />  <input type="button" id="upload" value="upload" onclick="uploadImage()" /> Javascript: function uploadImage()     {         var userObj = {};         userObj.userId = "123456";         var serializedObj = JSON.stringify(userObj);         var formData = new FormData();         formData.append('file', $('#uploadEditorImage')[0].files[0]);         formData.append('vm', serializedObj );         var _urlAction = '@Url.Action("Upload", "Home")';         $.ajax({   ...

CV Rejection Reasons

There are many people who have strong skills in specific field but when they try to get a job, it becomes so hard for them and main reason for rejection of CVs are: 1. No Subject 2. Wrong Subject 3. Inappropriate wording 4. Mismatch Qualification / Experience 5. Unsupported CV Format 6. CV details in image 7. Missing Contact Info 8. Inappropriate Name (Princess, Prince, Cute, Dashing etc ) 9. Over filling of data 10. Same CV for all jobs Mostly recruiters spent max 1-2 minutes in reading out the CV. So it is the responsibility of incumbents to impress him/her within this tenure. So one must be careful while writing and sending the CV because it shows the reflection of your personality. I wish you best of luck for your job search.

WhatsApp on PC

WhatsApp has become the top messaging media nowadays. Now people don't spend money on sending messages including music, pictures and any type of file to anybody. They just use WhatsApp in order to do these kind of tasks. There is no limit of messages in this tiny but powerful application. Recently WhatsApp launched their web portal for sending and receiving messages. You can do it with following steps. Visit  http://web.whatsapp.com/ Scan QR code with your mobile camera. Enjoy free messages. Your phone needs to stay connected to internet in order to work with web client. This feature is not yet enabled for iOS due to platform limitation as of today date.

Draw Image in canvas by maintaining its Aspect Ratio

I have looking for a solution for drawing Image in canvas by maintaining its Aspect Ratio. After so much research and reading articles I successfully implemented in my project by combining inputs from them specially this . I decided to share my solution with you people. So here it is. <!DOCTYPE html> <html> <body> <label> Image File: </label><br/> <input type= "file" id= "fileControl" name= "fileControl" /> <div style= "border:1px solid red;align:center" > <canvas id= "imageCanvas" ></canvas> </div> <script> var fileControl = document .getElementById( 'fileControl' ); fileControl.addEventListener( 'change' , handleImage, false ); var canvas = document .getElementById( 'imageCanvas' ); var ctx = canvas.getContext( '2d' ); function handleImage(e){ var reader = new FileReader(); rea...

Publish Paid Android Apps on Google Play Store

Good news for the all the Android developers!  Other new countries that can now publish paid apps are: Pakistan, Jordan, Lebanon, Oman, Puerto Rico, Qatar, And Venezuela. These countries can now publish paid Android apps and games on the Google Play Store. This news just came in earlier this week after Google allowed support for another 7 countries who can now sell apps. Previously, Android users in Pakistan were only able to purchase and download paid apps but it was a hassle for a developer who wanted to make money by selling his app/game. For those developers who are new to this and want to get started, visit the  Google Play Developer Console . There is a $25 registration fees for the first time when you sign up, so make sure you have a credit card with you. To check out other countries from where you can publish Android apps  — there are more than 60 countries now. Check them

How to Run WhatsApp on Computer

WhatsApp is one of the coolest applications we have in our smat phones. Everyone does not have a smart phone and they still want to use WhatsApp. Today I will describe that how can you do that. BlueStacks solved this problem nicely. This software helps you to install and use Android applications on your WhatsApp. You can download this application from  bluestacks.joydownload.com/‎ Steps to configure WhatsApp: Install BlueStacks Player. Enter your Gmail account details. (It will link you to play store) You will see the list of applications on the main dashboard. Click on WhatsApp. Configure WhatsApp using your mobile number. Congratulations. You have successfully installed and configure WhatsApp on your computer.