具有利用约束的数据库 [英] Databases with utilization constraints

查看:141
本文介绍了具有利用约束的数据库的处理方法,对大家解决问题具有一定的参考价值,需要的朋友们下面随着小编来一起学习吧!

问题描述

我有一个基于网络的应用程序,允许用户使用简化的脚本语言和GUI创建自己的复杂查询。问题是 - 有时我的用户很好,不那么明亮。通常,他们将创建一个执行大量连接的查询,或者对大型数据集采用无意义的比较,从而快速消耗机器上的大部分可用资源。实际上,少数民众破坏了其他人的聚会。培训或禁止这些特殊用户不是一个选择。



这里是我的问题:有任何数据库(NoSQL或SQL,或真的)每个查询的限制?



限制CPU利用率将是最小的,但是其他约束,如执行时间,内存使用和行返回的限制也将是很好的。



编辑:对于开源和/或开源的额外点数,或自由产品。



EDIT2 :找到一些相关问题,清楚表明Oracle支持某种资源限制方案,但有什么其他产品吗?只是Oracle和SQL Server?



http://serverfault.com/questions/124158/throttle-or-limit-resources-used-by-a-user-in-a-database
http://stackoverflow.com/questions/2418581/is-there-a-way-to-throttle-or-limit-resources-used-by-a-user-in-oracle

解决方案

SQL Server 2008支持资源调控器:


资源调控器是SQL Server 2008中的一种新技术
,通过为传入的
请求指定对
资源消耗的限制,使您能够
管理SQL Server工作负载和
资源。在资源调控器
上下文中,工作负载是一组
类似大小的查询或请求
,可以,应该被视为
单个实体。这不是
需求,但是工作负载

资源使用模式越统一,您可能从资源调控器获得更多的好处。
资源限制可以在
实时重新配置,对正在执行的
工作负载的影响最小。



资源调控器提供: p>


  • 对传入连接进行分类并将工作负载
    路由到特定组的功能。


  • 能够监控组中每个工作负载的资源使用情况。


  • 对CPU使用率的具体限制
    和内存分配。这可以防止
    或最小化
    run-away查询的概率。


  • 将分组的工作负载与特定池
    资源。


  • 能够识别和设置工作负载的优先级。



参考


I have a web-based application that allows users to create their own complicated queries using a simplified scripting language and GUI. Problem is - sometimes my users are well, not so bright. Often, they'll create a query that does massive joins, or employs pointless comparisons over large datasets that quickly consumes most of the available resources on the machine. In effect, a small amount of folks are ruining the party for everyone else. Training or banning these "special" users isn't an option.

So here's my question: Are there any databases (NoSQL or SQL, or anything really) that support resource constraints on a per query basis?

Limiting CPU utilization would be bare minimum, but other constraints like execution time, memory usage and rows-returned limits would be nice too. It'd be especially handy if I could programmatically specify limits so I could target my problem users.

EDIT: Extra points for opensource and/or free products.

EDIT2: Found some related questions, that make it clear that Oracle supports some sort of resource-limiting scheme, but are there any other products that do? Just Oracle and SQL Server?

http://serverfault.com/questions/124158/throttle-or-limit-resources-used-by-a-user-in-a-database http://stackoverflow.com/questions/2418581/is-there-a-way-to-throttle-or-limit-resources-used-by-a-user-in-oracle

解决方案

SQL Server 2008 supports a resource governor:

Resource Governor is a new technology in SQL Server 2008 that enables you to manage SQL Server workload and resources by specifying limits on resource consumption by incoming requests. In the Resource Governor context, workload is a set of similarly sized queries or requests that can, and should be, treated as a single entity. This is not a requirement, but the more uniform the resource usage pattern of a workload is, the more benefit you are likely to derive from Resource Governor. Resource limits can be reconfigured in real time with minimal impact on workloads that are executing.

Resource Governor provides:

  • The ability to classify incoming connections and route their workloads to a specific group.

  • The ability to monitor resource usage for each workload in a group.

  • The ability to pool resources and set pool-specific limits on CPU usage and memory allocation. This prevents or minimizes the probability of run-away queries.

  • The ability to associate grouped workloads with a specific pool of resources.

  • The ability to identify and set priorities for workloads.

Ref.

这篇关于具有利用约束的数据库的文章就介绍到这了,希望我们推荐的答案对大家有所帮助,也希望大家多多支持IT屋!

查看全文
登录 关闭
扫码关注1秒登录
发送“验证码”获取 | 15天全站免登陆