I've posted the following to setup defaults for the keys I thought should be optional: https://camlistore-review.googlesource.com/#/c/9206/
On Sunday, January 22, 2017 at 9:32:50 AM UTC-8, Steve Armstrong wrote: > > I'm trying to get the scanningcabinet working ( > https://camlistore-review.googlesource.com/#/c/5416/). I've rebased it up > on ToT and it seems to be functional, but I'm having a lot of confusion > with the app interface with camlistore. > > I added the following to my config: > > "/scancab/": { > "handler": "app", > "enabled": true, > "handlerArgs": { > "prefix": "/scancab/", > "program": "scanningcabinet", > "listen": "127.0.0.1:2055", > "backendURL": "http://127.0.0.1:2055/" > } > }, > > I'd like to drop as much redundant info as possible. Why is "prefix" > required twice? Can we plumb through the "/scancab/" key down into the > handler's constructor so it has it as a default? This key seems to be how > scannincabinet would call back to Camlistore. Shouldn't that not be > configurable and just be a randomly generated URL that's passed into > scanningcabinet when it's run (like the auth is)? > > Also, "listen" or "serverListed" are required. Can't we just default to a > random port added to Camlistore's ip if neither one is specified? > > "backendURL" or "serverBaseURL" is also required. Shouldn't it just > default to whatever "listen" defaults to? > > Finally, when I go to http://localhost:3179/scancab/test it routes to > http://localhost:2055/scancab/test. I'd expect it to trim off the > "/scancab/" prefix and route to http://localhost:2055/test. > > I'm probably missing the goal of how this contract is supposed to work, > and which knobs are intended to be configurable. Could someone help me out, > as I don't want to submit a pull request that removes/changes a bunch of > these keys and behaviours if they were intended. > > Thanks > -- You received this message because you are subscribed to the Google Groups "Camlistore" group. To unsubscribe from this group and stop receiving emails from it, send an email to [email protected]. For more options, visit https://groups.google.com/d/optout.
