Comments (12)
Pull request #41 contains support for diagnostics on the service level.
from apimanagementarmtemplatecreator.
Good idea, I'll try to get that with next release
from apimanagementarmtemplatecreator.
Logger support was included in pull request #24. Is that enough?
It does not create new loggers but will create a "link" to existing ones.
from apimanagementarmtemplatecreator.
Guess this will be enough for now?
from apimanagementarmtemplatecreator.
It'd be nice if this was part of the tool, but creating the link is fine for us. However, I just tested this out (with commit f17cb07) and it didn't seem to generate the logger link for an API with an existing logger.
from apimanagementarmtemplatecreator.
Strange that the creation of the logger link was not working in that commit. It worked fine for me.
In pull request 32 there are code that will generate an Application Insights instance if you specify the parameter CreateApplicationInsightsInstance as true and it is used by a logger.
It will be created in the same location as the api management instance and the type will be "other".
You will not need to specify the instrumentation key as a parameter because it will be a reference from the Application Insights instance to the API Management instance.4
If you set CreateApplicationInsightsInstance=false then you still need to provide the instrumentation key as a parameter
from apimanagementarmtemplatecreator.
Hi @nilshedstrom, maybe I'm misunderstanding what you meant when you said creating a link to an existing logger. I'm expecting something similar to what I have at the bottom of my sample template (LOGGER ASSOCIATION WITH API). I just pulled latest and reran the tool against an API that has an App Insights logger configured, but I'm not seeing any "link" it in the output. Am I missing a parameter?
from apimanagementarmtemplatecreator.
Pull request 32 is not merged yet so you dont get it by pulling the latest version of the main branch.
When you get it and have the CreateApplicationInsightsInstance as $true then you will get something like this in resources for the APIM instance
{
"type": "Microsoft.Insights/components",
"name": "[parameters('apimServiceName_applicationInsights')]",
"apiVersion": "2015-05-01",
"properties": {
"Application_Type": "other"
},
"resources": [],
"dependsOn": [
"[resourceId('Microsoft.ApiManagement/service', parameters('apimServiceName'))]"
],
"location": "[parameters('apimServiceName_location')]",
"kind": "other"
},
{
"type": "Microsoft.ApiManagement/service/loggers",
"name": "[concat(parameters('apimServiceName'),'/',parameters('apimServiceName_applicationInsights'))]",
"apiVersion": "2017-03-01",
"properties": {
"loggerType": "applicationInsights",
"description": null,
"credentials": {
"instrumentationKey": "[reference(resourceId('Microsoft.Insights/components', parameters('apimServiceName_applicationInsights')), '2014-04-01').InstrumentationKey]"
},
"isBuffered": true
},
"resources": [],
"dependsOn": [
"[resourceId('Microsoft.ApiManagement/service', parameters('apimServiceName'))]",
"[resourceId('Microsoft.Insights/components',parameters('apimServiceName_applicationInsights'))]"
]
}
from apimanagementarmtemplatecreator.
This will create the logger and the app insights instance, but you need to add a diagnostics resource to assign the logger to the API.
from apimanagementarmtemplatecreator.
I realized this when I Application Insights did not log anything untill I added a ""Microsoft.ApiManagement/service/diagnostics" resource.
I hope I will have time to support for this in APIManagementARMTemplateCreator soon.
from apimanagementarmtemplatecreator.
@joeyeng Loggers are created, diagnostics resources are created and Application Insights resources can be created if requested. What else is needed before this issue can be closed?
from apimanagementarmtemplatecreator.
Great, I will close this issue now.
from apimanagementarmtemplatecreator.
Related Issues (20)
- Backends with Custom URL causes NullReferenceException HOT 2
- API Filters not working HOT 3
- Error in Write-APIManagementTemplates HOT 3
- Named values used in backend definitions HOT 2
- Write-APIManagementTemplates: AlwaysAddPropertiesAndBackend + GenerateParameterFiles causes causes cast error
- Get-APIManagementTemplate stopped working for Consumption instances HOT 2
- backend-id Policy substitution HOT 1
- API Product not getting the proper dependson HOT 1
- Exception message is: Value cannot be null. Parameter name: input HOT 12
- Policy files not extracted anymore HOT 1
- Issue with extra / in linked template URL in Azure DevOPS
- Products with API acccess - Using a parameter that is not included in the ARM-Template HOT 7
- The resource IfsGatewayFunctionApp is not defined in the template HOT 9
- Missing dependency for application insights diagnostics template
- PessimisticConcurrencyConflict: Operation on the API is in progress
- Extracting API Manager with swagger files HOT 1
- Support for backend arm template HOT 2
- Support for Powershell 7 HOT 1
- Exporting "Named Values" is limited to 100 HOT 1
- Write-APIManagementTemplates not working HOT 1
Recommend Projects
-
React
A declarative, efficient, and flexible JavaScript library for building user interfaces.
-
Vue.js
🖖 Vue.js is a progressive, incrementally-adoptable JavaScript framework for building UI on the web.
-
Typescript
TypeScript is a superset of JavaScript that compiles to clean JavaScript output.
-
TensorFlow
An Open Source Machine Learning Framework for Everyone
-
Django
The Web framework for perfectionists with deadlines.
-
Laravel
A PHP framework for web artisans
-
D3
Bring data to life with SVG, Canvas and HTML. 📊📈🎉
-
Recommend Topics
-
javascript
JavaScript (JS) is a lightweight interpreted programming language with first-class functions.
-
web
Some thing interesting about web. New door for the world.
-
server
A server is a program made to process requests and deliver data to clients.
-
Machine learning
Machine learning is a way of modeling and interpreting data that allows a piece of software to respond intelligently.
-
Visualization
Some thing interesting about visualization, use data art
-
Game
Some thing interesting about game, make everyone happy.
Recommend Org
-
Facebook
We are working to build community through open source technology. NB: members must have two-factor auth.
-
Microsoft
Open source projects and samples from Microsoft.
-
Google
Google ❤️ Open Source for everyone.
-
Alibaba
Alibaba Open Source for everyone
-
D3
Data-Driven Documents codes.
-
Tencent
China tencent open source team.
from apimanagementarmtemplatecreator.