11. WEB APPS
• .NET, Node.js, Java, PHP, and Python
• Webjobs – 웹앱에서 VM에서 프로그램이나
스크립트를 실행
• VS publish, remote debug 통합
• GitHub, BitBucket, VSO를 이용한 협업
• 자동크기조정 – 신속하게 규모 축소 및 확장
• 스태이징 된 배포를 통한 릴리즈 전 코드 검증
웹, 모바일 및
통합 시나리오에 적합
Web Apps
12. • 네이티브 및 크로스 플랫폼 앱 빌드
• Single Sign On(SSO) – Facebook, Twitter,
Microsoft, Google 계정 연동
• iOS, Android, Windows에 몇 초 내 수백만명에
푸시 알림 전송
• 오프라인 동기화 – SQL, Table Storage, Mongo
DB 등과 오프라인 동기화
• 자동크기조정 – 신속하게 규모 축소 및 확장
전세계에서 사용가능한
모바일 앱 개발 플랫폼
MOBILE APPS
Mobile Apps
13. • 코드 작성 없이 디자인 도구로 빠르게 작성
• 기존에 만들어진 수많은 템플릿 이용
• 워크플로를 쉽게 디자인
• 커스텀 API 사용
• Biztalk API를 보다 쉽게 이용
비즈니스 프로세스
자동화
LOGIC APPS
Logic Apps
14. • SaaS 플랫폼에 쉽게 연결
• API 생태계
• 커스텀 API를 발행할 수 있고 다시 사용 가능
• 논리 앱과 통합
• C#, Java 및 Javascript 등의 다양한 API를
이용한 개발
API 생성 및 사용을
더욱 편하게
API APPS
API Apps
19. 뭐가 필요한데?
계정,
Cloud Server
Cross Platform
• 사용자 정보 체계적 관리 및
분석 처리
• 사용자 기기간 데이터 동기화
• 이용자간 채팅, 자료 공유 등
소셜 서비스
• 외부 계정과 연동 서비스
• Etc
• 윈도우 10, iOS, 안드로이드
등 모든 모바일 플랫폼에 대응
할 수 있는 체계
• 여러 디바이스들에 쉽게 연결
될 수 있는 체계
좋은 서비스
• 좋은 기술들로 퍼져나갈 좋은
서비스
• 서비스의 변화에 대응할 수 있
는 체계
• 기술이 좋아도 서비스가 안 좋
으면 무의미
26. Core + Service Core
Core
[PCL]
Service
Core
[Web App] Storage
Document db
Azure Storage
SQL
Notification
Notification Hub
Data Analysis
Application Insight
Machine Learning
Rest API
HTTP
Business
Logic
Account
서비스 계정 관리
동기화
Web Job
<CODE />
유저 입력
처리
Service Core와의
연결
33. Web App와 Client 사이
User
EventEditView
EventViewModel
(UI Logic)
DB
HTTP
Event
Controller
Logic
for Event
Local DB
Client Web App
Event 데이터 처리 예시
34. 데이터 모델 추가될 때
Entity
Entity
Entity
Contract
Event
EventEditView
EventViewModel
Event Controller
Local DB 처리
Azure DB 처리
….
Event 서버 데이터 처리
데이터 모델 하나 추가 될 때 일일히 해야 되는 것들
35. Generics
class Test<T> where T : class
{
T _value;
public Test(T t)
{
this._value = t;
}
public void Write()
{
Console.WriteLine(this._value);
}
}
<T>
- 코드 재사용, 형식 안정성 및 성능 최대화
- 고유한 제네릭 인터페이스 클래스, 메서드
및 Delegate 생성 가능
- 특정 데이터 형식의 메서드에만 액세스
하도록 제한 가능
class Program
{
static void Main()
{
Test<int> test1 = new Test<int>(5);
test1.Write();
Test<string> test2 = new Test<string>("cat");
test2.Write();
}
}
36. PCL에서 사용 가능한 Entity
Entity Framework 7
(Azure SQL)
Table Entity
(Azure Table Storage ≥4.4.0.0)
Json
(Azure Document db)
Windows
10
Android
(Xamarin)
iOS
(Xamarin)
Core
[PCL]
Service
Core
[Web App]
37. ViewModel<T>
Generic을 이용한 데이터 처리 컨셉
Insert<T>
Entity T (ICustomEntity)
id
UpdatedTime
CreatedTime
…
Update<T>
Delete<T>
Controller<T>
Reflection으로 T변환 필요
TContoller(Http.Post)
TContoller(Http.Put)
TContoller(Http.Delete)
Storage<T>
Sync 기능 통합 가능
Insert<T>
Update<T>
Delete<T>
Get<T>
Sync<T>
다른 싱크 기능을 가진
컨트롤러에서 사용
38. Controller 처리 예시
BaramTableEntity parseEntity =
JsonConvert.DeserializeObject<BaramTableEntity>(apiRequest.RequestJson);
Type type = Type.GetType($"DesignMe.{parseEntity.TableName}, Core, Version=1.0.0.0,
Culture=neutral, PublicKeyToken=null");
Type genericType = typeof(TableStorageManager<>).MakeGenericType(type);
dynamic storagemanager = Activator.CreateInstance(genericType);
dynamic entity = storagemanager.Parse(apiRequest.RequestJson);
Type apiResultType = typeof(TableApiResult<>).MakeGenericType(type);
dynamic apiResult = Activator.CreateInstance(apiResultType);
entity = await storagemanager.Insert(entity);
public class TableController : ApiController
{
public async Task<IHttpActionResult> Post(TableApiRequest apiRequest)
…
Request에 T 정보를 넣고 컨트롤러에서 리플렉션으로 복원
39. User
View
더 이상 작업이 필요 없어지는 구간
ViewModel<T>
(UI Logic)
DB<T>
HTTP
Controller
<T>
Storage
Manager<T>
Local DB
<T>.db
Client Web App
40. Entity Framework 7
출처 : entityframeworktutorial.net
Azure SQL 뿐만 아니라
Sqlite 에도 사용 가능해
서버와 클라이언트 모두
사용 가능
44. Notification Hubs
NOTIFICATION
HUBS
• .NET, Node.js, Java, PHP, and Python
• Windows, iOS, Android, Android(China) 등 대부
분의 모바일 플랫폼에 알림 전송 가능
• 등록 시 Tag를 입력해 특정 디바이스나 조건에
맞는 곳에 알림을 보냄
• 수 초 내에 수백만개의 알림 전송 가능
• 뉴스, SNS 알림 등의 Toast 알림과 기기 동기화
를 위한 신호를 주는 Raw 알림 등 여러 타입의
알림 전송 가능
수 초 내에
수백만개의 알림 전송
45. Notification Hubs
Push
Notifications
wns apns gcm
// windows
var toast = @"<toast><visual>
<binding template=""ToastText01"">
<text id=""1"">Hello</text></binding></visual></toast>";
await
Notifications.Instance.Hub.SendWindowsNativeNotificationAsync(toast,userTag)
;
// apns
var alert = "{"aps":{"alert":"Hello"}}";
await
Notifications.Instance.Hub.SendAppleNativeNotificationAsync(alert,userTag);
// gcm
var notif = "{ "data" : {"msg":"Hello"}}";
await
Notifications.Instance.Hub.SendGcmNativeNotificationAsync(notif,userTag);
태그
정보
태그
정보
46. Tag : 원하는 기기에 알림 보내기
switch (notificationType)
{
case "wns":
registration = new
WindowsRegistrationDescription(notificationUri);
break;
case "apns":
registration = new AppleRegistrationDescription(notificationUri);
break;
case "gcm":
registration = new GcmRegistrationDescription(notificationUri);
break;
}
registration.RegistrationId = id; //Notifation RegistrationId
registration.Tags = new HashSet<string>();
registration.Tags.Add("id:" + accountId);
registration.Tags.Add("device:" + deviceId); //Tag 정보
await Hub.CreateOrUpdateRegistrationAsync(registration);
Notification 등록 시
Id, device id 등을
등록하여
원하는 그룹 혹은
장치에만 따로 알림
전송 가능