Page 60 - MSDN Magazine, July 2017
P. 60
Figure 9 Example of @Input Decorator
database industry. DocumentDB provides these guarantees to help alleviate the challenges faced by developers who need to develop low latency, distributed, highly available applications.
Even though it may not be related to the application you’ve built, it’s good to know that DocumentDB provides four consistency levels: Strong: This is an RDBMS-like consistency. With every request, the client is always guaranteed to read the latest acknowledge write. However, this is slow and in order to use this, the DocumentDB
account cannot be associated with more than one region.
DocumentDB provides rich and familiar SQL query capabilities with consistent low latencies on JSON data, ensuring that 99 percent of your reads are served in less than 10 ms and 99 percent of your writes are served
in less than 15 ms.
Bounded staleness: This level guarantees that the reads may lag behind by at most x versions of the document or a certain time interval by the client. So, if the client sets x=2, the user will be guar- anteed to get a document no later than the last two versions. This functions the same with time. If the time is set to five seconds, every five seconds the resource will be guaranteed to have been
@Component({
template: '<product-info [productDetails]="product"></product-info>'
})
export class ProductsComponent { product: Product = new Product("Computer ABC"); }
@Component({
selector: 'product-info', template: `
<div class='row'>
<div class="col-md-12 form-group">
<label>Product Name:</label>
<span class="form-control-static">{{productDetails.name}}</span> </div>
</div> `
})
export class ProductComponent { @Input() productDetails: Product; }
DocumentDB
DocumentDB is a fully managed NoSQL database service built for fast and predictable performance, high availability, elastic scaling, global distribution and ease of development. As a schema-free NoSQL database, DocumentDB provides rich and familiar SQL query capabilities with consistent low latencies on JSON data, ensuring that 99 percent of your reads are served in less than 10 ms and 99 percent of your writes are served in less than 15 ms.
DocumentDB transparently replicates your data to all regions you’ve associated with your DocumentDB account, enabling you to develop applications that require global access to data while providing tradeoffs between consistency, availability and perfor- mance, all with corresponding guarantees. DocumentDB provides transparent regional failover with multi-homing APIs, and the ability to elastically scale throughput and storage across the globe.
The core promise of DocumentDB is its service-level agreements (SLAs), which are highly rated in the industry for throughput, latency, availability and consistency. This is a unique offering in the
Term
Postings
$/locations/0/
1, 2
locations/0/country/
1, 2
locations/0/city/
1, 2
0/country/Germany
1, 2
1/country/France
1
{1,2} locations
{1,2} revenue
{2} 200
{1,2}
{1,2} headquarters
{1} Belgium
{1,2} country
{1,2} exports
...
...
{1,2} 1
{2} dealers
{2} 0
{2} name
{2} Hans
...
...
{1,2} city
{2} Athens
ASP.NET Core
0/city/Moscow
1
0/dealers/0
2
Index Entry
{1,2} country
{1,2} 0
{1,2} city
{1} 1
{2} Italy
{1,2} city
{1,2} 0
{1,2} city
{1,2} Germany {1} Berlin {2} Bonn
{1} France {1} Paris
{1} Moscow
{2} Berlin
Figure 10 Representation of the Index for JSON Documents 54 msdn magazine