@@ -8,38 +8,49 @@ function model::greet(name: String[1]): String[1]
88function model::processData(data: String[1]): String[1]
99{
1010  'Processed data: ' + $data
11- }###HostedService
11+ }
12+ 
13+ ###HostedService
1214// Basic hosted service with UserList ownership
1315HostedService model::BasicHostedService
1416{
15-    pattern : '/api/greet/{name}';
16-    ownership : UserList { users: [
17-     'user1',
18-     'user2'
19-     ] };
20-    function : model::greet(String[1]):String[1];
21-    documentation : 'A simple hosted service that greets users by name';
22-    autoActivateUpdates : true;
17+    pattern: '/api/greet/{name}';
18+    ownership: UserList 
19+    {
20+       users: [
21+          'user1',
22+          'user2'
23+       ]
24+    };
25+    function: model::greet(String[1]):String[1];
26+    documentation: 'A simple hosted service that greets users by name';
27+    autoActivateUpdates: true;
2328}
2429
2530// Hosted service with Deployment ownership and stereotypes
2631HostedService <<meta::pure::profiles::doc.doc>> {doc.doc = 'Example with deployment ownership'} model::DeploymentHostedService
2732{
28-    pattern : '/api/process/{data}';
29-    ownership : Deployment { identifier: '12345' };
30-    function : model::processData(String[1]):String[1];
31-    documentation : 'A hosted service that processes data with deployment ownership';
32-    autoActivateUpdates : false;
33+    pattern: '/api/process/{data}';
34+    ownership: Deployment 
35+    {
36+       identifier: '12345'
37+    };
38+    function: model::processData(String[1]):String[1];
39+    documentation: 'A hosted service that processes data with deployment ownership';
40+    autoActivateUpdates: false;
3341}
3442
3543// Hosted service with post-deployment actions
3644HostedService model::AdvancedHostedService
3745{
38-    pattern : '/api/advanced/{param}';
39-    ownership : UserList { users: [
40-     'admin'
41-     ] };
42-    function : model::processData(String[1]):String[1];
43-    documentation : 'Advanced hosted service with post-deployment actions';
44-    autoActivateUpdates : true;
46+    pattern: '/api/advanced/{param}';
47+    ownership: UserList 
48+    {
49+       users: [
50+          'admin'
51+       ]
52+    };
53+    function: model::processData(String[1]):String[1];
54+    documentation: 'Advanced hosted service with post-deployment actions';
55+    autoActivateUpdates: true;
4556}
0 commit comments