ASP NET Core appsettings json file

Sdílet
Vložit
  • čas přidán 22. 01. 2019
  • In this video we will discuss the significance of appsettings.json file in ASP.NET Core project.
    Healthy diet is very important for both body and mind. We want to inspire you to cook and eat healthy. If you like Aarvi Kitchen recipes, please support by sharing, subscribing and liking.
    / @aarvikitchen5572
    Text version of the video
    csharp-video-tutorials.blogsp...
    Slides
    csharp-video-tutorials.blogsp...
    ASP.NET Core Text Articles & Slides
    csharp-video-tutorials.blogsp...
    ASP.NET Core Tutorial
    • ASP.NET core tutorial ...
    Angular, JavaScript, jQuery, Dot Net & SQL Playlists
    czcams.com/users/kudvenka...
    WebHost Class
    github.com/aspnet/MetaPackage...
  • Věda a technologie

Komentáře • 87

  • @phanidivi3613
    @phanidivi3613 Před 5 lety +84

    no words sir,today i am a software engineer because of you sir.

  • @apositron84
    @apositron84 Před 4 lety +7

    Wow, these videos are amazing. I'm looking forward to getting up tomorrow and working through some more! Thank you!

  • @michalisp1121
    @michalisp1121 Před 3 lety +12

    I've seen many tutorials on youtube and I could say kudvenkat is the one of the best, if not the best, teacher out there. Wish I could post this in each of his videos. Thank you sir.

    • @fawemimoolawale4539
      @fawemimoolawale4539 Před rokem

      This tutorial is applied for beginner’s in these 2022 or it’s what learning for beginner’s in these 2022 because there’s latest version

  • @sungjin1225
    @sungjin1225 Před 3 lety

    there are no deeper explanation doc or vid than this. This is amazing! Thank you!

  • @BendaoudAbdelmounaim
    @BendaoudAbdelmounaim Před 3 lety

    Finally some in depth videos on the .NET Core framework, thank you so much

  • @prashnew1983
    @prashnew1983 Před 4 lety +2

    Sir , you are truly a gem. Thankyou

  • @talkathiriify
    @talkathiriify Před 4 lety +1

    You are amazing
    Thank you very very very much for all your tutorials.

  • @GavinLon
    @GavinLon Před 4 lety

    Excellent tutorial as always.

  • @GISJohn
    @GISJohn Před 4 lety +1

    Oh man, you have saved me so much trouble! Great Series

  • @yohanl1342
    @yohanl1342 Před 5 lety +2

    thanks for teaching !!!

  • @cprashanthreddy
    @cprashanthreddy Před 3 lety +1

    Superb Detail...

  • @TheAbubakarbaig
    @TheAbubakarbaig Před 4 lety

    I really appreciate. I thought mosh was great but you are even greater than him. Kudos and long live man.

  • @parko1965
    @parko1965 Před 5 lety

    Looks like this series is going to be big, cheers Venkat for your time, good tutorial.

  • @ThomasLorenz1
    @ThomasLorenz1 Před 2 lety

    Very clear explanation. Great! Saved my day!

  • @fiddler-dv4or
    @fiddler-dv4or Před 4 lety

    Great video. Thank you!

  • @javiernievas2839
    @javiernievas2839 Před 4 lety

    You are amazing!!! Definitely!!

  • @sergeyplotnikov5031
    @sergeyplotnikov5031 Před 4 lety

    So clear!!!! Thank you!!!

  • @hninkyawtwai8818
    @hninkyawtwai8818 Před rokem

    Kudvenkat is One of my best teachers. Thank you very much Sir!!

  • @jatinkumar4410
    @jatinkumar4410 Před 2 lety

    Your tutorials are amazing...

  • @tusharkukreti7448
    @tusharkukreti7448 Před 3 lety

    i want to say thank you in every video you post! I love you Kudvenkat

  • @SuperEvoken
    @SuperEvoken Před 2 lety

    these videos are great; going to watch the whole series.

  • @pedroreisbr
    @pedroreisbr Před 3 lety +1

    Finally some in depth videos on the .NET Core framework, thank you so much sir.

    • @fawemimoolawale4539
      @fawemimoolawale4539 Před rokem

      This tutorial is applied for beginner’s in these 2022 or it’s what learning for beginner’s in these 2022 because there’s latest version

  • @chaitanya2725
    @chaitanya2725 Před 2 lety

    Excellent 👌

  • @zbigniewcwiakalski7253

    Cool !

  • @ReduanRafi
    @ReduanRafi Před 2 lety

    Very informative !

  • @roronoa_d_law1075
    @roronoa_d_law1075 Před 4 lety

    Nice infos here

  • @erkangorgulu6013
    @erkangorgulu6013 Před 4 lety +2

    I really appreciate the effort you put into these videos. They really help.

  • @AspdotnetPools
    @AspdotnetPools Před 2 lety

    Good one..

  • @Artavazd.kirakosyan
    @Artavazd.kirakosyan Před 5 lety

    thank you for a a high quality tutorial, quick question: 8~9min: after setting "MyKey" and running, I deleted the key from lanchsettings and appsettinggs, preassumably it must show the value of "MyKey" from appsettings, but not. any hint? where is that info come from?

  • @a_n_m3516
    @a_n_m3516 Před 5 lety

    Hi kudvenkat sir, say we add MyKey with different values in appSettings.json and environment variables of iisexpress profile. And we run the application from command line. It should display the MyKey of appSettings.json and not environment variables in launchSettings.json, am I right?

  • @michigansafetyproducts1446

    Thank you!

  • @robertmays6097
    @robertmays6097 Před 5 lety

    excellent

  • @AshutoshKumar-kt1dd
    @AshutoshKumar-kt1dd Před 4 lety

    Great

  • @dhliu9687
    @dhliu9687 Před rokem

    Hi Teacher, I check - in ~

  • @jamesoo96571
    @jamesoo96571 Před 5 lety +12

    If you are missing appsettings.json file just add

    PreserveNewest

    into EmployeeManagement.csproj file and add appsettings.json file to the project. Then fill it with shown info by yourself. Same with appsettings.developement.json. Cheers

    • @honeytrippers
      @honeytrippers Před 5 lety +1

      Hi
      Oleg Sviridov
      "....and add appsettings.json file to the project."
      How?
      RMB on EmploymentManagement->Add->New Item->ASP.NET Core->JSON file/JSON schema File ???
      Then add the following?....
      {
      "Logging": {
      "LogLevel": {
      "Default": "Warning"
      }
      }
      }
      ...save all and run the project?
      does the appsettings.developement.json get built automatically or do you need to add that separately???
      If so, how?
      and how does it associate itself to the appsettings.json???
      Regards

    • @honeytrippers
      @honeytrippers Před 5 lety +1

      Hi kudvenkat,
      The development example....
      {
      "Logging": {"LogLevel": {"Default": "Debug", "System": "Information", "Microsoft": "Information"} },
      "Mykey": "Value of MyKey from appsettings.Development.json"
      }
      ....doesn't show, just the appsettings.json example...
      {
      "Logging": { "LogLevel": { "Default": "Warning" } },
      "AllowedHosts": "*",
      "Mykey": "Value of MyKey from appsettings.json"
      }
      ....though the...
      "Mykey": "Value of MyKey from Environmrnt Variable"
      ...version in the launchSettings.json did display........once I stopped running it the profile context of "EmployeeManagement" and ran it in "IIS Express" rpofile context I'd added it to!!!

    • @jatt420fauji
      @jatt420fauji Před 4 lety

      It Worked Thank's Sir

  • @ayushtripathi9
    @ayushtripathi9 Před 5 lety +9

    Thank you sir. Please make videos on .Net core Angular implementation.

  • @dheerajambippi2283
    @dheerajambippi2283 Před 2 lety

    When we publish .net core 3.1 project in release mode, It includes appsettings.json and appsettings.production .json. Why it not publish either appsettings.json nor appsettings.production.json file? Or appsetting.json is mandatory

  • @craghava5834
    @craghava5834 Před rokem

    Hi Sir, if we have multiple appsettings files? appsettings.Dev.json, appsettings.QA.json, appsettings.Preprod.json, etc.? Please let me know accordingly thanks.

  • @darshandivte4766
    @darshandivte4766 Před 2 lety

    so can we consider appsetting.js or appsetting.development.js file same as web.config file ?

  • @reefhound9902
    @reefhound9902 Před 4 lety

    Just to add, as ConfigureAppConfiguration loads settings, it is "last one wins" in case of duplicate keys.

  • @abouishakA
    @abouishakA Před 2 lety

    thanks

  • @durpinthapamagar
    @durpinthapamagar Před 5 lety +3

    hello sir i could not find appsettings.json file in my project
    i am using vs 2017

    • @QuickZ_
      @QuickZ_ Před 5 lety +1

      right-click project -> Add -> new item -> App Setting file -> Add
      and it will generate the file for you.

  • @karlailianadesousavieira5151

    Is it possible to read an include file from Asp Net Core?

  • @khosseny1625
    @khosseny1625 Před 5 lety

    Dear Sir , Can we use appsettings file as we use the web.config file in asp.net forms to save the database connection string ?

    • @sriramsundara393
      @sriramsundara393 Před 5 lety

      Yes we can use for that have connection string in dev json file and under env.isdevelopment condition, you can access the connection string.

  • @kumarshrey209
    @kumarshrey209 Před 3 lety +1

    25 april 2021

  • @Defense89
    @Defense89 Před rokem

    nice video Thx alot , i would like to know how to access connection string in appsetting from dbcontext? i tried constructor but it tells me the connection string is null :/
    please help me.

  • @QuickZ_
    @QuickZ_ Před 5 lety

    What happened to User Secrets?

  • @viivekg
    @viivekg Před 4 lety

    Can you show how to access AppSettings for my UnitTest Project please.

  • @Ruhgtfo
    @Ruhgtfo Před 4 lety

    do you have time make an example app for face detection without third party API, but something like Emgu

  • @DecentProgrammer
    @DecentProgrammer Před 3 lety

    detailed viedo

  • @TheXunty
    @TheXunty Před 4 lety

    Can anyone explain this ?
    I am new to development, and dot net is my first language can anyone tell me what is the exact significance of appconfig file ?
    I see in this video the value is stored using key/value pair but in realtime project what exactly will it store ?

    • @ryanander31
      @ryanander31 Před 4 lety +1

      RE:
      I am new to development, and dot net is my first language can anyone tell me what is the exact significance of appconfig file ?
      - An "app.config" file is the traditional configuration file used for applications built using the full .NET framework. It is built in an XML format and can contain a variety of settings (e.g. key/value pairs, service endpoint definitions, connection strings, framework specific settings, etc.). Note that in traditional ASP.NET this file is named "web.config" and can be altered post deployment using tools in Internet Information Services (IIS) server manager. These files can get rather large and complex as services and additional libraries are added to the application. App.config/Web.Config files are required to run applications using the full .NET framework.
      - The appsetting.json file in .NET Core is built in a JSON (JavaScript Object Notation) format and appears to be an optional component. The .NET Core dependency injection container (implemented in the Microsoft.Extensions.DependencyInjection) is able to search for different configuration sources (e.g. appsettings.json, appsettings.development.json, launchSetting.json, system environment variables, application parameters, etc) and bundle them into a single object that can be accessed at run time via a strongly typed object.
      RE: I see in this video the value is stored using key/value pair but in realtime project what exactly will it store ?
      - What the file is storing during "realtime"/run time may depend on what environment you are running the application under. In most circumstances it will probably contain at least connection string to a database. The connection string would probably be targeting different database servers when running in a production environment as opposed to a development environment.

  • @Kasador
    @Kasador Před 4 lety

    Using MacOS, but when I type IConfiguration, I don't get any errors or red underlines, and so I'd like to know how to get the info for the namespace.
    EDIT: I updated my Visual Studio code and I am now receiving error messages.

  • @arunnayak3342
    @arunnayak3342 Před 3 lety

    Can we get pdf of all these classes.. Thanks in Advance...

  • @factworld4375
    @factworld4375 Před 5 lety

    Thank you.

  • @trunklemcjeans
    @trunklemcjeans Před 3 lety

    you sir are saving my ass. thank you.

  • @conaxliu9677
    @conaxliu9677 Před 4 lety

    4:30 I was trying to browse through the methods of _config to see how to retrieve the value of MyKey, but never thought it would be that easy. *Cry laughing*

  • @vimalrules90
    @vimalrules90 Před 5 lety +1

    AppSettings file is missing in my project

    • @dragony117
      @dragony117 Před 5 lety

      maybe You are using dotnet core 2.1

  • @anithakrishnamoorthy5036
    @anithakrishnamoorthy5036 Před 5 měsíci

    For new learners like me:
    Constuctor is a special method used to initialze object (ctor)
    Method - block of code needs to be executed

  • @Hemantsharma-fo4ut
    @Hemantsharma-fo4ut Před 9 měsíci

    Your voice is amazing, sounds like robot

  • @dotnetstuff1912
    @dotnetstuff1912 Před 4 lety +1

    environment specific config settings are not overriding appsetting.json settings (3.1) VS2019. Actually it is not at all reading config setting from Environment specific appsettings file

    • @mohinimadavi5870
      @mohinimadavi5870 Před 3 lety +1

      You need to put configuration IIS Express in Profiles in json file if you are launching using IIS Express.

    • @anvayjoshi6283
      @anvayjoshi6283 Před 3 lety

      @@mohinimadavi5870 Thank you

  • @ibknl1986
    @ibknl1986 Před 3 lety

    You are doing a great job. May Allah (God) guide and bless you.

  • @charlesm.1638
    @charlesm.1638 Před 4 lety

    Will this work with ASP.net 3.1?

  • @narendrakumarbiswal2023

    For Environment
    variable it didnot fetched anything still redirecting from developement.json

    • @garurumon9758
      @garurumon9758 Před 4 lety

      If anyone else is confused by this then you need to add the key to the relevant profile if not running via IISExpress - the environment variables are specific to a profile.

    • @NikhilShirgaonkar
      @NikhilShirgaonkar Před 4 lety

      Yes, make sure to which profile you're adding environment variable

  • @randompointlessness2766

    My launchSettings won't load into Program Main arguments are empty

  • @karthikraja7017
    @karthikraja7017 Před 4 lety

    How can we use encryption to hide actual connection string in appsettings.json ?

  • @playtune9217
    @playtune9217 Před rokem

    who is here from nagarro :)

  • @raqibul1000
    @raqibul1000 Před 2 lety

    ALLAH blessed you