-
Notifications
You must be signed in to change notification settings - Fork 129
Home
(Working 20160225) ##CloudBread Project developer guide In this wiki, we will discuss about CloudBread project install and developer usage guide. This document include below chapters
###Getting Started Guide ####1. Register Azure CloudBread is developing on Microsoft Azure Cloud Platform especially, leveraging PaaS based services. To deploy CloudBread on cloud, register free Microsoft Azure subscription in this link - https://azure.microsoft.com/en-us/free/ There're more free options to use Azure - Visual Studio subscriber, Startup - BizSpark, Academic - DreamSpark.
####2. CloudBread ARM To deploy on Azure, CloudBread is using ARM - Azure Resource Manager, please, visit official CloudBread-ARM project and follow the deploy instructions. For more information about ARM, visit Azure Resource Manager link.
####3. Set up Database After ARM deploy task, you should set up SQL database. This task include creating database objects such as tables, constraints and stored procedures. To set up SQL database, visit official CloudBread-DB-Install-Script project and follow set up SQL database instructions. For more information about Azure SQL Database, visit Azure SQL Database link.
####4. CloudBread deploy from Github To deploy CloudBread project on Azure Mobile App service, we recommend to using Github deploy method.
- 4.1 In Github, Fork latest CloudBread project stable branch to you Github repository.
- 4.2 Logon to Microsoft Azure portal website
- 4.3 Go to your deployed Resource Group, open Mobile App(CloudBread frontend API service)
- 4.4 Go to Settings, Continuous deployment. Click Choose Source, then click Github Repository, and then click OK.
- 4.5 If you're first time to using Azure repository, might need to create repository login credential.
- 4.6 Choose your Github forked CloudBread repository.
- 4.7 It's automatically start deployment task.
For more information, please reference Deploy your app to Azure App Service and Continuous deployment using GIT in Azure App Service
####5. CloudBread configuration - web.config file configuration I CloudBread, all of service specific configuration values are located at web.config with default values. To connect on Azure SQL Database, Azure table storage and Redis cache, you should configure this web.config file. For the development purpose, I recommend to set the connectionString values in web.config. If you're using connectionString setting on Azure app service, the Azure app service will override connectionString values setting in production.
- 5.1 Logon to Microsoft Azure portal website
- 5.2 Choose your Resource Group, Azure SQL Database, Connection strings and copy the ADO.NET connection string.
- 5.3 Paste the connection string to web.config file CloudBreadDBConString section. The code must be looks like this.
<add name="CloudBreadDBConString" connectionString="Server=tcp:yourservername.database.windows.net,1433;Database=yourdatabasename;User ID=yourloginid@yourservername;Password=yourpassword;Encrypt=True;TrustServerCertificate=False;Connection Timeout=30;" providerName="System.Data.SqlClient" />
- 5.4 In the Azure portal, in the Resource Group choose your Storage Account - setting - Access Keys and then copy Connection strings of KEY1.
- 5.5 Paste the storage account connection string to web.config file CloudBreadStorageConString section. The code must be looks like this.
<add name="CloudBreadStorageConString" connectionString="DefaultEndpointsProtocol=https;AccountName=yourstorageaccountname;AccountKey=youraccountkey;BlobEndpoint=https://yourstorageaccountname.blob.core.windows.net/;TableEndpoint=https://yourstorageaccountname.table.core.windows.net/;QueueEndpoint=https://yourstorageaccountname.queue.core.windows.net/;FileEndpoint=https://yourstorageaccountname.file.core.windows.net/" />
- (TODO)5.5 Adding Redis connection string
- 5.7 Download and install Postman app.
- 5.8 Download(or open cloned local repository) Postman collection file from your Github forked CloudBread repository Tools folder. Open the json file in editor and change all *"url": * to your CloudBread mobile app service URL. In Postman app, Import your edited collection file.
- 5.9 In Postman app, execute 00-ping GET request API. The response must be "Hello". To test the database connection, execute CBSelNotices POST request API.
###CloudBread - "Actor Behavior" ####What is Actor Behavior? CloudBread is using Behavior concept to implement game server engine. To build business logic list to implement game server engine, project team generalized game actor's behaviors and made the behaviors list. CloudBread Engine is implementation of these behaviors and easily add/modify behaviors as framework basis. ####CloudBread Behavior list and description To check out, visit the CloudBread behavior list wiki page, please.
###CloudBread API developer usage ####How to call CloudBread API in test or development environment? For the developer test, CloudBread is using Postman app, described this page 5.7 section. If you're already installed somestring-CloudBreadDB-testdata-insert.sql script as part of CloudBread-DB-Install-Script project, you can test on Postman app, right away. ####CloudBread Client developer project In client game development environment, you can maximize with CloudBread official developer test app.
- Unity3D - visit official CloudBread Client Unity and follow installation instructions.
- (TODO)iOS - visit official CloudBread Client iOS and follow installation instructions.
- (TODO)Android - visit official CloudBread Client Android and follow installation instructions.
- (TODO)UWP-Universal Windows Platform - visit official CloudBread Client UWP and follow installation instructions.
###Authentication provider login(Facebook, Twitter, Microsoft ID, Google ID, Azure Active Directory) ####How to set up Authentication provider login? Azure Mobile App is already set up the Authentication provider login environment. By default, you can set Facebook, Twitter, Microsoft ID and Google ID provider for your mobile game and mobile app. ####How to Register mobile game app on Authentication provider? Please, visit this link for Facebook, [Twitter](How to configure your App Service application to use Twitter login), Microsoft ID, Google ID and Azure Active Directory. After you set up the authentication on Azure Web App, all request should use Azure Mobile App Client SDK or call with x-zumo-auth in HTTP Request Header.
- For the developer test, CloudBread is using Postman app.
- To test the Authentication provider enabled API call in Postman, you must generate the x-zumo-auth request header value.
- You can generate this value by yourself.
- To generated the x-zumo-auth key you should use mobile device environment. Because, Azure Mobile App SDK is built for mobile device execution.
- After generated the x-zumo-auth key, replace all x-zumo-auth request header values in Postman collection file on API call dev & testing time.
- If you're using Microsoft Windows 8.x or Windows 10 for development system, visit official CloudBread-Dev-Authkey-Gen-win8.1 and follow installation instructions.
- (TODO)If you're using Mac OS for development system, visit official CloudBread-Dev-Authkey-Gen-Android and follow installation instructions.
For more information, visit Authentication and Authorization in Azure Mobile Apps link, please.
###CloudBread API reference
- Please, visit official API reference page - http://cloudbreadproject.github.io
###Cloud service architecture
- (TODO)Azure Cloud Service
###Database design
- Please, visit CloudBread database design page. - CloudBread database design
###CloudBread Socket - "Real-time Communication" ####What is CloudBread Socket project This project is designed for CloudBread mobile game & app server engine to implement real-time bidirectional communication.
- CloudBread Socket project Live Demo link This Live Demo is built on React web framework. In client game development environment, you can reference the source code with CloudBread official developer test app.
- Please, visit CloudBread Socket project implementation guide page
###CloudBread Admin website CloudBread is support built-in Admin website to manage your game server data in various way. To deploy CloudBread project on Azure Web App service, we recommend to using Github deploy method. This task is identically same with CloudBread not Azure Mobile App Service but Azure Azure Web App Service.
- In Github, Fork latest CloudBread-Admin-Web project stable branch to you Github repository.
- Logon to Microsoft Azure portal website
- Go to your deployed Resource Group, open Web App(CloudBread Admin website service)
- Go to Settings, Continuous deployment. Click Choose Source, then click Github Repository, and then click OK.
- If you're first time to using Azure repository, might need to create repository login credential.
- Choose your Github forked CloudBread-Admin-Web repository.
- It's automatically start deployment task.
For more information, please reference Deploy your app to Azure App Service and Continuous deployment using GIT in Azure App Service
(TODO)- Admin website usage
(TODO)###CloudBread leader board - Redis
- What is CloudBread leader board
- Default SQL statistics service
- SQL vs Redis leader board
###CloudBread scheduler service
- Azure Webjobs
###Store in-game log at Redis Cache
- (TODO)
###CloudBread system monitoring ####General monitoring
- Monitor service metrics https://azure.microsoft.com/en-us/documentation/articles/insights-how-to-customize-monitoring/
- View events and audit logs https://azure.microsoft.com/en-us/documentation/articles/insights-debugging-with-events/
- Monitor availability and responsiveness of any web site https://azure.microsoft.com/en-us/documentation/articles/app-insights-monitor-web-app-availability/
- Receive alert notifications https://azure.microsoft.com/en-us/documentation/articles/insights-receive-alert-notifications/
####App Service
####SQL Database
- Troubleshoot, diagnose, and prevent SQL connection errors and transient errors for SQL Database
- Monitoring Azure SQL Database using dynamic management views
- TODO
###CloudBread system logging
- (TODO)
###CloudBread service performance scaling CloudBread is built on full PaaS base cloud environment and developed as stateless application. You can easily scale the CloudBread services with below articles.
- Azure App Service: Scaling App Service Applications
- Scale pricing tier in Azure App Service
- Scale instance count manually or automatically
- Azure SQL Database performance guidance for single databases
- Change the service tier and performance level (pricing tier) of a SQL database
- (TODO)Elastic Database with Azure SQL
- Monitor a storage account in the Azure Portal
- Enabling Azure Storage metrics and viewing metrics data
- Monitor, diagnose, and troubleshoot Microsoft Azure Storage
###CloudBread troubleshooting
- (TODO)
- Monitor, diagnose, and troubleshoot Microsoft Azure Storage
- End-to-End Troubleshooting using Azure Storage Metrics and Logging, AzCopy, and Message Analyzer
###Build CloudBread staging environment
###FAQ