You are viewing a plain text version of this content. The canonical link for it is here.
Posted to user@couchdb.apache.org by Mark Hahn <ma...@hahnca.com> on 2012/11/01 01:41:00 UTC
help with rewrite
I've just started working on a futon replacement called "ftn" (
https://github.com/mark-hahn/ftn). It is a couch app built with kanso. I
need to start my app by referencing a design doc like _design/ftn and then
inside my app make ajax calls to a different db.
Right now I have to start the app with something like
http://domain:5984/ftn/_design/ftn/idx.htm. I obviously would like to use
the vhost and rewrite feature to start the app with something shorter. I
can't figure out how to do this because any ajax call in my app for a
different db would also be sent to my ftn db due to the vhost.
Can someone figure out how I can use a short url instead of
http://domain:5984/ftn/_design/ftn/idx.htm?
P.S. How does futon get away with a URL with just the path _utils? Can I
do this with something like _ftn and have it fire up my couch app?
Re: help with rewrite
Posted by Noah Slater <ns...@apache.org>.
We're a friendly bunch. Lots of diverse interests there. (But yes, lots of
core CouchDB traffic.) Newcomers always welcome!
On 3 November 2012 17:28, Mark Hahn <ma...@hahnca.com> wrote:
> It's actually going faster than I expected. I've never used backbone
> before. The backbone router is doing the parsing of the couch urls all by
> itself.
>
> Maybe by early next week it will actually be useful as a super-curl.
>
> > And pop on over to the dev list!
>
> I've always assumed that list was for developers of couch, not couch apps.
> But I'll take a look.
>
> On Sat, Nov 3, 2012 at 10:00 AM, Noah Slater <ns...@apache.org> wrote:
>
> > Let us know how you get on, Mark! (And pop on over to the dev list!)
> >
> > On 1 November 2012 01:27, Mark Hahn <ma...@hahnca.com> wrote:
> >
> > > It doesn't appear anything has happened yet on the new futon you
> pointed
> > me
> > > to.
> > >
> > > I'm going to go ahead for the normal vain reasons. I want to learn new
> > > tools and I want to have one that works exactly the way I want it to
> > work.
> > > Also i think plowing ahead without waiting for committee consensus
> would
> > > be good (excuse my arrogance).
> > >
> > > Thanks for the links to the magic pixie dust. I hope it doesn't
> require
> > > erlang. If it does I can use the long url for now.
> > >
> > > On Wed, Oct 31, 2012 at 6:17 PM, Dave Cottlehuber <dc...@jsonified.com>
> > > wrote:
> > >
> > > > On 1 November 2012 01:41, Mark Hahn <ma...@hahnca.com> wrote:
> > > >
> > > > > I've just started working on a futon replacement called "ftn" (
> > > > > https://github.com/mark-hahn/ftn). It is a couch app built with
> > > kanso.
> > > > I
> > > > > need to start my app by referencing a design doc like _design/ftn
> and
> > > > then
> > > > > inside my app make ajax calls to a different db.
> > > > >
> > > > > Right now I have to start the app with something like
> > > > > http://domain:5984/ftn/_design/ftn/idx.htm. I obviously would
> like
> > to
> > > > use
> > > > > the vhost and rewrite feature to start the app with something
> > shorter.
> > > I
> > > > > can't figure out how to do this because any ajax call in my app
> for a
> > > > > different db would also be sent to my ftn db due to the vhost.
> > > > >
> > > > > Can someone figure out how I can use a short url instead of
> > > > > http://domain:5984/ftn/_design/ftn/idx.htm?
> > > > >
> > > > >
> > > > Looks like some nice work Mark. Please check over on dev@ there's
> > > already
> > > > some work going on in this vein, we'd love to see you contribute
> there!
> > > >
> > > >
> > > >
> > >
> >
> http://mail-archives.apache.org/mod_mbox/couchdb-dev/201210.mbox/%3CC4A1A200-C7CE-498D-91CB-C84ED7405EE2@redcometlabs.com%3E
> > > >
> > > >
> > >
> >
> http://mail-archives.apache.org/mod_mbox/couchdb-dev/201210.mbox/%3CCAFUSCh-en-K44NBmy=WYVJGkwgkA_Nepb6zcC_V5_2_fSA024Q@mail.gmail.com%3E
> > > >
> > > >
> > > > > P.S. How does futon get away with a URL with just the path _utils?
> > > Can
> > > > I
> > > > > do this with something like _ftn and have it fire up my couch app?
> > > > >
> > > >
> > > >
> > > >
> > >
> >
> https://github.com/apache/couchdb/blob/master/etc/couchdb/default.ini.tpl.in#L124is
> > > > the magic pixie dust. Either point towards the filesystem or take a
> > > > read
> > > > of http://davispj.com/2010/09/26/new-couchdb-externals-api.html and
> > see
> > > if
> > > > you can use that to proxy directly to a couchapp. I think Ryan has a
> > fix
> > > > for this as well?
> > > >
> > > > A+
> > > > Dave
> > > >
> > >
> >
> >
> >
> > --
> > NS
> >
>
--
NS
Re: help with rewrite
Posted by Mark Hahn <ma...@hahnca.com>.
It's actually going faster than I expected. I've never used backbone
before. The backbone router is doing the parsing of the couch urls all by
itself.
Maybe by early next week it will actually be useful as a super-curl.
> And pop on over to the dev list!
I've always assumed that list was for developers of couch, not couch apps.
But I'll take a look.
On Sat, Nov 3, 2012 at 10:00 AM, Noah Slater <ns...@apache.org> wrote:
> Let us know how you get on, Mark! (And pop on over to the dev list!)
>
> On 1 November 2012 01:27, Mark Hahn <ma...@hahnca.com> wrote:
>
> > It doesn't appear anything has happened yet on the new futon you pointed
> me
> > to.
> >
> > I'm going to go ahead for the normal vain reasons. I want to learn new
> > tools and I want to have one that works exactly the way I want it to
> work.
> > Also i think plowing ahead without waiting for committee consensus would
> > be good (excuse my arrogance).
> >
> > Thanks for the links to the magic pixie dust. I hope it doesn't require
> > erlang. If it does I can use the long url for now.
> >
> > On Wed, Oct 31, 2012 at 6:17 PM, Dave Cottlehuber <dc...@jsonified.com>
> > wrote:
> >
> > > On 1 November 2012 01:41, Mark Hahn <ma...@hahnca.com> wrote:
> > >
> > > > I've just started working on a futon replacement called "ftn" (
> > > > https://github.com/mark-hahn/ftn). It is a couch app built with
> > kanso.
> > > I
> > > > need to start my app by referencing a design doc like _design/ftn and
> > > then
> > > > inside my app make ajax calls to a different db.
> > > >
> > > > Right now I have to start the app with something like
> > > > http://domain:5984/ftn/_design/ftn/idx.htm. I obviously would like
> to
> > > use
> > > > the vhost and rewrite feature to start the app with something
> shorter.
> > I
> > > > can't figure out how to do this because any ajax call in my app for a
> > > > different db would also be sent to my ftn db due to the vhost.
> > > >
> > > > Can someone figure out how I can use a short url instead of
> > > > http://domain:5984/ftn/_design/ftn/idx.htm?
> > > >
> > > >
> > > Looks like some nice work Mark. Please check over on dev@ there's
> > already
> > > some work going on in this vein, we'd love to see you contribute there!
> > >
> > >
> > >
> >
> http://mail-archives.apache.org/mod_mbox/couchdb-dev/201210.mbox/%3CC4A1A200-C7CE-498D-91CB-C84ED7405EE2@redcometlabs.com%3E
> > >
> > >
> >
> http://mail-archives.apache.org/mod_mbox/couchdb-dev/201210.mbox/%3CCAFUSCh-en-K44NBmy=WYVJGkwgkA_Nepb6zcC_V5_2_fSA024Q@mail.gmail.com%3E
> > >
> > >
> > > > P.S. How does futon get away with a URL with just the path _utils?
> > Can
> > > I
> > > > do this with something like _ftn and have it fire up my couch app?
> > > >
> > >
> > >
> > >
> >
> https://github.com/apache/couchdb/blob/master/etc/couchdb/default.ini.tpl.in#L124is
> > > the magic pixie dust. Either point towards the filesystem or take a
> > > read
> > > of http://davispj.com/2010/09/26/new-couchdb-externals-api.html and
> see
> > if
> > > you can use that to proxy directly to a couchapp. I think Ryan has a
> fix
> > > for this as well?
> > >
> > > A+
> > > Dave
> > >
> >
>
>
>
> --
> NS
>
Re: help with rewrite
Posted by Noah Slater <ns...@apache.org>.
Let us know how you get on, Mark! (And pop on over to the dev list!)
On 1 November 2012 01:27, Mark Hahn <ma...@hahnca.com> wrote:
> It doesn't appear anything has happened yet on the new futon you pointed me
> to.
>
> I'm going to go ahead for the normal vain reasons. I want to learn new
> tools and I want to have one that works exactly the way I want it to work.
> Also i think plowing ahead without waiting for committee consensus would
> be good (excuse my arrogance).
>
> Thanks for the links to the magic pixie dust. I hope it doesn't require
> erlang. If it does I can use the long url for now.
>
> On Wed, Oct 31, 2012 at 6:17 PM, Dave Cottlehuber <dc...@jsonified.com>
> wrote:
>
> > On 1 November 2012 01:41, Mark Hahn <ma...@hahnca.com> wrote:
> >
> > > I've just started working on a futon replacement called "ftn" (
> > > https://github.com/mark-hahn/ftn). It is a couch app built with
> kanso.
> > I
> > > need to start my app by referencing a design doc like _design/ftn and
> > then
> > > inside my app make ajax calls to a different db.
> > >
> > > Right now I have to start the app with something like
> > > http://domain:5984/ftn/_design/ftn/idx.htm. I obviously would like to
> > use
> > > the vhost and rewrite feature to start the app with something shorter.
> I
> > > can't figure out how to do this because any ajax call in my app for a
> > > different db would also be sent to my ftn db due to the vhost.
> > >
> > > Can someone figure out how I can use a short url instead of
> > > http://domain:5984/ftn/_design/ftn/idx.htm?
> > >
> > >
> > Looks like some nice work Mark. Please check over on dev@ there's
> already
> > some work going on in this vein, we'd love to see you contribute there!
> >
> >
> >
> http://mail-archives.apache.org/mod_mbox/couchdb-dev/201210.mbox/%3CC4A1A200-C7CE-498D-91CB-C84ED7405EE2@redcometlabs.com%3E
> >
> >
> http://mail-archives.apache.org/mod_mbox/couchdb-dev/201210.mbox/%3CCAFUSCh-en-K44NBmy=WYVJGkwgkA_Nepb6zcC_V5_2_fSA024Q@mail.gmail.com%3E
> >
> >
> > > P.S. How does futon get away with a URL with just the path _utils?
> Can
> > I
> > > do this with something like _ftn and have it fire up my couch app?
> > >
> >
> >
> >
> https://github.com/apache/couchdb/blob/master/etc/couchdb/default.ini.tpl.in#L124is
> > the magic pixie dust. Either point towards the filesystem or take a
> > read
> > of http://davispj.com/2010/09/26/new-couchdb-externals-api.html and see
> if
> > you can use that to proxy directly to a couchapp. I think Ryan has a fix
> > for this as well?
> >
> > A+
> > Dave
> >
>
--
NS
Re: help with rewrite
Posted by Mark Hahn <ma...@hahnca.com>.
It doesn't appear anything has happened yet on the new futon you pointed me
to.
I'm going to go ahead for the normal vain reasons. I want to learn new
tools and I want to have one that works exactly the way I want it to work.
Also i think plowing ahead without waiting for committee consensus would
be good (excuse my arrogance).
Thanks for the links to the magic pixie dust. I hope it doesn't require
erlang. If it does I can use the long url for now.
On Wed, Oct 31, 2012 at 6:17 PM, Dave Cottlehuber <dc...@jsonified.com> wrote:
> On 1 November 2012 01:41, Mark Hahn <ma...@hahnca.com> wrote:
>
> > I've just started working on a futon replacement called "ftn" (
> > https://github.com/mark-hahn/ftn). It is a couch app built with kanso.
> I
> > need to start my app by referencing a design doc like _design/ftn and
> then
> > inside my app make ajax calls to a different db.
> >
> > Right now I have to start the app with something like
> > http://domain:5984/ftn/_design/ftn/idx.htm. I obviously would like to
> use
> > the vhost and rewrite feature to start the app with something shorter. I
> > can't figure out how to do this because any ajax call in my app for a
> > different db would also be sent to my ftn db due to the vhost.
> >
> > Can someone figure out how I can use a short url instead of
> > http://domain:5984/ftn/_design/ftn/idx.htm?
> >
> >
> Looks like some nice work Mark. Please check over on dev@ there's already
> some work going on in this vein, we'd love to see you contribute there!
>
>
> http://mail-archives.apache.org/mod_mbox/couchdb-dev/201210.mbox/%3CC4A1A200-C7CE-498D-91CB-C84ED7405EE2@redcometlabs.com%3E
>
> http://mail-archives.apache.org/mod_mbox/couchdb-dev/201210.mbox/%3CCAFUSCh-en-K44NBmy=WYVJGkwgkA_Nepb6zcC_V5_2_fSA024Q@mail.gmail.com%3E
>
>
> > P.S. How does futon get away with a URL with just the path _utils? Can
> I
> > do this with something like _ftn and have it fire up my couch app?
> >
>
>
> https://github.com/apache/couchdb/blob/master/etc/couchdb/default.ini.tpl.in#L124is
> the magic pixie dust. Either point towards the filesystem or take a
> read
> of http://davispj.com/2010/09/26/new-couchdb-externals-api.html and see if
> you can use that to proxy directly to a couchapp. I think Ryan has a fix
> for this as well?
>
> A+
> Dave
>
Re: help with rewrite
Posted by Dave Cottlehuber <dc...@jsonified.com>.
On 1 November 2012 01:41, Mark Hahn <ma...@hahnca.com> wrote:
> I've just started working on a futon replacement called "ftn" (
> https://github.com/mark-hahn/ftn). It is a couch app built with kanso. I
> need to start my app by referencing a design doc like _design/ftn and then
> inside my app make ajax calls to a different db.
>
> Right now I have to start the app with something like
> http://domain:5984/ftn/_design/ftn/idx.htm. I obviously would like to use
> the vhost and rewrite feature to start the app with something shorter. I
> can't figure out how to do this because any ajax call in my app for a
> different db would also be sent to my ftn db due to the vhost.
>
> Can someone figure out how I can use a short url instead of
> http://domain:5984/ftn/_design/ftn/idx.htm?
>
>
Looks like some nice work Mark. Please check over on dev@ there's already
some work going on in this vein, we'd love to see you contribute there!
http://mail-archives.apache.org/mod_mbox/couchdb-dev/201210.mbox/%3CC4A1A200-C7CE-498D-91CB-C84ED7405EE2@redcometlabs.com%3E
http://mail-archives.apache.org/mod_mbox/couchdb-dev/201210.mbox/%3CCAFUSCh-en-K44NBmy=WYVJGkwgkA_Nepb6zcC_V5_2_fSA024Q@mail.gmail.com%3E
> P.S. How does futon get away with a URL with just the path _utils? Can I
> do this with something like _ftn and have it fire up my couch app?
>
https://github.com/apache/couchdb/blob/master/etc/couchdb/default.ini.tpl.in#L124is
the magic pixie dust. Either point towards the filesystem or take a
read
of http://davispj.com/2010/09/26/new-couchdb-externals-api.html and see if
you can use that to proxy directly to a couchapp. I think Ryan has a fix
for this as well?
A+
Dave