Bringing changes from dev-react (#215)
* Updating README * Update packages using: npm audit fix * Update packages using: npm install react-scripts@5.0.1 * Update packages using: npm install node-sass@7.0.1 * Update Microsoft.Azure.DocumentDB.Core to latest version * Moving react-sripts to devDependencies as per https://github.com/facebook/create-react-app/issues/11174 * Update npm packages (#207) - Remove dependency on node-sass which is deprecated: 'npm uninstall node-sass' - Run 'npm audit fix' * Migrating to Azure Cosmos DB .NET SDK v3 (#205) * Bump terser from 5.12.1 to 5.14.2 in /ServerlessLibraryAPI/ClientApp (#208) Bumps [terser](https://github.com/terser/terser) from 5.12.1 to 5.14.2. - [Release notes](https://github.com/terser/terser/releases) - [Changelog](https://github.com/terser/terser/blob/master/CHANGELOG.md) - [Commits](https://github.com/terser/terser/commits) --- updated-dependencies: - dependency-name: terser dependency-type: indirect ... Signed-off-by: dependabot[bot] <support@github.com> Co-authored-by: dependabot[bot] <49699333+dependabot[bot]@users.noreply.github.com> * Remove swagger endpoint (#209) * Update functionapp to .net core 3.1 (#212) * Update Newtonsoft.Json (#213) * Update storage extension (#214) * Microsoft mandatory file (#210) Co-authored-by: microsoft-github-policy-service[bot] <77245923+microsoft-github-policy-service[bot]@users.noreply.github.com> Co-authored-by: dependabot[bot] <49699333+dependabot[bot]@users.noreply.github.com> Co-authored-by: microsoft-github-policy-service[bot] <77245923+microsoft-github-policy-service[bot]@users.noreply.github.com>
This commit is contained in:
Родитель
c936e7e47f
Коммит
ce0d3059c7
|
@ -0,0 +1,41 @@
|
|||
<!-- BEGIN MICROSOFT SECURITY.MD V0.0.7 BLOCK -->
|
||||
|
||||
## Security
|
||||
|
||||
Microsoft takes the security of our software products and services seriously, which includes all source code repositories managed through our GitHub organizations, which include [Microsoft](https://github.com/Microsoft), [Azure](https://github.com/Azure), [DotNet](https://github.com/dotnet), [AspNet](https://github.com/aspnet), [Xamarin](https://github.com/xamarin), and [our GitHub organizations](https://opensource.microsoft.com/).
|
||||
|
||||
If you believe you have found a security vulnerability in any Microsoft-owned repository that meets [Microsoft's definition of a security vulnerability](https://aka.ms/opensource/security/definition), please report it to us as described below.
|
||||
|
||||
## Reporting Security Issues
|
||||
|
||||
**Please do not report security vulnerabilities through public GitHub issues.**
|
||||
|
||||
Instead, please report them to the Microsoft Security Response Center (MSRC) at [https://msrc.microsoft.com/create-report](https://aka.ms/opensource/security/create-report).
|
||||
|
||||
If you prefer to submit without logging in, send email to [secure@microsoft.com](mailto:secure@microsoft.com). If possible, encrypt your message with our PGP key; please download it from the [Microsoft Security Response Center PGP Key page](https://aka.ms/opensource/security/pgpkey).
|
||||
|
||||
You should receive a response within 24 hours. If for some reason you do not, please follow up via email to ensure we received your original message. Additional information can be found at [microsoft.com/msrc](https://aka.ms/opensource/security/msrc).
|
||||
|
||||
Please include the requested information listed below (as much as you can provide) to help us better understand the nature and scope of the possible issue:
|
||||
|
||||
* Type of issue (e.g. buffer overflow, SQL injection, cross-site scripting, etc.)
|
||||
* Full paths of source file(s) related to the manifestation of the issue
|
||||
* The location of the affected source code (tag/branch/commit or direct URL)
|
||||
* Any special configuration required to reproduce the issue
|
||||
* Step-by-step instructions to reproduce the issue
|
||||
* Proof-of-concept or exploit code (if possible)
|
||||
* Impact of the issue, including how an attacker might exploit the issue
|
||||
|
||||
This information will help us triage your report more quickly.
|
||||
|
||||
If you are reporting for a bug bounty, more complete reports can contribute to a higher bounty award. Please visit our [Microsoft Bug Bounty Program](https://aka.ms/opensource/security/bounty) page for more details about our active programs.
|
||||
|
||||
## Preferred Languages
|
||||
|
||||
We prefer all communications to be in English.
|
||||
|
||||
## Policy
|
||||
|
||||
Microsoft follows the principle of [Coordinated Vulnerability Disclosure](https://aka.ms/opensource/security/cvd).
|
||||
|
||||
<!-- END MICROSOFT SECURITY.MD BLOCK -->
|
|
@ -9,127 +9,127 @@ using Microsoft.Extensions.Logging;
|
|||
|
||||
namespace ServerlessLibrary
|
||||
{
|
||||
public interface ICacheService
|
||||
{
|
||||
IList<LibraryItemWithStats> GetCachedItems();
|
||||
}
|
||||
|
||||
//https://stackoverflow.com/questions/44723017/in-memory-caching-with-auto-regeneration-on-asp-net-core
|
||||
public class CacheService : ICacheService
|
||||
{
|
||||
protected readonly IMemoryCache _cache;
|
||||
private readonly ILibraryStore libraryStore;
|
||||
private readonly ILogger logger;
|
||||
|
||||
private Task LoadingTask = Task.CompletedTask;
|
||||
private Timer Timer = null;
|
||||
private bool LoadingBusy = false;
|
||||
private bool isCacheLoadedOnce = false;
|
||||
|
||||
public CacheService(IMemoryCache cache, ILibraryStore libraryStore, ILogger<CacheService> logger)
|
||||
public interface ICacheService
|
||||
{
|
||||
this._cache = cache;
|
||||
this.libraryStore = libraryStore;
|
||||
this.logger = logger;
|
||||
InitTimer();
|
||||
IList<LibraryItemWithStats> GetCachedItems();
|
||||
}
|
||||
|
||||
private void InitTimer()
|
||||
//https://stackoverflow.com/questions/44723017/in-memory-caching-with-auto-regeneration-on-asp-net-core
|
||||
public class CacheService : ICacheService
|
||||
{
|
||||
_cache.Set<LibraryItemsResult>(ServerlessLibrarySettings.CACHE_ENTRY, new LibraryItemsResult() { Result = new List<LibraryItemWithStats>(), IsBusy = true });
|
||||
protected readonly IMemoryCache _cache;
|
||||
private readonly ILibraryStore libraryStore;
|
||||
private readonly ILogger logger;
|
||||
|
||||
Timer = new Timer(TimerTickAsync, null, 1000, ServerlessLibrarySettings.SLCacheRefreshIntervalInSeconds * 1000);
|
||||
}
|
||||
private Task LoadingTask = Task.CompletedTask;
|
||||
private Timer Timer = null;
|
||||
private bool LoadingBusy = false;
|
||||
private bool isCacheLoadedOnce = false;
|
||||
|
||||
public IList<LibraryItemWithStats> GetCachedItems()
|
||||
{
|
||||
// Make a blocking call to load cache on first time call.
|
||||
if (!isCacheLoadedOnce)
|
||||
{
|
||||
try
|
||||
public CacheService(IMemoryCache cache, ILibraryStore libraryStore, ILogger<CacheService> logger)
|
||||
{
|
||||
logger.LogInformation("Loading initial cache");
|
||||
IList<LibraryItemWithStats> items = this.ConstructCache().Result;
|
||||
_cache.Set(ServerlessLibrarySettings.CACHE_ENTRY, new LibraryItemsResult() { Result = items, IsBusy = false });
|
||||
logger.LogInformation("Loaded {0} items into cache", items.Count());
|
||||
this._cache = cache;
|
||||
this.libraryStore = libraryStore;
|
||||
this.logger = logger;
|
||||
InitTimer();
|
||||
}
|
||||
catch (Exception ex)
|
||||
|
||||
private void InitTimer()
|
||||
{
|
||||
this.logger.LogError(ex, "Failed to load cache in first call");
|
||||
_cache.Set<LibraryItemsResult>(ServerlessLibrarySettings.CACHE_ENTRY, new LibraryItemsResult() { Result = new List<LibraryItemWithStats>(), IsBusy = true });
|
||||
|
||||
Timer = new Timer(TimerTickAsync, null, 1000, ServerlessLibrarySettings.SLCacheRefreshIntervalInSeconds * 1000);
|
||||
}
|
||||
}
|
||||
|
||||
logger.LogInformation("Successfully loaded initial cache");
|
||||
isCacheLoadedOnce = true;
|
||||
return _cache.Get<LibraryItemsResult>(ServerlessLibrarySettings.CACHE_ENTRY).Result;
|
||||
public IList<LibraryItemWithStats> GetCachedItems()
|
||||
{
|
||||
// Make a blocking call to load cache on first time call.
|
||||
if (!isCacheLoadedOnce)
|
||||
{
|
||||
try
|
||||
{
|
||||
logger.LogInformation("Loading initial cache");
|
||||
IList<LibraryItemWithStats> items = this.ConstructCache().Result;
|
||||
_cache.Set(ServerlessLibrarySettings.CACHE_ENTRY, new LibraryItemsResult() { Result = items, IsBusy = false });
|
||||
logger.LogInformation("Loaded {0} items into cache", items.Count());
|
||||
}
|
||||
catch (Exception ex)
|
||||
{
|
||||
this.logger.LogError(ex, "Failed to load cache in first call");
|
||||
}
|
||||
}
|
||||
|
||||
logger.LogInformation("Successfully loaded initial cache");
|
||||
isCacheLoadedOnce = true;
|
||||
return _cache.Get<LibraryItemsResult>(ServerlessLibrarySettings.CACHE_ENTRY).Result;
|
||||
}
|
||||
|
||||
private async void TimerTickAsync(object state)
|
||||
{
|
||||
logger.LogInformation("Cache refresh timer fired");
|
||||
if (!isCacheLoadedOnce || LoadingBusy)
|
||||
{
|
||||
logger.LogWarning("Skipping cache refresh");
|
||||
return;
|
||||
}
|
||||
|
||||
try
|
||||
{
|
||||
LoadingBusy = true;
|
||||
LoadingTask = LoadCaches();
|
||||
await LoadingTask;
|
||||
}
|
||||
catch
|
||||
{
|
||||
// do not crash the app
|
||||
}
|
||||
finally
|
||||
{
|
||||
LoadingBusy = false;
|
||||
}
|
||||
}
|
||||
private async Task LoadCaches()
|
||||
{
|
||||
try
|
||||
{
|
||||
logger.LogInformation("Starting cache refresh");
|
||||
var items = await ConstructCache();
|
||||
_cache.Set<LibraryItemsResult>(ServerlessLibrarySettings.CACHE_ENTRY, new LibraryItemsResult() { Result = items, IsBusy = false });
|
||||
logger.LogInformation("Updated cache with {0} items", items.Count());
|
||||
}
|
||||
catch (Exception ex)
|
||||
{
|
||||
this.logger.LogError(ex, "Failed to load cache");
|
||||
}
|
||||
}
|
||||
private async Task<IList<LibraryItemWithStats>> ConstructCache()
|
||||
{
|
||||
logger.LogInformation("Starting ConstructCache");
|
||||
IList<LibraryItem> libraryItems;
|
||||
IList<LibraryItemWithStats> libraryItemsWithStats = new List<LibraryItemWithStats>();
|
||||
libraryItems = await this.libraryStore.GetAllItems();
|
||||
logger.LogInformation("Cosmos DB returned {0} results", libraryItems.Count());
|
||||
var stats = await StorageHelper.getSLItemRecordsAsync();
|
||||
logger.LogInformation("Storage returned {0} results", stats.Count());
|
||||
foreach (var storeItem in libraryItems)
|
||||
{
|
||||
var item = storeItem.ConvertTo<LibraryItemWithStats>();
|
||||
var itemStat = stats.Where(s => s.id == storeItem.Id.ToString()).FirstOrDefault();
|
||||
item.TotalDownloads = itemStat != null && itemStat.totalDownloads > 0 ? itemStat.totalDownloads : 1;
|
||||
item.Likes = itemStat != null && itemStat.likes > 0 ? itemStat.likes : 0;
|
||||
item.Dislikes = itemStat != null && itemStat.dislikes > 0 ? itemStat.dislikes : 0;
|
||||
libraryItemsWithStats.Add(item);
|
||||
}
|
||||
|
||||
logger.LogInformation("ConstructCache returned {0} items", libraryItemsWithStats.Count());
|
||||
return libraryItemsWithStats;
|
||||
}
|
||||
}
|
||||
|
||||
private async void TimerTickAsync(object state)
|
||||
public class LibraryItemsResult
|
||||
{
|
||||
logger.LogInformation("Cache refresh timer fired");
|
||||
if (!isCacheLoadedOnce || LoadingBusy)
|
||||
{
|
||||
logger.LogWarning("Skipping cache refresh");
|
||||
return;
|
||||
}
|
||||
|
||||
try
|
||||
{
|
||||
LoadingBusy = true;
|
||||
LoadingTask = LoadCaches();
|
||||
await LoadingTask;
|
||||
}
|
||||
catch
|
||||
{
|
||||
// do not crash the app
|
||||
}
|
||||
finally
|
||||
{
|
||||
LoadingBusy = false;
|
||||
}
|
||||
public IList<LibraryItemWithStats> Result { get; set; }
|
||||
public bool IsBusy { get; set; }
|
||||
}
|
||||
private async Task LoadCaches()
|
||||
{
|
||||
try
|
||||
{
|
||||
logger.LogInformation("Starting cache refresh");
|
||||
var items = await ConstructCache();
|
||||
_cache.Set<LibraryItemsResult>(ServerlessLibrarySettings.CACHE_ENTRY, new LibraryItemsResult() { Result = items, IsBusy = false });
|
||||
logger.LogInformation("Updated cache with {0} items", items.Count());
|
||||
}
|
||||
catch (Exception ex)
|
||||
{
|
||||
this.logger.LogError(ex, "Failed to load cache");
|
||||
}
|
||||
}
|
||||
private async Task<IList<LibraryItemWithStats>> ConstructCache()
|
||||
{
|
||||
logger.LogInformation("Starting ConstructCache");
|
||||
IList<LibraryItem> libraryItems;
|
||||
IList<LibraryItemWithStats> libraryItemsWithStats = new List<LibraryItemWithStats>();
|
||||
libraryItems = await this.libraryStore.GetAllItems();
|
||||
logger.LogInformation("Cosmos DB returned {0} results", libraryItems.Count());
|
||||
var stats = await StorageHelper.getSLItemRecordsAsync();
|
||||
logger.LogInformation("Storage returned {0} results", stats.Count());
|
||||
foreach (var storeItem in libraryItems)
|
||||
{
|
||||
var item = storeItem.ConvertTo<LibraryItemWithStats>();
|
||||
var itemStat = stats.Where(s => s.id == storeItem.Id.ToString()).FirstOrDefault();
|
||||
item.TotalDownloads = itemStat != null && itemStat.totalDownloads > 0 ? itemStat.totalDownloads : 1;
|
||||
item.Likes = itemStat != null && itemStat.likes > 0 ? itemStat.likes : 0;
|
||||
item.Dislikes = itemStat != null && itemStat.dislikes > 0 ? itemStat.dislikes : 0;
|
||||
libraryItemsWithStats.Add(item);
|
||||
}
|
||||
|
||||
logger.LogInformation("ConstructCache returned {0} items", libraryItemsWithStats.Count());
|
||||
return libraryItemsWithStats;
|
||||
}
|
||||
}
|
||||
|
||||
public class LibraryItemsResult
|
||||
{
|
||||
public IList<LibraryItemWithStats> Result { get; set; }
|
||||
public bool IsBusy { get; set; }
|
||||
}
|
||||
|
||||
}
|
||||
}
|
Разница между файлами не показана из-за своего большого размера
Загрузить разницу
|
@ -5,7 +5,6 @@
|
|||
"dependencies": {
|
||||
"@uifabric/styling": "^6.47.6",
|
||||
"markdown-to-jsx": "^6.11.4",
|
||||
"node-sass": "^7.0.1",
|
||||
"office-ui-fabric-react": "^6.187.0",
|
||||
"react": "^16.8.6",
|
||||
"react-app-polyfill": "^1.0.1",
|
||||
|
|
|
@ -1,11 +1,8 @@
|
|||
using System;
|
||||
using System.Collections.Generic;
|
||||
using System.Collections.Generic;
|
||||
using System.Linq;
|
||||
using System.Linq.Expressions;
|
||||
using System.Threading.Tasks;
|
||||
using Microsoft.Azure.Documents;
|
||||
using Microsoft.Azure.Documents.Client;
|
||||
using Microsoft.Azure.Documents.Linq;
|
||||
using Microsoft.Azure.Cosmos;
|
||||
using Microsoft.Azure.Cosmos.Fluent;
|
||||
using ServerlessLibrary.Models;
|
||||
|
||||
namespace ServerlessLibrary
|
||||
|
@ -40,16 +37,16 @@ namespace ServerlessLibrary
|
|||
{
|
||||
private static readonly string DatabaseId = ServerlessLibrarySettings.Database;
|
||||
private static readonly string CollectionId = ServerlessLibrarySettings.Collection;
|
||||
private static DocumentClient client;
|
||||
private static Container container;
|
||||
|
||||
public static async Task<T> GetItemAsync(string id)
|
||||
{
|
||||
try
|
||||
{
|
||||
Document document = await client.ReadDocumentAsync(UriFactory.CreateDocumentUri(DatabaseId, CollectionId, id));
|
||||
return (T)(dynamic)document;
|
||||
ItemResponse<T> response = await container.ReadItemAsync<T>(id, PartitionKey.None);
|
||||
return response.Resource;
|
||||
}
|
||||
catch (DocumentClientException e)
|
||||
catch (CosmosException e)
|
||||
{
|
||||
if (e.StatusCode == System.Net.HttpStatusCode.NotFound)
|
||||
{
|
||||
|
@ -64,83 +61,53 @@ namespace ServerlessLibrary
|
|||
|
||||
public static async Task<List<T>> GetAllItemsAsync()
|
||||
{
|
||||
IDocumentQuery<T> query = client.CreateDocumentQuery<T>(
|
||||
UriFactory.CreateDocumentCollectionUri(DatabaseId, CollectionId),
|
||||
new FeedOptions { MaxItemCount = -1, EnableCrossPartitionQuery = true })
|
||||
.AsDocumentQuery();
|
||||
FeedIterator<T> query = container.GetItemQueryIterator<T>(
|
||||
queryDefinition: null,
|
||||
requestOptions: new QueryRequestOptions() { MaxItemCount = -1 }); // NOTE: FeedOptions.EnableCrossPartitionQuery is removed in SDK v3 (https://docs.microsoft.com/en-us/azure/cosmos-db/sql/migrate-dotnet-v3?tabs=dotnet-v3#changes-to-feedoptions-queryrequestoptions-in-v30-sdk)
|
||||
|
||||
List<T> results = new List<T>();
|
||||
while (query.HasMoreResults)
|
||||
using (query)
|
||||
{
|
||||
results.AddRange(await query.ExecuteNextAsync<T>());
|
||||
while (query.HasMoreResults)
|
||||
{
|
||||
results.AddRange(await query.ReadNextAsync());
|
||||
}
|
||||
}
|
||||
|
||||
return results;
|
||||
}
|
||||
|
||||
public static async Task<Document> CreateItemAsync(T item)
|
||||
public static async Task<T> CreateItemAsync(T item)
|
||||
{
|
||||
return await client.CreateDocumentAsync(UriFactory.CreateDocumentCollectionUri(DatabaseId, CollectionId), item);
|
||||
ItemResponse<T> response = await container.CreateItemAsync(item, PartitionKey.None);
|
||||
return response.Resource;
|
||||
}
|
||||
|
||||
public static async Task<Document> UpdateItemAsync(string id, T item)
|
||||
public static async Task<T> UpdateItemAsync(string id, T item)
|
||||
{
|
||||
return await client.ReplaceDocumentAsync(UriFactory.CreateDocumentUri(DatabaseId, CollectionId, id), item);
|
||||
ItemResponse<T> response = await container.UpsertItemAsync(item, PartitionKey.None);
|
||||
return response.Resource;
|
||||
}
|
||||
|
||||
public static async Task DeleteItemAsync(string id)
|
||||
{
|
||||
await client.DeleteDocumentAsync(UriFactory.CreateDocumentUri(DatabaseId, CollectionId, id));
|
||||
await container.DeleteItemAsync<T>(id, PartitionKey.None);
|
||||
}
|
||||
|
||||
public static void Initialize()
|
||||
{
|
||||
if (client == null)
|
||||
if (container == null)
|
||||
{
|
||||
client = new DocumentClient(new Uri(ServerlessLibrarySettings.CosmosEndpoint), ServerlessLibrarySettings.CosmosAuthkey);
|
||||
CreateDatabaseIfNotExistsAsync().Wait();
|
||||
CreateCollectionIfNotExistsAsync().Wait();
|
||||
}
|
||||
}
|
||||
CosmosClientBuilder cosmosClientBuilder = new CosmosClientBuilder(
|
||||
ServerlessLibrarySettings.CosmosEndpoint,
|
||||
ServerlessLibrarySettings.CosmosAuthkey);
|
||||
CosmosClient client = cosmosClientBuilder.Build();
|
||||
|
||||
private static async Task CreateDatabaseIfNotExistsAsync()
|
||||
{
|
||||
try
|
||||
{
|
||||
await client.ReadDatabaseAsync(UriFactory.CreateDatabaseUri(DatabaseId));
|
||||
}
|
||||
catch (DocumentClientException e)
|
||||
{
|
||||
if (e.StatusCode == System.Net.HttpStatusCode.NotFound)
|
||||
{
|
||||
await client.CreateDatabaseAsync(new Database { Id = DatabaseId });
|
||||
}
|
||||
else
|
||||
{
|
||||
throw;
|
||||
}
|
||||
}
|
||||
}
|
||||
DatabaseResponse databaseResponse = client.CreateDatabaseIfNotExistsAsync(DatabaseId).Result;
|
||||
Database database = databaseResponse;
|
||||
|
||||
private static async Task CreateCollectionIfNotExistsAsync()
|
||||
{
|
||||
try
|
||||
{
|
||||
await client.ReadDocumentCollectionAsync(UriFactory.CreateDocumentCollectionUri(DatabaseId, CollectionId));
|
||||
}
|
||||
catch (DocumentClientException e)
|
||||
{
|
||||
if (e.StatusCode == System.Net.HttpStatusCode.NotFound)
|
||||
{
|
||||
await client.CreateDocumentCollectionAsync(
|
||||
UriFactory.CreateDatabaseUri(DatabaseId),
|
||||
new DocumentCollection { Id = CollectionId },
|
||||
new RequestOptions { OfferThroughput = 400 });
|
||||
}
|
||||
else
|
||||
{
|
||||
throw;
|
||||
}
|
||||
ContainerResponse containerResponse = database.CreateContainerIfNotExistsAsync(id: CollectionId, partitionKeyPath: "/_partitionKey", throughput: 400).Result;
|
||||
container = containerResponse;
|
||||
}
|
||||
}
|
||||
}
|
||||
|
|
|
@ -18,11 +18,9 @@
|
|||
<PackageReference Include="Microsoft.AspNetCore.App" />
|
||||
<PackageReference Include="Microsoft.AspNetCore.Razor.Design" Version="2.1.2" PrivateAssets="All" />
|
||||
<PackageReference Include="Microsoft.AspNetCore.SpaServices.Extensions" Version="2.1.1" />
|
||||
<PackageReference Include="Microsoft.Azure.DocumentDB.Core" Version="2.17.0" />
|
||||
<PackageReference Include="Microsoft.Azure.Cosmos" Version="3.26.1" />
|
||||
<PackageReference Include="Microsoft.Extensions.Logging.ApplicationInsights" Version="2.9.1" />
|
||||
<PackageReference Include="Swashbuckle.AspNetCore" Version="4.0.1" />
|
||||
<PackageReference Include="Swashbuckle.AspNetCore.Swagger" Version="4.0.1" />
|
||||
<PackageReference Include="System.Configuration.ConfigurationManager" Version="4.5.0" />
|
||||
<PackageReference Include="System.Configuration.ConfigurationManager" Version="4.7.0" />
|
||||
<PackageReference Include="WindowsAzure.Storage" Version="9.3.3" />
|
||||
</ItemGroup>
|
||||
|
||||
|
|
|
@ -8,7 +8,6 @@ using Microsoft.Extensions.Configuration;
|
|||
using Microsoft.Extensions.DependencyInjection;
|
||||
using Microsoft.Extensions.Logging;
|
||||
using ServerlessLibrary.OAuth.GitHub;
|
||||
using Swashbuckle.AspNetCore.Swagger;
|
||||
using System.Threading.Tasks;
|
||||
|
||||
namespace ServerlessLibrary
|
||||
|
@ -36,7 +35,8 @@ namespace ServerlessLibrary
|
|||
.AddOAuth<GitHubAuthenticationOptions, GitHubAuthenticationHandler>(
|
||||
GitHubAuthenticationDefaults.AuthenticationScheme,
|
||||
GitHubAuthenticationDefaults.DisplayName,
|
||||
options => {
|
||||
options =>
|
||||
{
|
||||
options.ClientId = Configuration["Authentication:GitHub:ClientId"]; // these settings need to be present in appSettings (or in secrets.json)
|
||||
options.ClientSecret = Configuration["Authentication:GitHub:ClientSecret"];
|
||||
});
|
||||
|
@ -49,14 +49,15 @@ namespace ServerlessLibrary
|
|||
configuration.RootPath = "ClientApp/build";
|
||||
});
|
||||
|
||||
services.AddSwaggerGen(c =>
|
||||
{
|
||||
c.SwaggerDoc("v1", new Info
|
||||
{
|
||||
Title = "ASP.NET Core 2.0 Web API",
|
||||
Version = "v1"
|
||||
});
|
||||
});
|
||||
// ToDo: re-enable swagger
|
||||
//services.AddSwaggerGen(c =>
|
||||
//{
|
||||
// c.SwaggerDoc("v1", new Info
|
||||
// {
|
||||
// Title = "ASP.NET Core 2.0 Web API",
|
||||
// Version = "v1"
|
||||
// });
|
||||
//});
|
||||
|
||||
services.AddSingleton<ICacheService, CacheService>();
|
||||
services.AddSingleton<ILibraryStore, CosmosLibraryStore>();
|
||||
|
@ -70,11 +71,13 @@ namespace ServerlessLibrary
|
|||
app.UseDefaultFiles();
|
||||
app.UseStaticFiles();
|
||||
app.UseSpaStaticFiles();
|
||||
app.UseSwaggerUI(c =>
|
||||
{
|
||||
c.SwaggerEndpoint("/swagger/v1/swagger.json", "Serverless library API v1");
|
||||
c.RoutePrefix = "swagger";
|
||||
});
|
||||
|
||||
// ToDo: Re-enable swagger
|
||||
//app.UseSwaggerUI(c =>
|
||||
//{
|
||||
// c.SwaggerEndpoint("/swagger/v1/swagger.json", "Serverless library API v1");
|
||||
// c.RoutePrefix = "swagger";
|
||||
//});
|
||||
|
||||
app.UseAuthentication();
|
||||
|
||||
|
|
|
@ -7,8 +7,8 @@
|
|||
"repository": "https://github.com/anthonychu/azure-functions-openalpr",
|
||||
"description": "App for reading license plate info from a photo.",
|
||||
"language": "C# Script",
|
||||
"technologies": ["Functions 1.x"],
|
||||
"solutionareas": ["Machine Learning"],
|
||||
"technologies": [ "Functions 1.x" ],
|
||||
"solutionareas": [ "Machine Learning" ],
|
||||
"author": "anthonychu",
|
||||
"authortype": "Community",
|
||||
"tags": []
|
||||
|
@ -21,12 +21,12 @@
|
|||
"repository": "https://github.com/toolboc/stripe-function",
|
||||
"description": "Allows for incorporating Stripe payment functionality as a callable web service.",
|
||||
"language": "JavaScript",
|
||||
"technologies": ["Functions 1.x"],
|
||||
"technologies": [ "Functions 1.x" ],
|
||||
"blog": "http://pjdecarlo.com/2017/06/super-cheap-subscription-and-payment-services-with-stripe-on-microsoft-azure-using-serverless-code-via-azure-functions-node-js.html",
|
||||
"solutionareas": ["Integration"],
|
||||
"solutionareas": [ "Integration" ],
|
||||
"author": "toolboc",
|
||||
"authortype": "Community",
|
||||
"tags": ["Payment"]
|
||||
"tags": [ "Payment" ]
|
||||
},
|
||||
{
|
||||
"id": "7044ca9c-682a-408a-8acb-f17c552301bf",
|
||||
|
@ -36,8 +36,8 @@
|
|||
"repository": "https://github.com/burkeholland/weather-bulb",
|
||||
"description": "Timers that set the color of an LIFX bulb based on the outside temperature.",
|
||||
"language": "JavaScript",
|
||||
"technologies": ["Functions 1.x"],
|
||||
"solutionareas": ["Scheduled Jobs", "IoT"],
|
||||
"technologies": [ "Functions 1.x" ],
|
||||
"solutionareas": [ "Scheduled Jobs", "IoT" ],
|
||||
"author": "burkeholland",
|
||||
"authortype": "Community",
|
||||
"tags": []
|
||||
|
@ -50,8 +50,8 @@
|
|||
"repository": "https://github.com/nastassiar/crudfunctions",
|
||||
"description": "An HTTP API for CRUD operations against CosmosDB. (So boring, why would you write it yourself?!!)",
|
||||
"language": "JavaScript",
|
||||
"technologies": ["Functions 1.x", "Cosmos DB"],
|
||||
"solutionareas": ["Web API"],
|
||||
"technologies": [ "Functions 1.x", "Cosmos DB" ],
|
||||
"solutionareas": [ "Web API" ],
|
||||
"author": "nastassiar",
|
||||
"authortype": "Community"
|
||||
},
|
||||
|
@ -63,9 +63,9 @@
|
|||
"repository": "https://github.com/ricardodsanchez/WhatToBring",
|
||||
"description": "Returns a list of what items you should bring when traveling to certain cities.",
|
||||
"language": "JavaScript",
|
||||
"technologies": ["Functions 1.x"],
|
||||
"technologies": [ "Functions 1.x" ],
|
||||
"blog": "https://ricardodsanchez.com/what-can-you-do-with-azure-functions-heres-one-example/",
|
||||
"solutionareas": ["Web API"],
|
||||
"solutionareas": [ "Web API" ],
|
||||
"author": "ricardodsanchez",
|
||||
"authortype": "Community"
|
||||
},
|
||||
|
@ -78,8 +78,8 @@
|
|||
"description": "This simple demo game is used to teach basic concepts around building Azure Functions with node.js.",
|
||||
"blog": "https://aka.ms/aztugofwar",
|
||||
"language": "JavaScript",
|
||||
"technologies": ["Functions 2.x", "App Service"],
|
||||
"solutionareas": ["Web API", "Event Processing", "Gaming"],
|
||||
"technologies": [ "Functions 2.x", "App Service" ],
|
||||
"solutionareas": [ "Web API", "Event Processing", "Gaming" ],
|
||||
"author": "joescars",
|
||||
"authortype": "Community"
|
||||
},
|
||||
|
@ -91,8 +91,8 @@
|
|||
"repository": "https://github.com/akos-sebestyen/purolator-tracker",
|
||||
"description": "App for tracking Purolator shipments.",
|
||||
"language": "JavaScript",
|
||||
"technologies": ["Functions 1.x"],
|
||||
"solutionareas": ["Event Processing", "Scheduled Jobs"],
|
||||
"technologies": [ "Functions 1.x" ],
|
||||
"solutionareas": [ "Event Processing", "Scheduled Jobs" ],
|
||||
"author": "akos-sebestyen",
|
||||
"authortype": "Community"
|
||||
},
|
||||
|
@ -104,8 +104,8 @@
|
|||
"repository": "https://github.com/anthonychu/azure-functions-raffle",
|
||||
"description": "A simple raffle application.",
|
||||
"language": "C# Script",
|
||||
"technologies": ["Functions 1.x"],
|
||||
"solutionareas": ["Web API", "Static Website", "Gaming"],
|
||||
"technologies": [ "Functions 1.x" ],
|
||||
"solutionareas": [ "Web API", "Static Website", "Gaming" ],
|
||||
"author": "anthonychu",
|
||||
"authortype": "Community"
|
||||
},
|
||||
|
@ -117,8 +117,8 @@
|
|||
"repository": "https://github.com/jefking/fn-smart-thumbnail",
|
||||
"description": "Test your own images in bulk against Microsoft Cognitive Services: Smart Thumbnail API.",
|
||||
"language": "C# Script",
|
||||
"technologies": ["Functions 2.x", "Blob Storage"],
|
||||
"solutionareas": ["Machine Learning"],
|
||||
"technologies": [ "Functions 2.x", "Blob Storage" ],
|
||||
"solutionareas": [ "Machine Learning" ],
|
||||
"author": "jefking",
|
||||
"authortype": "Community"
|
||||
},
|
||||
|
@ -130,8 +130,8 @@
|
|||
"repository": "https://github.com/jefking/fn-computer-vision",
|
||||
"description": "Test your own images in bulk against Microsoft Cognitive Services: Computer Vision API.",
|
||||
"language": "C# Script",
|
||||
"technologies": ["Functions 1.x", "Cognitive Services"],
|
||||
"solutionareas": ["Machine Learning"],
|
||||
"technologies": [ "Functions 1.x", "Cognitive Services" ],
|
||||
"solutionareas": [ "Machine Learning" ],
|
||||
"author": "jefking",
|
||||
"authortype": "Community"
|
||||
},
|
||||
|
@ -143,8 +143,8 @@
|
|||
"repository": "https://github.com/nastassiar/RecognizeTextFunction",
|
||||
"description": "Test your own images in bulk against Microsoft Cognitive Services: OCR.",
|
||||
"language": "C# Script",
|
||||
"technologies": ["Functions 1.x", "Blob Storage"],
|
||||
"solutionareas": ["Machine Learning"],
|
||||
"technologies": [ "Functions 1.x", "Blob Storage" ],
|
||||
"solutionareas": [ "Machine Learning" ],
|
||||
"author": "nastassiar",
|
||||
"authortype": "Community"
|
||||
},
|
||||
|
@ -156,8 +156,8 @@
|
|||
"repository": "https://github.com/Azure-Samples/functions-node-sas-token",
|
||||
"description": "This is a sample HTTP trigger Azure Function that returns a SAS token for Azure Storage for the specified container, blob, and permissions.",
|
||||
"language": "JavaScript",
|
||||
"technologies": ["Functions 1.x", "Blob Storage"],
|
||||
"solutionareas": ["Web API", "Authentication"],
|
||||
"technologies": [ "Functions 1.x", "Blob Storage" ],
|
||||
"solutionareas": [ "Web API", "Authentication" ],
|
||||
"author": "Azure-Samples",
|
||||
"authortype": "Microsoft"
|
||||
},
|
||||
|
@ -169,8 +169,8 @@
|
|||
"repository": "https://github.com/m-gagne/PDF2AzSearch",
|
||||
"description": "This Azure Function binds to an Azure Storage container to process PDF files, extract metadata (using Regular Expressions), stores the result in DocumentDB (extracted text + captured metadata) which can then be used by Azure Search",
|
||||
"language": "JavaScript",
|
||||
"technologies": ["Functions 1.x", "Blob Storage", "Cosmos DB"],
|
||||
"solutionareas": ["Data Processing"],
|
||||
"technologies": [ "Functions 1.x", "Blob Storage", "Cosmos DB" ],
|
||||
"solutionareas": [ "Data Processing" ],
|
||||
"author": "m-gagne",
|
||||
"authortype": "Community"
|
||||
},
|
||||
|
@ -182,8 +182,8 @@
|
|||
"repository": "https://github.com/AzureBytes/functionsstorsql",
|
||||
"description": "Stores a queue message in SQL Database; uses Entity Framework.",
|
||||
"language": "C# Script",
|
||||
"technologies": ["Functions 1.x", "SQL Server"],
|
||||
"solutionareas": ["Data Processing"],
|
||||
"technologies": [ "Functions 1.x", "SQL Server" ],
|
||||
"solutionareas": [ "Data Processing" ],
|
||||
"author": "AzureBytes",
|
||||
"authortype": "Community"
|
||||
},
|
||||
|
@ -195,8 +195,8 @@
|
|||
"repository": "https://github.com/jefking/fl-image-resize",
|
||||
"description": "The easiest way to resize images stored in Blob Storage (on Azure); uses ImageProcessor.",
|
||||
"language": "C#",
|
||||
"technologies": ["Functions 1.x", "Blob Storage"],
|
||||
"solutionareas": ["Data Processing"],
|
||||
"technologies": [ "Functions 1.x", "Blob Storage" ],
|
||||
"solutionareas": [ "Data Processing" ],
|
||||
"author": "jefking",
|
||||
"authortype": "Community"
|
||||
},
|
||||
|
@ -209,8 +209,8 @@
|
|||
"description": "Sends a Slackbot notification to specified users or channels when users are added or removed from Slack.",
|
||||
"language": "C# Script",
|
||||
"blog": "https://github.com/cfe84/slack-users-change-alerts",
|
||||
"technologies": ["Functions 1.x"],
|
||||
"solutionareas": ["Event Processing"],
|
||||
"technologies": [ "Functions 1.x" ],
|
||||
"solutionareas": [ "Event Processing" ],
|
||||
"author": "anthonychu",
|
||||
"authortype": "Community"
|
||||
},
|
||||
|
@ -223,8 +223,8 @@
|
|||
"description": "The Closed-Loop function binds to the Event Hub compatible name of an IoT Hub. Each message into the IoT Hub will trigger the function. The sample function reads the JSON message payload, deserializes it, adds the two integer values (DataPoint1 and DataPoint2), and sends the sum back to the device, via IoT Hub, using a C2D message.",
|
||||
"addTemplate": "https://raw.githubusercontent.com/fashaikh/AzureFunctions/master/ClosedLoopFunction/deploy/addfunction.json",
|
||||
"language": "C# Script",
|
||||
"technologies": ["Functions 1.x"],
|
||||
"solutionareas": ["IoT", "Data Processing"],
|
||||
"technologies": [ "Functions 1.x" ],
|
||||
"solutionareas": [ "IoT", "Data Processing" ],
|
||||
"author": "khilscher",
|
||||
"authortype": "Community"
|
||||
},
|
||||
|
@ -237,8 +237,8 @@
|
|||
"description": "Serves a static website from a www root with a default index.html page.",
|
||||
"blog": "http://anthonychu.ca/post/azure-functions-static-file-server",
|
||||
"language": "C# Script",
|
||||
"technologies": ["Functions 1.x"],
|
||||
"solutionareas": ["Web API", "Static Website"],
|
||||
"technologies": [ "Functions 1.x" ],
|
||||
"solutionareas": [ "Web API", "Static Website" ],
|
||||
"author": "anthonychu",
|
||||
"authortype": "Community"
|
||||
},
|
||||
|
@ -250,8 +250,8 @@
|
|||
"repository": "https://github.com/jefking/fl-default-static",
|
||||
"description": "Defaults page (index.htm) for containers. No need for compute on top of raw storage; if you are running static sites. This deployment contains a CDN layered 'over top' of the function.",
|
||||
"language": "JavaScript",
|
||||
"technologies": ["Functions 1.x", "Blob Storage"],
|
||||
"solutionareas": ["Static Website"],
|
||||
"technologies": [ "Functions 1.x", "Blob Storage" ],
|
||||
"solutionareas": [ "Static Website" ],
|
||||
"author": "jefking",
|
||||
"authortype": "Community"
|
||||
},
|
||||
|
@ -263,8 +263,8 @@
|
|||
"repository": "https://github.com/Azure-Samples/consumption-cost-node",
|
||||
"description": "This sample demonstrates how to use the Azure billing commerce APIs to find consumption cost per subscription and resource-groups.",
|
||||
"language": "JavaScript",
|
||||
"technologies": ["Functions 1.x"],
|
||||
"solutionareas": ["Web API", "Authentication"],
|
||||
"technologies": [ "Functions 1.x" ],
|
||||
"solutionareas": [ "Web API", "Authentication" ],
|
||||
"author": "Azure-Samples",
|
||||
"authortype": "Microsoft"
|
||||
},
|
||||
|
@ -276,8 +276,8 @@
|
|||
"repository": "https://github.com/Azure/azure-quickstart-templates/tree/master/101-logic-app-sql-proc",
|
||||
"description": "This template allows you to create a Logic App that will run a SQL stored procedure on schedule. Any arguments for the procedure can be put into the body section of the template.",
|
||||
"language": "na",
|
||||
"technologies": ["Logic Apps", "SQL Server"],
|
||||
"solutionareas": ["Integration", "Scheduled Jobs"],
|
||||
"technologies": [ "Logic Apps", "SQL Server" ],
|
||||
"solutionareas": [ "Integration", "Scheduled Jobs" ],
|
||||
"author": "Azure",
|
||||
"authortype": "Microsoft"
|
||||
},
|
||||
|
@ -289,8 +289,8 @@
|
|||
"repository": "https://github.com/Azure/azure-quickstart-templates/tree/master/101-logic-app-sendgrid",
|
||||
"description": "This template allows you to create a Logic app that sends an email. You can add an additional triggers or actions to customize it to your needs.",
|
||||
"language": "na",
|
||||
"technologies": ["Logic Apps"],
|
||||
"solutionareas": ["Integration"],
|
||||
"technologies": [ "Logic Apps" ],
|
||||
"solutionareas": [ "Integration" ],
|
||||
"author": "Azure",
|
||||
"authortype": "Microsoft"
|
||||
},
|
||||
|
@ -302,8 +302,8 @@
|
|||
"repository": "https://github.com/Azure/azure-quickstart-templates/tree/master/101-logic-app-ftp-to-blob",
|
||||
"description": "This template allows you to create a Logic app that listens to a folder on an FTP server and will copy it to an Azure Blob container. You can add an additional triggers or actions to customize it to your needs.",
|
||||
"language": "na",
|
||||
"technologies": ["Logic Apps", "Blob Storage"],
|
||||
"solutionareas": ["Integration"],
|
||||
"technologies": [ "Logic Apps", "Blob Storage" ],
|
||||
"solutionareas": [ "Integration" ],
|
||||
"author": "Azure",
|
||||
"authortype": "Microsoft"
|
||||
},
|
||||
|
@ -315,8 +315,8 @@
|
|||
"repository": "https://github.com/jefking/fn-http-queue-s",
|
||||
"description": "Posted messages get added to Azure Storage Queue.",
|
||||
"language": "JavaScript",
|
||||
"technologies": ["Functions 1.x", "Storage Queue"],
|
||||
"solutionareas": ["Web API", "Data Processing"],
|
||||
"technologies": [ "Functions 1.x", "Storage Queue" ],
|
||||
"solutionareas": [ "Web API", "Data Processing" ],
|
||||
"author": "jefking",
|
||||
"authortype": "Community"
|
||||
},
|
||||
|
@ -328,8 +328,8 @@
|
|||
"repository": "https://github.com/jefking/fn-http-queue-sb",
|
||||
"description": "Posted messages get added to Azure Service Bus Queue.",
|
||||
"language": "JavaScript",
|
||||
"technologies": ["Functions 1.x", "Service Bus Queue"],
|
||||
"solutionareas": ["Web API", "Data Processing"],
|
||||
"technologies": [ "Functions 1.x", "Service Bus Queue" ],
|
||||
"solutionareas": [ "Web API", "Data Processing" ],
|
||||
"author": "jefking",
|
||||
"authortype": "Community"
|
||||
},
|
||||
|
@ -341,8 +341,8 @@
|
|||
"repository": "https://github.com/jefking/fn-http-topic",
|
||||
"description": "Posted messages get added to Azure Service Bus Topic.",
|
||||
"language": "JavaScript",
|
||||
"technologies": ["Functions 1.x"],
|
||||
"solutionareas": ["Web API", "Data Processing"],
|
||||
"technologies": [ "Functions 1.x" ],
|
||||
"solutionareas": [ "Web API", "Data Processing" ],
|
||||
"author": "jefking",
|
||||
"authortype": "Community"
|
||||
},
|
||||
|
@ -354,8 +354,8 @@
|
|||
"repository": "https://github.com/jefking/fn-webhook-queue",
|
||||
"description": "Posted Body gets added to Azure Service Bus Queue.",
|
||||
"language": "JavaScript",
|
||||
"technologies": ["Functions 1.x", "Service Bus Queue"],
|
||||
"solutionareas": ["Web API", "Data Processing"],
|
||||
"technologies": [ "Functions 1.x", "Service Bus Queue" ],
|
||||
"solutionareas": [ "Web API", "Data Processing" ],
|
||||
"author": "jefking",
|
||||
"authortype": "Community"
|
||||
},
|
||||
|
@ -367,8 +367,8 @@
|
|||
"repository": "https://github.com/isaac2004/RedditPoller",
|
||||
"description": "Scheduled email notifications of Reddit Posts",
|
||||
"language": "C#",
|
||||
"technologies": ["Functions 1.x"],
|
||||
"solutionareas": ["Scheduled Jobs"],
|
||||
"technologies": [ "Functions 1.x" ],
|
||||
"solutionareas": [ "Scheduled Jobs" ],
|
||||
"author": "isaac2004",
|
||||
"authortype": "Community"
|
||||
},
|
||||
|
@ -380,13 +380,8 @@
|
|||
"repository": "https://github.com/Azure-Samples/media-services-dotnet-functions-integration",
|
||||
"description": "Sample for use with Azure Media Services. Ingest from Azure Blobs, encode and output to Azure Blobs, monitor encoding progress, and use WebHooks or Queues to hook into the workflow.",
|
||||
"language": "C# Script",
|
||||
"technologies": ["Functions 1.x", "Storage Queue"],
|
||||
"solutionareas": [
|
||||
"Data Processing",
|
||||
"Web API",
|
||||
"Integration",
|
||||
"Automation"
|
||||
],
|
||||
"technologies": [ "Functions 1.x", "Storage Queue" ],
|
||||
"solutionareas": [ "Data Processing", "Web API", "Integration", "Automation" ],
|
||||
"author": "jefking",
|
||||
"authortype": "Community"
|
||||
},
|
||||
|
@ -398,13 +393,8 @@
|
|||
"repository": "https://github.com/Azure-Samples/functions-dotnet-codercards",
|
||||
"description": "CoderCards is a geek trading card generator. It uses Microsoft Cognitive Services to detect the predominant emotion in a face, which is used to choose a card back.",
|
||||
"language": "C#",
|
||||
"technologies": ["Functions 1.x", "Blob Storage", "Cognitive Services"],
|
||||
"solutionareas": [
|
||||
"Web API",
|
||||
"Machine Learning",
|
||||
"Static Website",
|
||||
"Data Processing"
|
||||
],
|
||||
"technologies": [ "Functions 1.x", "Blob Storage", "Cognitive Services" ],
|
||||
"solutionareas": [ "Web API", "Machine Learning", "Static Website", "Data Processing" ],
|
||||
"author": "Azure-Samples",
|
||||
"authortype": "Microsoft"
|
||||
},
|
||||
|
@ -416,8 +406,8 @@
|
|||
"repository": "https://github.com/Azure/azure-quickstart-templates/tree/master/101-logic-app-and-function-app",
|
||||
"description": "This template creates a Serverless app in Azure with Logic Apps and Functions. The Logic App triggers on an HTTP POST, calls the Azure Function, and returns the response.",
|
||||
"language": "na",
|
||||
"technologies": ["Functions 1.x", "Logic Apps"],
|
||||
"solutionareas": ["Integration"],
|
||||
"technologies": [ "Functions 1.x", "Logic Apps" ],
|
||||
"solutionareas": [ "Integration" ],
|
||||
"author": "Azure",
|
||||
"authortype": "Microsoft"
|
||||
},
|
||||
|
@ -429,8 +419,8 @@
|
|||
"repository": "https://github.com/Azure/azure-quickstart-templates/tree/master/101-logic-app-create",
|
||||
"description": "Create a Logic App from a template",
|
||||
"language": "na",
|
||||
"technologies": ["Logic Apps"],
|
||||
"solutionareas": ["Integration"],
|
||||
"technologies": [ "Logic Apps" ],
|
||||
"solutionareas": [ "Integration" ],
|
||||
"author": "Azure",
|
||||
"authortype": "Microsoft"
|
||||
},
|
||||
|
@ -442,8 +432,8 @@
|
|||
"repository": "https://github.com/Azure/azure-quickstart-templates/tree/master/201-logic-app-xslt-with-params",
|
||||
"description": "This template creates a request-response Logic App which performs XSLT based transformation. The XSLT map takes primitives (integer, string etc.) as input parameters as uses them during XML transformation.",
|
||||
"language": "na",
|
||||
"technologies": ["Logic Apps"],
|
||||
"solutionareas": ["Integration", "Data Processing"],
|
||||
"technologies": [ "Logic Apps" ],
|
||||
"solutionareas": [ "Integration", "Data Processing" ],
|
||||
"author": "Azure",
|
||||
"authortype": "Microsoft"
|
||||
},
|
||||
|
@ -455,8 +445,8 @@
|
|||
"repository": "https://github.com/Azure/azure-quickstart-templates/tree/master/201-logic-app-veter-pipeline",
|
||||
"description": "This template creates a VETER pipeline using Logic Apps.",
|
||||
"language": "na",
|
||||
"technologies": ["Logic Apps"],
|
||||
"solutionareas": ["Integration", "Data Processing"],
|
||||
"technologies": [ "Logic Apps" ],
|
||||
"solutionareas": [ "Integration", "Data Processing" ],
|
||||
"author": "Azure",
|
||||
"authortype": "Microsoft"
|
||||
},
|
||||
|
@ -468,8 +458,8 @@
|
|||
"repository": "https://github.com/Azure/azure-quickstart-templates/tree/master/201-logic-app-transform-function",
|
||||
"description": "This template creates a webhook based C# azure function with transform capabilites to use in logic apps integration scenarios.",
|
||||
"language": "C# Script",
|
||||
"technologies": ["Functions 1.x", "Logic Apps"],
|
||||
"solutionareas": ["Integration", "Web API"],
|
||||
"technologies": [ "Functions 1.x", "Logic Apps" ],
|
||||
"solutionareas": [ "Integration", "Web API" ],
|
||||
"author": "Azure",
|
||||
"authortype": "Microsoft"
|
||||
},
|
||||
|
@ -481,8 +471,8 @@
|
|||
"repository": "https://github.com/Azure/azure-quickstart-templates/tree/master/201-logic-app-custom-api",
|
||||
"description": "Call into your own custom API that can run your own code.",
|
||||
"language": "na",
|
||||
"technologies": ["Logic Apps", "App Service", "Azure Active Directory"],
|
||||
"solutionareas": ["Integration", "Authentication", "Web API"],
|
||||
"technologies": [ "Logic Apps", "App Service", "Azure Active Directory" ],
|
||||
"solutionareas": [ "Integration", "Authentication", "Web API" ],
|
||||
"author": "Azure",
|
||||
"authortype": "Microsoft"
|
||||
},
|
||||
|
@ -494,8 +484,8 @@
|
|||
"repository": "https://github.com/Azure/azure-quickstart-templates/tree/master/201-logic-app-b2b-disaster-recovery-replication",
|
||||
"description": "This template demonstrates B2B Disaster Recovery replication using Logic Apps.",
|
||||
"language": "na",
|
||||
"technologies": ["Logic Apps", "Azure Active Directory"],
|
||||
"solutionareas": ["Automation"],
|
||||
"technologies": [ "Logic Apps", "Azure Active Directory" ],
|
||||
"solutionareas": [ "Automation" ],
|
||||
"author": "Azure",
|
||||
"authortype": "Microsoft"
|
||||
},
|
||||
|
@ -507,8 +497,8 @@
|
|||
"repository": "https://github.com/Azure/azure-quickstart-templates/tree/master/201-logic-app-as2-send-receive",
|
||||
"description": "This template demonstrates AS2 Send Receive using Logic Apps.",
|
||||
"language": "na",
|
||||
"technologies": ["Logic Apps"],
|
||||
"solutionareas": ["Integration"],
|
||||
"technologies": [ "Logic Apps" ],
|
||||
"solutionareas": [ "Integration" ],
|
||||
"author": "Azure",
|
||||
"authortype": "Microsoft"
|
||||
},
|
||||
|
@ -520,13 +510,8 @@
|
|||
"repository": "https://github.com/Azure/azure-quickstart-templates/tree/master/201-alert-to-queue-with-logic-app",
|
||||
"description": "Add the alert payload you pass to an Azure Storage queue that you specify.",
|
||||
"language": "na",
|
||||
"technologies": ["Logic Apps", "Storage Queue"],
|
||||
"solutionareas": [
|
||||
"Event Processing",
|
||||
"Web API",
|
||||
"Integration",
|
||||
"Automation"
|
||||
],
|
||||
"technologies": [ "Logic Apps", "Storage Queue" ],
|
||||
"solutionareas": [ "Event Processing", "Web API", "Integration", "Automation" ],
|
||||
"author": "Azure",
|
||||
"authortype": "Microsoft"
|
||||
},
|
||||
|
@ -538,8 +523,8 @@
|
|||
"repository": "https://github.com/Azure/azure-quickstart-templates/tree/master/201-alert-to-slack-with-logic-app",
|
||||
"description": "When the Alert is triggered, it will post a message to a slack channel that you specify",
|
||||
"language": "na",
|
||||
"technologies": ["Logic Apps"],
|
||||
"solutionareas": ["Integration", "Event Processing"],
|
||||
"technologies": [ "Logic Apps" ],
|
||||
"solutionareas": [ "Integration", "Event Processing" ],
|
||||
"author": "Azure",
|
||||
"authortype": "Microsoft"
|
||||
},
|
||||
|
@ -551,8 +536,8 @@
|
|||
"repository": "https://github.com/Azure/azure-quickstart-templates/tree/master/201-alert-to-text-message-with-logic-app",
|
||||
"description": "When the Alert is triggered, it will send you a text message with the details of the alert.",
|
||||
"language": "na",
|
||||
"technologies": ["Logic Apps"],
|
||||
"solutionareas": ["Integration", "Web API"],
|
||||
"technologies": [ "Logic Apps" ],
|
||||
"solutionareas": [ "Integration", "Web API" ],
|
||||
"author": "Azure",
|
||||
"authortype": "Microsoft"
|
||||
},
|
||||
|
@ -564,10 +549,11 @@
|
|||
"repository": "https://github.com/wilfriedwoivre/azure-sandbox-function",
|
||||
"description": "Provide API to create temporary Resource Group. Provide function to remove temporary resource group each day",
|
||||
"language": "C# Script",
|
||||
"technologies": ["Functions 2.x"],
|
||||
"solutionareas": ["Automation", "Web API"],
|
||||
"technologies": [ "Functions 2.x" ],
|
||||
"solutionareas": [ "Automation", "Web API" ],
|
||||
"author": "wilfriedwoivre",
|
||||
"authortype": "Community"
|
||||
"authortype": "Community",
|
||||
|
||||
},
|
||||
{
|
||||
"id": "3a3d0bc3-c100-40a1-941d-6fdbce38415b",
|
||||
|
@ -577,8 +563,8 @@
|
|||
"repository": "https://github.com/nastassiar/WebRequestFunction",
|
||||
"description": "Triggered every 5 minutes to do a GET from an API, check for duplicated records in Azure blob storage it has already seen and POST any new alerts to another API.",
|
||||
"language": "C#",
|
||||
"technologies": ["Functions 2.x"],
|
||||
"solutionareas": ["Scheduled Jobs", "Integration"],
|
||||
"technologies": [ "Functions 2.x" ],
|
||||
"solutionareas": [ "Scheduled Jobs", "Integration" ],
|
||||
"author": "nastassiar",
|
||||
"authortype": "Community"
|
||||
},
|
||||
|
@ -590,8 +576,8 @@
|
|||
"repository": "https://github.com/keesschollaart81/CaseOnline.Azure.WebJobs.Extensions.Mqtt",
|
||||
"description": "Trigger your function by- and publish messages to your MQTT topics",
|
||||
"language": "C#",
|
||||
"technologies": ["Functions 2.x"],
|
||||
"solutionareas": ["Event Processing"],
|
||||
"technologies": [ "Functions 2.x" ],
|
||||
"solutionareas": [ "Event Processing" ],
|
||||
"author": "keesschollaart81",
|
||||
"authortype": "Community"
|
||||
},
|
||||
|
@ -603,8 +589,8 @@
|
|||
"repository": "https://github.com/aliencube/ARM-Deployment-History-Cleaner",
|
||||
"description": "This provides Azure Logic Apps to clean up ARM deployment history before hitting 800 limits.",
|
||||
"language": "na",
|
||||
"technologies": ["Logic Apps"],
|
||||
"solutionareas": ["Automation"],
|
||||
"technologies": [ "Logic Apps" ],
|
||||
"solutionareas": [ "Automation" ],
|
||||
"author": "justinyoo",
|
||||
"authortype": "Community"
|
||||
},
|
||||
|
@ -616,8 +602,8 @@
|
|||
"repository": "https://github.com/aliencube/Key-Vault-Connector-for-Logic-Apps",
|
||||
"description": "This provides a custom Key Vault API Connector for Logic Apps.",
|
||||
"language": "C#",
|
||||
"technologies": ["Functions 2.x", "Logic Apps", "Key Vault"],
|
||||
"solutionareas": ["Integration", " Authentication"],
|
||||
"technologies": [ "Functions 2.x", "Logic Apps", "Key Vault" ],
|
||||
"solutionareas": [ "Integration", " Authentication" ],
|
||||
"author": "justinyoo",
|
||||
"authortype": "Community"
|
||||
},
|
||||
|
@ -629,8 +615,8 @@
|
|||
"repository": "https://github.com/anirudhgarg/functions-logicapp-startstopvms",
|
||||
"description": "This solution allows you to Start and Stop Azure VM's for a given Subscription, Resource Group or Tags based on a schedule. The implementation uses Azure VM async API's and hence potentially hundreds of VM's can be started/stopped.",
|
||||
"language": "na",
|
||||
"technologies": ["Functions 2.x", "Logic Apps"],
|
||||
"solutionareas": ["Automation", "Integration", " Authentication"],
|
||||
"technologies": [ "Functions 2.x", "Logic Apps" ],
|
||||
"solutionareas": [ "Automation", "Integration", " Authentication" ],
|
||||
"author": "anirudhgarg",
|
||||
"authortype": "Community"
|
||||
},
|
||||
|
@ -642,8 +628,8 @@
|
|||
"repository": "https://github.com/JimPaine/Azure-Functions-KeyVault-Demo",
|
||||
"description": "A demo showing how to use @Microsoft.KeyVault in appsettings for simplified secret management",
|
||||
"language": "C# Script",
|
||||
"technologies": ["Functions 1.x", "Key Vault"],
|
||||
"solutionareas": ["Authentication"],
|
||||
"technologies": [ "Functions 1.x", "Key Vault" ],
|
||||
"solutionareas": [ "Authentication" ],
|
||||
"author": "JimPaine",
|
||||
"authortype": "Community"
|
||||
},
|
||||
|
@ -655,13 +641,8 @@
|
|||
"repository": "https://github.com/JimPaine/emotion-checker",
|
||||
"description": "An HTML5 page which streams your camera to the Face API for age and emotion, all via a V2 function",
|
||||
"language": "C#",
|
||||
"technologies": [
|
||||
"Functions 2.x",
|
||||
"Cognitive Services",
|
||||
"Key Vault",
|
||||
"Blob Storage"
|
||||
],
|
||||
"solutionareas": ["Static Website", "Authentication"],
|
||||
"technologies": [ "Functions 2.x", "Cognitive Services", "Key Vault", "Blob Storage" ],
|
||||
"solutionareas": [ "Static Website", "Authentication" ],
|
||||
"author": "JimPaine",
|
||||
"authortype": "Community"
|
||||
},
|
||||
|
@ -673,8 +654,8 @@
|
|||
"repository": "https://github.com/eavanvalkenburg/http_to_powerbi_function",
|
||||
"description": "This Function examples uses the Push Rest API of PowerBI to push data into it, the content of your request (in json) needs to match the datastructure in json for it to work.",
|
||||
"language": "C# Script",
|
||||
"technologies": ["Functions 1.x"],
|
||||
"solutionareas": ["Web API", "Data Processing"],
|
||||
"technologies": [ "Functions 1.x" ],
|
||||
"solutionareas": [ "Web API", "Data Processing" ],
|
||||
"author": "eavanvalkenburg",
|
||||
"authortype": "Community"
|
||||
},
|
||||
|
@ -686,8 +667,8 @@
|
|||
"repository": "https://github.com/0GiS0/azure-functions-loves-twilio",
|
||||
"description": "It sends and receives SMS using Twilio and Azure Functions. It is based on three functions: HandleMessage, which receives the message that you want to send. SendSMS, which sends the message to Twilio.SMSReceived, the SMS sent by the user to a specific Twilio mobile number is received.",
|
||||
"language": "JavaScript",
|
||||
"technologies": ["Functions 1.x"],
|
||||
"solutionareas": ["Web API", "Event Processing"],
|
||||
"technologies": [ "Functions 1.x" ],
|
||||
"solutionareas": [ "Web API", "Event Processing" ],
|
||||
"author": "0GiS0",
|
||||
"authortype": "Community"
|
||||
},
|
||||
|
@ -699,8 +680,8 @@
|
|||
"repository": "https://github.com/0GiS0/audio-azure-functions",
|
||||
"description": "Conversions using ffmpeg and transcriptions with Speech Service: Mp3ToWav: It converts from MP3 to WAV in order to be treated by Speech service from Cognitive Services, but it can be used simply as a transformation method. WavToText: Use Speech Service to get the audio transcript.",
|
||||
"language": "C#",
|
||||
"technologies": ["Functions 2.x", "Cognitive Services"],
|
||||
"solutionareas": ["Data Processing"],
|
||||
"technologies": [ "Functions 2.x", "Cognitive Services" ],
|
||||
"solutionareas": [ "Data Processing" ],
|
||||
"author": "0GiS0",
|
||||
"authortype": "Community"
|
||||
},
|
||||
|
@ -712,8 +693,8 @@
|
|||
"repository": "https://github.com/0GiS0/azure-function-clean-exif",
|
||||
"description": "It removes file metadata using Azure Functions.",
|
||||
"language": "JavaScript",
|
||||
"technologies": ["Functions 2.x", "Blob Storage"],
|
||||
"solutionareas": ["Data Processing"],
|
||||
"technologies": [ "Functions 2.x", "Blob Storage" ],
|
||||
"solutionareas": [ "Data Processing" ],
|
||||
"author": "0GiS0",
|
||||
"authortype": "Community"
|
||||
},
|
||||
|
@ -725,8 +706,8 @@
|
|||
"repository": "https://github.com/raahmed/BlobStorageTrigger",
|
||||
"description": "This application takes a specific type of csv file (detailed in the project README), cleans the data and then places the contents in .json format into a Queue.",
|
||||
"language": "Python",
|
||||
"technologies": ["Functions 2.x", "Blob Storage"],
|
||||
"solutionareas": ["Data Processing"],
|
||||
"technologies": [ "Functions 2.x", "Blob Storage" ],
|
||||
"solutionareas": [ "Data Processing" ],
|
||||
"author": "raahmed",
|
||||
"authortype": "Community"
|
||||
},
|
||||
|
@ -738,8 +719,8 @@
|
|||
"repository": "https://github.com/gdprtcl/AzDevOps-AzLA",
|
||||
"description": "Create a Logic App to notify an individual over mail whenever he/she is assigned to a Work Item (Bug) with high priority.",
|
||||
"language": "na",
|
||||
"technologies": ["Logic Apps"],
|
||||
"solutionareas": ["Automation"],
|
||||
"technologies": [ "Logic Apps" ],
|
||||
"solutionareas": [ "Automation" ],
|
||||
"author": "gdprtcl",
|
||||
"authortype": "Community"
|
||||
},
|
||||
|
@ -751,18 +732,8 @@
|
|||
"repository": "https://github.com/daniel-rocha/azure-functions-java-bindings",
|
||||
"description": "20+ ready-to-use examples of triggers and bindings with Azure Java Functions",
|
||||
"language": "Java",
|
||||
"technologies": [
|
||||
"Functions 2.x",
|
||||
"Cosmos DB",
|
||||
"Blob Storage",
|
||||
"Event Grid"
|
||||
],
|
||||
"solutionareas": [
|
||||
"Data Processing",
|
||||
"Event Processing",
|
||||
"Web API",
|
||||
"Integration"
|
||||
],
|
||||
"technologies": [ "Functions 2.x", "Cosmos DB", "Blob Storage", "Event Grid" ],
|
||||
"solutionareas": [ "Data Processing", "Event Processing", "Web API", "Integration" ],
|
||||
"author": "daniel-rocha",
|
||||
"authortype": "Community"
|
||||
},
|
||||
|
@ -774,8 +745,8 @@
|
|||
"repository": "https://github.com/raahmed/QueueStorageTrigger",
|
||||
"description": "A series of events in queue storage are collected and added to CosmosDB.",
|
||||
"language": "Python",
|
||||
"technologies": ["Functions 1.x", "Cosmos DB", "Storage Queue"],
|
||||
"solutionareas": ["Data Processing"],
|
||||
"technologies": [ "Functions 1.x", "Cosmos DB", "Storage Queue" ],
|
||||
"solutionareas": [ "Data Processing" ],
|
||||
"author": "raahmed",
|
||||
"authortype": "Community"
|
||||
},
|
||||
|
@ -787,8 +758,8 @@
|
|||
"repository": "https://github.com/paulbatum/pull-request-reviewer",
|
||||
"description": "A simple example of using Azure Functions to implement a GitHub webhook",
|
||||
"language": "JavaScript",
|
||||
"technologies": ["Functions 2.x"],
|
||||
"solutionareas": ["Automation", "Web API", "Authentication"],
|
||||
"technologies": [ "Functions 2.x" ],
|
||||
"solutionareas": [ "Automation", "Web API", "Authentication" ],
|
||||
"author": "paulbatum",
|
||||
"authortype": "Community"
|
||||
},
|
||||
|
@ -800,8 +771,8 @@
|
|||
"repository": "https://github.com/mhoeger/functions-typescript-intermediate",
|
||||
"description": "A function app written in TypeScript that shows how to create backend API functions that use custom routes, npm modules, and globally shared code between functions.",
|
||||
"language": "TypeScript",
|
||||
"technologies": ["Functions 2.x"],
|
||||
"solutionareas": ["Web API"],
|
||||
"technologies": [ "Functions 2.x" ],
|
||||
"solutionareas": [ "Web API" ],
|
||||
"author": "mhoeger",
|
||||
"authortype": "Community"
|
||||
},
|
||||
|
@ -813,8 +784,8 @@
|
|||
"repository": "https://github.com/simonaco/nodebinar",
|
||||
"description": "Build a serverless API with Node.js on top of Azure Functions and Azure Cosmos DB",
|
||||
"language": "JavaScript",
|
||||
"technologies": ["Functions 2.x"],
|
||||
"solutionareas": ["Web API"],
|
||||
"technologies": [ "Functions 2.x" ],
|
||||
"solutionareas": [ "Web API" ],
|
||||
"author": "simonaco",
|
||||
"authortype": "Community"
|
||||
},
|
||||
|
@ -826,8 +797,8 @@
|
|||
"repository": "https://github.com/fashaikh/functions-msi-csharp",
|
||||
"description": "Once installed it creates a Function App linked to an MSI. If you go ahead and change the access of the MSI to particular resources, then it is able to talk to ARM and return the results",
|
||||
"language": "C#",
|
||||
"technologies": ["Functions 2.x", "Azure Active Directory"],
|
||||
"solutionareas": ["Authentication"],
|
||||
"technologies": [ "Functions 2.x", "Azure Active Directory" ],
|
||||
"solutionareas": [ "Authentication" ],
|
||||
"author": "fashaikh",
|
||||
"authortype": "Community"
|
||||
},
|
||||
|
@ -839,18 +810,8 @@
|
|||
"repository": "https://github.com/fashaikh/functions-aws-s3-cosmosdb-v1",
|
||||
"description": "V1 FunctionApp with AWS S3 bucket and queue bindings,Cognitive Services and CosmosDB: 1)TimerTriggerFromS3: OCR images from S3 2) GetS3PreSignedUrl: Creates a pre signed Url for any S3 bucket 3) BlobTriggerToS3:From Azure Storage to S3",
|
||||
"language": "C#",
|
||||
"technologies": [
|
||||
"Functions 1.x",
|
||||
"Cosmos DB",
|
||||
"Cognitive Services",
|
||||
"Storage Queue"
|
||||
],
|
||||
"solutionareas": [
|
||||
"Scheduled Jobs",
|
||||
"Web API",
|
||||
"Data Processing",
|
||||
"Machine Learning"
|
||||
],
|
||||
"technologies": [ "Functions 1.x", "Cosmos DB", "Cognitive Services", "Storage Queue" ],
|
||||
"solutionareas": [ "Scheduled Jobs", "Web API", "Data Processing", "Machine Learning" ],
|
||||
"author": "fashaikh",
|
||||
"authortype": "Community"
|
||||
},
|
||||
|
@ -861,8 +822,8 @@
|
|||
"repository": "https://github.com/priyaananthasankar/messaging-pattern",
|
||||
"description": "This sample shows how to deploy a blob storage that subscribes to an event grid which sends messages to an Azure Function through a WebHook Trigger. This is a commonly used messaging pattern for many customers.",
|
||||
"language": "Python",
|
||||
"technologies": ["Functions 2.x", "Blob Storage", "Event Grid"],
|
||||
"solutionareas": ["Data Processing", "Event Processing"],
|
||||
"technologies": [ "Functions 2.x", "Blob Storage", "Event Grid" ],
|
||||
"solutionareas": [ "Data Processing", "Event Processing" ],
|
||||
"author": "priyaananthasankar",
|
||||
"authortype": "Community"
|
||||
},
|
||||
|
@ -873,8 +834,8 @@
|
|||
"repository": "https://github.com/gbowerman/twitter-code/tree/master/azurefunctions/dailyreport",
|
||||
"description": "Python function designed to run a daily Twitter search and send output to a Microsoft Teams channel",
|
||||
"language": "Python",
|
||||
"technologies": ["Functions 2.x"],
|
||||
"solutionareas": ["Scheduled Jobs"],
|
||||
"technologies": [ "Functions 2.x" ],
|
||||
"solutionareas": [ "Scheduled Jobs" ],
|
||||
"author": "gbowerman",
|
||||
"authortype": "Community"
|
||||
},
|
||||
|
@ -885,8 +846,8 @@
|
|||
"repository": "https://github.com/ankitkumarr/image-game-sample",
|
||||
"description": "An image game sample that shows how to decode/encode images to JSON and to perform image transformation on them.",
|
||||
"language": "Python",
|
||||
"technologies": ["Functions 2.x", "Blob Storage", "App Service"],
|
||||
"solutionareas": ["Web API", "Gaming", "Data Processing"],
|
||||
"technologies": [ "Functions 2.x", "Blob Storage", "App Service" ],
|
||||
"solutionareas": [ "Web API", "Gaming", "Data Processing" ],
|
||||
"author": "ankitkumarr",
|
||||
"authortype": "Community"
|
||||
},
|
||||
|
@ -898,8 +859,8 @@
|
|||
"repository": "https://github.com/LinaSerry/AlexaSkill_AzureFunction",
|
||||
"description": "Azure function which allows you to interact with your QnA azure bot using Alexa",
|
||||
"language": "C#",
|
||||
"technologies": ["Functions 2.x"],
|
||||
"solutionareas": ["Integration"],
|
||||
"technologies": [ "Functions 2.x" ],
|
||||
"solutionareas": [ "Integration" ],
|
||||
"author": "LinaSerry",
|
||||
"authortype": "Community"
|
||||
},
|
||||
|
@ -911,8 +872,8 @@
|
|||
"repository": "https://github.com/StratusOn/MSI-GetToken-FunctionApp",
|
||||
"description": "An Azure Function App to help get tokens from a Managed Service Identity (MSI) service configured on the Function App.",
|
||||
"language": "C# Script",
|
||||
"technologies": ["Functions 1.x", "Azure Active Directory"],
|
||||
"solutionareas": ["Authentication"],
|
||||
"technologies": [ "Functions 1.x", "Azure Active Directory" ],
|
||||
"solutionareas": [ "Authentication" ],
|
||||
"author": "raouche",
|
||||
"authortype": "Community"
|
||||
},
|
||||
|
@ -924,8 +885,8 @@
|
|||
"repository": "https://github.com/StratusOn/Media-Transport-to-UNC",
|
||||
"description": "Transports media files from a watched Azure Storage account to an Azure Files UNC file share.",
|
||||
"language": "C#",
|
||||
"technologies": ["Functions 1.x", "Blob Storage"],
|
||||
"solutionareas": ["Data Processing"],
|
||||
"technologies": [ "Functions 1.x", "Blob Storage" ],
|
||||
"solutionareas": [ "Data Processing" ],
|
||||
"author": "raouche",
|
||||
"authortype": "Community"
|
||||
},
|
||||
|
@ -936,8 +897,8 @@
|
|||
"repository": "https://github.com/asavaritayal/azure-resource-management",
|
||||
"description": "Python Function App to automate resource cleanup in Azure.",
|
||||
"language": "Python",
|
||||
"technologies": ["Functions 2.x"],
|
||||
"solutionareas": ["Automation", "Authentication"],
|
||||
"technologies": [ "Functions 2.x" ],
|
||||
"solutionareas": [ "Automation", "Authentication" ],
|
||||
"author": "asavaritayal",
|
||||
"authortype": "Community"
|
||||
},
|
||||
|
@ -948,8 +909,8 @@
|
|||
"repository": "https://github.com/asavaritayal/dog-classification",
|
||||
"description": "Azure Function written in Python that predicts the dog breed based on an Image URL.",
|
||||
"language": "Python",
|
||||
"technologies": ["Functions 2.x"],
|
||||
"solutionareas": ["Machine Learning", "Web API"],
|
||||
"technologies": [ "Functions 2.x" ],
|
||||
"solutionareas": [ "Machine Learning", "Web API" ],
|
||||
"author": "asavaritayal",
|
||||
"authortype": "Community"
|
||||
},
|
||||
|
@ -961,8 +922,8 @@
|
|||
"repository": "https://github.com/simonaco/tweetverse",
|
||||
"description": "Tweetverse: scan twitter, analyze sentiment and post sentiment in Slack channel",
|
||||
"language": "JavaScript",
|
||||
"technologies": ["Functions 2.x"],
|
||||
"solutionareas": ["Machine Learning"],
|
||||
"technologies": [ "Functions 2.x" ],
|
||||
"solutionareas": [ "Machine Learning" ],
|
||||
"author": "simonaco",
|
||||
"authortype": "Community"
|
||||
},
|
||||
|
@ -974,8 +935,8 @@
|
|||
"repository": "https://github.com/simonaco/redditifier",
|
||||
"description": "Http endpoint that submits links to the Reddit API",
|
||||
"language": "JavaScript",
|
||||
"technologies": ["Functions 2.x"],
|
||||
"solutionareas": ["Web API"],
|
||||
"technologies": [ "Functions 2.x" ],
|
||||
"solutionareas": [ "Web API" ],
|
||||
"author": "simonaco",
|
||||
"authortype": "Community"
|
||||
},
|
||||
|
@ -987,9 +948,9 @@
|
|||
"repository": "https://github.com/eamonoreilly/StartStopPowerShellFunction",
|
||||
"description": "Start / Stop virtual machines in the specified resource group, subscription, or by tag on a schedule. You need to assign the managed identity of the function app access to the VMs so that the Function can start or stop the VMs when the timer trigger fires.",
|
||||
"language": "PowerShell",
|
||||
"technologies": ["Functions 2.x"],
|
||||
"solutionareas": ["Automation"],
|
||||
"technologies": [ "Functions 2.x" ],
|
||||
"solutionareas": [ "Automation" ],
|
||||
"author": "eamonoreilly",
|
||||
"authortype": "Community"
|
||||
}
|
||||
]
|
||||
]
|
|
@ -1,11 +1,13 @@
|
|||
<Project Sdk="Microsoft.NET.Sdk">
|
||||
<PropertyGroup>
|
||||
<TargetFramework>netstandard2.0</TargetFramework>
|
||||
<AzureFunctionsVersion>v2</AzureFunctionsVersion>
|
||||
<TargetFramework>netcoreapp3.1</TargetFramework>
|
||||
<AzureFunctionsVersion>v3</AzureFunctionsVersion>
|
||||
</PropertyGroup>
|
||||
<ItemGroup>
|
||||
<PackageReference Include="Microsoft.Azure.WebJobs.Extensions.Storage" Version="3.0.1" />
|
||||
<PackageReference Include="Microsoft.NET.Sdk.Functions" Version="1.0.24" />
|
||||
<PackageReference Include="Microsoft.Azure.WebJobs.Extensions.Storage" Version="5.0.1" />
|
||||
<PackageReference Include="Microsoft.Azure.WebJobs.Extensions.Tables" Version="1.0.0" />
|
||||
<PackageReference Include="Microsoft.NET.Sdk.Functions" Version="3.1.1" />
|
||||
<PackageReference Include="Newtonsoft.Json" Version="13.0.1" />
|
||||
</ItemGroup>
|
||||
<ItemGroup>
|
||||
<None Update="host.json">
|
||||
|
|
|
@ -1,5 +1,6 @@
|
|||
using System;
|
||||
using System.Collections.Generic;
|
||||
using System.Threading.Tasks;
|
||||
using Microsoft.Azure.WebJobs;
|
||||
using Microsoft.Extensions.Logging;
|
||||
using Microsoft.WindowsAzure.Storage;
|
||||
|
@ -15,7 +16,7 @@ namespace ServerlessLibraryFunctionApp
|
|||
|
||||
[FunctionName("UpdateCounts")]
|
||||
[Singleton]
|
||||
public static async void Run([QueueTrigger("slitemstats")]string myQueueItemJson, [Table("slitemstats")] CloudTable table, ILogger log)
|
||||
public static async Task Run([QueueTrigger("slitemstats")]string myQueueItemJson, [Table("slitemstats")] CloudTable table, ILogger log)
|
||||
{
|
||||
var payload = JsonConvert.DeserializeObject(((dynamic)myQueueItemJson));
|
||||
string id = payload.id.ToString();
|
||||
|
|
Загрузка…
Ссылка в новой задаче