Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

Application Insights config from appsettings.json #1402

Merged
merged 1 commit into from
Mar 19, 2019

Conversation

daveta
Copy link
Contributor

@daveta daveta commented Feb 26, 2019

John, here's a stab at "no botfile" override.

Would logically change:
public void ConfigureServices(IServiceCollection services)
{
var botConfig = BotConfiguration.Load("testbot.bot", null);
services.AddBotApplicationInsights(botConfig);

To something like:
public IConfiguration Configuration { get; }

public void ConfigureServices(IServiceCollection services)
{
services.AddBotApplicationInsights(Configuration);

@coveralls
Copy link
Collaborator

Pull Request Test Coverage Report for Build 50028

  • 0 of 0 changed or added relevant lines in 0 files are covered.
  • 6 unchanged lines in 1 file lost coverage.
  • Overall coverage increased (+0.05%) to 74.605%

Files with Coverage Reduction New Missed Lines %
/libraries/integration/Microsoft.Bot.Builder.Integration.ApplicationInsights.Core/ServiceCollectionExtensions.cs 6 86.15%
Totals Coverage Status
Change from base Build 49945: 0.05%
Covered Lines: 4010
Relevant Lines: 5375

💛 - Coveralls

@cleemullins
Copy link
Contributor

@daveta The approach @johnataylor is using in the samples is quite clean and seems like it would directly apply here. Let's sync tomorrow and see if we can get this closed across the board.

... and we need to make sure we don't break compat as we do it.

Copy link
Contributor

@cleemullins cleemullins left a comment

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

This LGTM, but let's sync with @johnataylor before we do anything here.

@cleemullins cleemullins added the blocked Current progress is blocked on something else. label Mar 1, 2019
@cleemullins
Copy link
Contributor

Added "Blocked" just so this isn't accidentally merged until John can confirm this matches what he's doing...

@daveta
Copy link
Contributor Author

daveta commented Mar 6, 2019

This is actually just using what the Application Insights default appsettings.json keys are. If we want to deviate from that, we can align on whatever is decided..

@daveta
Copy link
Contributor Author

daveta commented Mar 18, 2019

FYI: I believe @darrenj was going to take for his work (with the "standard" App Insights appsettings.json).

One thing I haven't investigated with the "standard" settings is how to support multiple distinct Application Insights instances. Something we could support in the ..bot config file.

@daveta daveta changed the title Add option to init that skips the botfile and just uses appsettings.json Application Insights config from appsettings.json Mar 19, 2019
@cleemullins cleemullins merged commit 1dd67dd into master Mar 19, 2019
@cleemullins cleemullins deleted the daveta-appins-nobotfile branch March 19, 2019 01:09
@cleemullins cleemullins removed the blocked Current progress is blocked on something else. label Mar 19, 2019
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
None yet
Projects
None yet
Development

Successfully merging this pull request may close these issues.

None yet

3 participants