Package gorilla/mux implements a request router and dispatcher for matching incoming requests to their respective handler.
Questions tagged [mux]
331 questions
0
votes
1 answer
Handling many GET requests at once in go
I'm writing this API which is a backend for slack bot application which will be used by many users. In one of the API endpoints in my api I'm calling an external API to get some data so I can massage it in my API to send it to the BOT/User. But that…

Niraj Fonseka
- 41
- 2
- 5
0
votes
1 answer
Golang mux router handler function arguments
I was trying to set up a CRUD http API using gorilla-mux library.
I followed a youtube tutorial
Implementation is below: -
package main
import (
"github.com/gorilla/mux"
"net/http"
"log"
)
type Book struct {
Id string …

ArunKolhapur
- 5,805
- 4
- 18
- 31
0
votes
1 answer
How to ignore a word and match all other words when using gorilla mux router?
For example, I have a func that handles "/items/{item-id}" and another func that handles "/items/request-task". How to make the first func ignores "/items/request-task" and match the rest?
user2675516
0
votes
1 answer
How to set pts and dts of AVPacket from RTP timestamps while muxing VP8 RTP stream to webm using ffmpeg libavformat?
I am using ffmpeg libavformat library to write a video only webm file. I recieve VP8 encoded rtp stream on my server. I have successfully grouped the rtp byte stream (from rtp payload) into individual frames, and constructed a AVPacket. I am NOT…

user2595786
- 1
- 1
- 4
0
votes
1 answer
Pipeline muxes in hdl
I am doing some simple tests to evaluate how clock speed increases in a digital circuit when pipelining.
I pipeline an 10to1 mux using 2 5to1 and 1 2to1. I get some clock speed increase from the fpga synthesizer (altera). Then I add one more stage,…

Hdllrn
- 1
0
votes
1 answer
Output in http a .mp4 file, issue pulling from database to browser
answered
I am having a hard time with Mongodb and Gridfs, using it with Go's http package. I am trying to store a .mp4 file into Gridfs, then pull it out into the browser for playback.
Heres what I am doing now. It successfully pulls the file from
…

ABC
- 2,068
- 1
- 10
- 21
0
votes
1 answer
Connection width does not match width of port
I have a problem! My code its doesn't working and I dont why. help me please. I try make a carry skip adder nbits and a error occured.
this is my the error :
Warning: C:/Users/Gerson/Desktop/cska1/cska1.v(102): Connection width does not match…

Gerson Dantas
- 3
- 2
0
votes
1 answer
VHDL : mux output not following inputs when it comes to clock signals
I'm creating an architecture to drive a stepper motor using an FPGA board with a L297 controller. So in order to change the speed i created a clock divider to change the clock frequency taken by the L297. The clock divider works just fine. My…

Med Khalil
- 1
- 1
0
votes
1 answer
Subroutes middlewares with Gorilla MUX and Negroni
I'm trying to add a middleware only on some routes. I wrote this code:
func main() {
router := mux.NewRouter().StrictSlash(false)
admin_subrouter := router.PathPrefix("/admin").Subrouter()
//handlers.CombinedLoggingHandler comes from…

Matias
- 575
- 5
- 17
0
votes
0 answers
Gorilla mux Handle any pattern with exception to static FileServer
I try to Handle any pattern another than "/app/*" to FileServer Handler. I use mux router to handle "/app/*" urls, and than I need to handle any others urls to static FileServer.This is my code:
r := mux.NewRouter()
r.Handle("/app/deleteComment",…

K4liber
- 785
- 1
- 8
- 17
0
votes
1 answer
404 Error while using gorilla/mux golang library
I am fairly new to golang and am finding myself frustrated with a simple file service program. I am suspecting that there is something wrong with my file prefix/ directory in the handler for my router r. I have tried many different formats for the…

Clarko
- 103
- 5
0
votes
1 answer
Unable to protect gorilla/mux Subroute with basic auth
I am trying to create routes using gorilla/mux, some of which should be protected by basic auth and others shouldn't. Specifically, every route under /v2 should require basic auth, but the routes under /health should be publicly accessible.
As you…

Gurjeet Singh
- 2,635
- 2
- 27
- 22
0
votes
1 answer
Gorilla mux http package
I'm using Gorilla mux as my router and dispatcher in my golang apps and I have a -I think- simple question:
In my main, I create a router: r := mux.NewRouter(). A few lines further, I register a handler: r.HandleFunc("/", doSomething).
So far so…

Rogier Lommers
- 2,263
- 3
- 24
- 38
0
votes
1 answer
Logic Gates - Dmux (nand2tetris)
I'm just started to take the nand2tetris course ! In the first project, it's demanded to build logic gates with "Nand" starting with "Not". Well, it was easy at the beginning, building or, and, xor. But then came "Multiplexor". It took me a while…

log101
- 17
- 7
0
votes
3 answers
ffmpeg - mux video and audio and trim the audio
I have a long audio part
and a short video part which I want to mux together.
I'm trying the following command to mux:
Video_0-0002.h264 - whole file (2 secs long)
Audio.wav - from 4 till 6 seconds
ffmpeg -y -i…

Anna Shmushkin
- 11
- 1
- 4