Questions tagged [policies]
200 questions
2
votes
1 answer
Asp.Net Core policies is running all requirements even if first ones are not succeeded
I'm creating custom policies for a web api. I assumed that requiring a authenticated user in a policy would prevent other requirements to be ran. I know that adding multiple requirements forces them all the be passed so essentially I see multiple…

Ingó Vals
- 4,788
- 14
- 65
- 113
2
votes
1 answer
Lifecycle policies for GCP Storage bucket
I want to apply some more advanced lifecycle policies on my GCP Storage Bucket to meet some imposed requirements.
An application performs hourly backups which are stored in a GCP Storage Bucket as "app_name_timestamp". I want to optimize the number…

notadevv
- 31
- 5
2
votes
3 answers
Azure APIM sleep or delay policy
is there a sleep policy or any alternative in azure apim so that i can delay for 5 seconds to particular response?enter image description here
In the attached image i need to give 5 seconds of delay or sleep condition to the highlighted condition.

Deepak Jain
- 31
- 5
2
votes
1 answer
Return simple string claim from custom policies in ADB2C
I followed this article where it explains how to implement a custom policy using Active Directory B2C. Everything is working great, the only concern I have is that the custom claim is returned like a serialized object. Let me explain a little bit…

brian enno
- 400
- 5
- 16
2
votes
0 answers
InfluxDB Grafana one graph with different CQs and RPs
We try to create retention policies on our data so we can reduce amount of data we store. The point is to have a graph divided into tree parts where every part would have different CQ and RP as well I think.
So graph in Grafana would show 3rd part…

vloubes
- 183
- 3
- 16
2
votes
3 answers
Kubernetes autoscaling policies not working
I've added some scaling policies to my HorizontalPodAutoscaler but they are not being applied. The scaleUp and scaleDown behaviours are being ignored. I need a way to stop pods scaling up and down every few minutes in response to small CPU spikes.…

Mikhail Janowski
- 4,209
- 7
- 28
- 40
2
votes
1 answer
What is the scope of Postgres policies?
I am trying to wrap my head around row level security in Postgres. Unfortunately the documentation is not very verbose on the matter. My problem is the following:
I have two tables: locations and locations_owners. There is a TRIGGER set on INSERT…

Fohlen
- 192
- 2
- 18
2
votes
0 answers
Why is my laravel policy authorization not working after a while
I'm following the laracasts 5.7 series and I was working on the authorization part using policies. It was working fine when I first added it. But the next day when I opened the app again (without TOUCHING any of the code) I kept being thrown to a…

kyljmn
- 23
- 3
2
votes
1 answer
How to set up Ranger policy for an array struct in hive table
I need to set up a Ranger policy to restrict a user to access certain array structs from a column in HIVE table.
For example, I have a column called 'Spouse' in a Hive table which contains array structs such as spousefirstname, spouselastname,…
user10735897
2
votes
4 answers
Laravel policies always return false
I have created policy, and add method view:
public function view(User $user, Contact $contact)
{
return $user->id === $contact->manager;
}
Then I have registered it:
protected $policies = [
'App\Model' => 'App\Policies\ModelPolicy',
…

domanskyi
- 701
- 1
- 6
- 19
2
votes
2 answers
RabbitMQ queue-master-locator does not work when stoping one node
we are exploring the queue-master-locator 'min-masters' policy, and it looks like it works OK when we create new Queues, but when for some reason we need to stop one node of the cluster, every queues existing on that node get promoted (master) to…

Pablo Pinargote
- 21
- 4
2
votes
0 answers
Laravel Policies VS Roles/Permissions Implementation
I have implemented small test code with Laravel Policies . I am wondering whether this is the right method to implement an roles based permission system. I also used Entrust Role Permission package too. My requirement is as follows :
1. List of…

Kiran Singnet
- 21
- 2
2
votes
1 answer
Apply multiple policies in sails on a route
How to apply multiple policies in sails on routes which are generated by sails like this : /users/:id/orders . I can apply a single policy like this in config/routes.js
'/users/:id/orders' : {
policy : 'isAuthenticated'
}
But how can apply more…

Devendra Verma
- 975
- 2
- 10
- 24
2
votes
3 answers
APIM Policy to convert and incoming GET request to a POST request for my back end service
NOTE: SEE MY OWN ANSWER BELOW
I have been looking through the slim documentation for hours. What I need is this:
I have an incoming GET request from a system that can ONLY send GET requests. My back-end service requires a POST request.
Can someone…

RuSs
- 1,725
- 1
- 29
- 47
2
votes
1 answer
Session is not defined sailsjs
I'm writing a policy checkSession which basically destroy session after some time.
checkSession.js (policies/checksession.js)
var moment = require('moment');
function checkLastActivity(req) {
if (!req.session.lastActivity) {
return…

Ahsan Hussain
- 952
- 4
- 21
- 42