Questions tagged [requestcontext]

93 questions
0
votes
0 answers

how to i access the request.user nestjs microservice?

I have a microservice setup with an api gateway accepting http requests and passing them to miscroservices (media-service, payment-service, etc.) using message pattern. I can access the request.user in the api-gateway which gives me the…
mushfau
  • 63
  • 3
  • 5
0
votes
1 answer

Module "django.template.context_processors" does not define a "custom_proc" attribute/class

def custom_proc(request): "A context processor that provides 'app', 'user' and 'ip_address'." return { 'app': 'My app', 'user': request.user, 'ip_address': request.META['REMOTE_ADDR'] } above code is my code. a request Context. i write…
mana
  • 1
  • 1
0
votes
1 answer

Access request context in async code of vertx without passing it to each function

I am developing an application in Vertx. I am attaching uniqueRequestId to each request and adds it to the requestContext object, so that while printing any logs I will associate uniqueRequestId to each log message and I will be able to better trace…
Vaibhav Raut
  • 472
  • 3
  • 12
0
votes
1 answer

Accessing StreamListener headers from RequestContext or similar

I have a service which calls a dozen other services. This reads from a Kafka topic using a @StreamListener in a controller class. For traceability purposes, the same headers(original request ID) from the Kafka message need to be forwarded to all the…
0
votes
0 answers

Cefsharp : problem with the Reqest Context of the General Usage page

I have some problems, to change user profile with cefsharp 71.0.2. All is working good with an user1. To change users, the General Usage Wiki page gives me the solution. But the 3rd line of this code var requestContextSettings = new…
0
votes
1 answer

Obtaining a RequestContext for a templatetag included on every page

I have a templatetag which generates a form, this therefore requires the {% csrf_token %} for security, which in turn requires a RequestContext object instead of the standard Context object. Now, the particular templatetag/form in question is…
Nick
  • 87
  • 1
  • 6
0
votes
1 answer

Django - Passing a filtered result to a template

Inside of my Django view I am trying to retrieve results from my database and then pass them on to my template with the following code: f = request.GET.get('f') try: fb_friends_found=…
Leon
  • 1
0
votes
2 answers

RequestContext returns 404 error for my imagaes?

I stumbled on a silly situation with Django's RequestContext thing. Here is my question: I stored all my images in my media/uploads file. In my template I'm simply using : {% for photo in photos %}
iva123
  • 3,395
  • 10
  • 47
  • 68
0
votes
1 answer

Which is the better way to access pageflowscope variable in ADF

As we know there are multiple ways to access the page flow scope variable but which one is the right one? ex RequestContext.getCurrentInstance().getPageFlowScope(); AdfContext.getCurrent.getPageFlowScope(); FacesContext? I am also curios to know…
gavityBox
  • 1
  • 2
0
votes
0 answers

Primefaces Dialog Framework: RequestContext.execute - Javascript called twice

I'd like to call a javascript from bean of a dialog window, but it is executed twice! I use the RequestContext.getCurrentInstance().execute() method. This method works perfectly if the page is not "Dialog Framework", but in external page dialog…
Linkman
  • 171
  • 1
  • 7
0
votes
2 answers

WildFly 10 | Undertow | Create Wildfly LoginModule with access to RequestContext

i'm trying to create a login module for wildfly 10 with access to the request context. I must identify the request url. Also I have to analyse the GET parameters to check if a token is set. How can I access to the request context and url…
Net_Hans
  • 115
  • 12
0
votes
0 answers

Mock OperationContext.Current.RequestContext in WCF Service Unit Test

Can anyone advise on how to go about Mocking the 'RequestContext' in a WCF service. I'm currently working on a legacy WCF service that relies heavily upon headers being set in the request context. Below I have a factory that I'd like to test, but…
HelloAmigo
  • 55
  • 6
0
votes
1 answer

Django: Certain aspects of context not passing properly in live environment vs. local

I'm having a strange issue where certain values in a context from my views are not passing to the template in a production environment only. Take the following view: def products(request,cat_id=0): if cat_id: cat =…
0
votes
0 answers

Spring mvc request scope context across threads

In a spring MVC web application, I wanna store user information at the request scope, in the filer or interceptor I will build the user information and store it and use it later within this request.I know in spring I can create request scope spring…
0
votes
1 answer

RequestContext.getCurrentInstance().update doesn't work

I have a JSF page with commandbutton to show dialog and show data from datatable, but the problem RequestContext.getCurrentInstance().update doesn't update the dialog, can anyone tell me what is wrong with my code? here is my JSF code
san san
  • 53
  • 1
  • 1
  • 4