[server] HTTP + SQLite bundled as single EXE?

Previous Topic Next Topic
 
classic Classic list List threaded Threaded
29 messages Options
12
Reply | Threaded
Open this post in threaded view
|

[server] HTTP + SQLite bundled as single EXE?

Gilles Ganault-3
Hello,

It's probably quite an easy thing to do for someone well versed in C,
but I haven't seen a project that would combine a web server and
SQLite into a single EXE.

Besides ease of deployment, this would offer a cross-platform solution
that wouldn't require developing a specific client-side connector,
since both hosts would speak HTTP.

Would someone with enough know-how be interested in giving it a shot?
Are there technical reasons why it wouldn't be a good idea?

Thank you.

_______________________________________________
sqlite-users mailing list
[hidden email]
http://sqlite.org:8080/cgi-bin/mailman/listinfo/sqlite-users
Reply | Threaded
Open this post in threaded view
|

Re: [server] HTTP + SQLite bundled as single EXE?

Simon Slavin-3

On 2 May 2010, at 8:26pm, Gilles Ganault wrote:

> It's probably quite an easy thing to do for someone well versed in C,
> but I haven't seen a project that would combine a web server and
> SQLite into a single EXE.
>
> Besides ease of deployment, this would offer a cross-platform solution
> that wouldn't require developing a specific client-side connector,
> since both hosts would speak HTTP.

How are you seeing this ?  You send your SQL queries via HTTP and it answers by replying with XML ?

Simon.
_______________________________________________
sqlite-users mailing list
[hidden email]
http://sqlite.org:8080/cgi-bin/mailman/listinfo/sqlite-users
Reply | Threaded
Open this post in threaded view
|

Re: [server] HTTP + SQLite bundled as single EXE?

Günter Greschenz
In reply to this post by Gilles Ganault-3
hi,
 
i did this some years ago:
1) sqlite
2) spidermonkey
3) my own http server
if you are interested, i have to search my old code...
 
bye, gg
 

Gilles Ganault <[hidden email]> hat am 2. Mai 2010 um 21:26 geschrieben:

> Hello,
>
> It's probably quite an easy thing to do for someone well versed in C,
> but I haven't seen a project that would combine a web server and
> SQLite into a single EXE.
>
> Besides ease of deployment, this would offer a cross-platform solution
> that wouldn't require developing a specific client-side connector,
> since both hosts would speak HTTP.
>
> Would someone with enough know-how be interested in giving it a shot?
> Are there technical reasons why it wouldn't be a good idea?
>
> Thank you.
>
> _______________________________________________
> sqlite-users mailing list
> [hidden email]
> http://sqlite.org:8080/cgi-bin/mailman/listinfo/sqlite-users
_______________________________________________
sqlite-users mailing list
[hidden email]
http://sqlite.org:8080/cgi-bin/mailman/listinfo/sqlite-users
Reply | Threaded
Open this post in threaded view
|

Re: [server] HTTP + SQLite bundled as single EXE?

Alexey Pechnikov-2
In reply to this post by Gilles Ganault-3
it's easy for TCL developers. You may build tclsqlite+tclhttpd+your
tcl scripts as starpack (single executable binary). For integrate
SQLite database into starpack use this extension:
http://www.siftsoft.com/tclsqlitevfs.html

This is work fine on linux/windows and some other platforms.

--
Best regards, Alexey Pechnikov.
http://pechnikov.tel/
_______________________________________________
sqlite-users mailing list
[hidden email]
http://sqlite.org:8080/cgi-bin/mailman/listinfo/sqlite-users
Reply | Threaded
Open this post in threaded view
|

Re: [server] HTTP + SQLite bundled as single EXE?

Kees Nuyt
In reply to this post by Gilles Ganault-3
On Sun, 02 May 2010 21:26:27 +0200, Gilles Ganault
<[hidden email]> wrote:

>Hello,
>
>It's probably quite an easy thing to do for someone well versed in C,
>but I haven't seen a project that would combine a web server and
>SQLite into a single EXE.

It may not be what you mean, but you should have a look at
fossil (also by drh):
http://www.fossil-scm.org/index.html/doc/tip/www/index.wiki
--
  (  Kees Nuyt
  )
c[_]
_______________________________________________
sqlite-users mailing list
[hidden email]
http://sqlite.org:8080/cgi-bin/mailman/listinfo/sqlite-users
Reply | Threaded
Open this post in threaded view
|

Re: [server] HTTP + SQLite bundled as single EXE?

Matt Young-5
In reply to this post by Gilles Ganault-3
I want to see SQLite integrated into the R statistical package. R Project
http://www.gardenersown.co.uk/Education/Lectures/R/regression.htm#multiple_regression

for example.

R statistical is very and becoming more popular, has great plotting,
and wrestles data in frames that look awfully like sql tables.  R has
built in procedure function, can cast text around fairly powerfully
and so on.  It is begging for the sqlite engine.

Like me, getting better access to government statistical table.


On 5/2/10, Gilles Ganault <[hidden email]> wrote:

> Hello,
>
> It's probably quite an easy thing to do for someone well versed in C,
> but I haven't seen a project that would combine a web server and
> SQLite into a single EXE.
>
> Besides ease of deployment, this would offer a cross-platform solution
> that wouldn't require developing a specific client-side connector,
> since both hosts would speak HTTP.
>
> Would someone with enough know-how be interested in giving it a shot?
> Are there technical reasons why it wouldn't be a good idea?
>
> Thank you.
>
> _______________________________________________
> sqlite-users mailing list
> [hidden email]
> http://sqlite.org:8080/cgi-bin/mailman/listinfo/sqlite-users
>
_______________________________________________
sqlite-users mailing list
[hidden email]
http://sqlite.org:8080/cgi-bin/mailman/listinfo/sqlite-users
Reply | Threaded
Open this post in threaded view
|

Re: [server] HTTP + SQLite bundled as single EXE?

Simon Slavin-3

On 3 May 2010, at 1:38am, Matt Young wrote:

> I want to see SQLite integrated into the R statistical package.

You have our permission.  Go ahead.

Simon.
_______________________________________________
sqlite-users mailing list
[hidden email]
http://sqlite.org:8080/cgi-bin/mailman/listinfo/sqlite-users
Reply | Threaded
Open this post in threaded view
|

Re: [server] HTTP + SQLite bundled as single EXE?

Gabor Grothendieck
In reply to this post by Matt Young-5
SQLite and R are already integrated through the RSQLite/DBI packages
and even higher level facilities (which I have posted about on this
thread) also exist.  I think that such an integration would logically
be done by R people rather than sqlite people.

In the discussion on this thread integration may mean different things
to different people so if you are referring to specific features
beyond what exists (such as a SQL functions written in R or stored
procedures written in R) then you can (1) speak with the RSQLite
package maintainer to see if he is interested in adding them or (2) if
you are interested in contributing then also discuss it with him, or
(3) if you are referring to specific features that make more sense in
certain other R packages (sqldf, RODBC, RJDBC, sqliteDF) then you can
communicate to the maintainers of those packages.

On Sun, May 2, 2010 at 8:38 PM, Matt Young <[hidden email]> wrote:

> I want to see SQLite integrated into the R statistical package. R Project
> http://www.gardenersown.co.uk/Education/Lectures/R/regression.htm#multiple_regression
>
> for example.
>
> R statistical is very and becoming more popular, has great plotting,
> and wrestles data in frames that look awfully like sql tables.  R has
> built in procedure function, can cast text around fairly powerfully
> and so on.  It is begging for the sqlite engine.
>
> Like me, getting better access to government statistical table.
>
>
> On 5/2/10, Gilles Ganault <[hidden email]> wrote:
>> Hello,
>>
>> It's probably quite an easy thing to do for someone well versed in C,
>> but I haven't seen a project that would combine a web server and
>> SQLite into a single EXE.
>>
>> Besides ease of deployment, this would offer a cross-platform solution
>> that wouldn't require developing a specific client-side connector,
>> since both hosts would speak HTTP.
>>
>> Would someone with enough know-how be interested in giving it a shot?
>> Are there technical reasons why it wouldn't be a good idea?
>>
>> Thank you.
>>
>> _______________________________________________
>> sqlite-users mailing list
>> [hidden email]
>> http://sqlite.org:8080/cgi-bin/mailman/listinfo/sqlite-users
>>
> _______________________________________________
> sqlite-users mailing list
> [hidden email]
> http://sqlite.org:8080/cgi-bin/mailman/listinfo/sqlite-users
>
_______________________________________________
sqlite-users mailing list
[hidden email]
http://sqlite.org:8080/cgi-bin/mailman/listinfo/sqlite-users
Reply | Threaded
Open this post in threaded view
|

Re: [server] HTTP + SQLite bundled as single EXE?

Matt Young-5
Thanks, I will follow up.

On 5/2/10, Gabor Grothendieck <[hidden email]> wrote:

> SQLite and R are already integrated through the RSQLite/DBI packages
> and even higher level facilities (which I have posted about on this
> thread) also exist.  I think that such an integration would logically
> be done by R people rather than sqlite people.
>
> In the discussion on this thread integration may mean different things
> to different people so if you are referring to specific features
> beyond what exists (such as a SQL functions written in R or stored
> procedures written in R) then you can (1) speak with the RSQLite
> package maintainer to see if he is interested in adding them or (2) if
> you are interested in contributing then also discuss it with him, or
> (3) if you are referring to specific features that make more sense in
> certain other R packages (sqldf, RODBC, RJDBC, sqliteDF) then you can
> communicate to the maintainers of those packages.
>
> On Sun, May 2, 2010 at 8:38 PM, Matt Young <[hidden email]> wrote:
>> I want to see SQLite integrated into the R statistical package. R Project
>> http://www.gardenersown.co.uk/Education/Lectures/R/regression.htm#multiple_regression
>>
>> for example.
>>
>> R statistical is very and becoming more popular, has great plotting,
>> and wrestles data in frames that look awfully like sql tables.  R has
>> built in procedure function, can cast text around fairly powerfully
>> and so on.  It is begging for the sqlite engine.
>>
>> Like me, getting better access to government statistical table.
>>
>>
>> On 5/2/10, Gilles Ganault <[hidden email]> wrote:
>>> Hello,
>>>
>>> It's probably quite an easy thing to do for someone well versed in C,
>>> but I haven't seen a project that would combine a web server and
>>> SQLite into a single EXE.
>>>
>>> Besides ease of deployment, this would offer a cross-platform solution
>>> that wouldn't require developing a specific client-side connector,
>>> since both hosts would speak HTTP.
>>>
>>> Would someone with enough know-how be interested in giving it a shot?
>>> Are there technical reasons why it wouldn't be a good idea?
>>>
>>> Thank you.
>>>
>>> _______________________________________________
>>> sqlite-users mailing list
>>> [hidden email]
>>> http://sqlite.org:8080/cgi-bin/mailman/listinfo/sqlite-users
>>>
>> _______________________________________________
>> sqlite-users mailing list
>> [hidden email]
>> http://sqlite.org:8080/cgi-bin/mailman/listinfo/sqlite-users
>>
> _______________________________________________
> sqlite-users mailing list
> [hidden email]
> http://sqlite.org:8080/cgi-bin/mailman/listinfo/sqlite-users
>
_______________________________________________
sqlite-users mailing list
[hidden email]
http://sqlite.org:8080/cgi-bin/mailman/listinfo/sqlite-users
Reply | Threaded
Open this post in threaded view
|

Re: [server] HTTP + SQLite bundled as single EXE?

Gilles Ganault-3
In reply to this post by Simon Slavin-3
On Sun, 2 May 2010 20:31:15 +0100, Simon Slavin
<[hidden email]> wrote:
>How are you seeing this ?  You send your SQL queries via HTTP and it answers by replying with XML ?

XML or TAB-separated text. Using regexes, it's easy to parse data,
unless someone knows of a better way.
Besides, if there are a lot of SELECTed data, since any HTTP library
worth its salt handles GZIP, the server can zip data before sending
them over the wire.

Actually, it seems like this single-EXE SQLite server could be
achieved simply by ripping unneeded code from Dr. Hipp's other great
software, the Fossil source control management software:

www.fossil-scm.org

Ideally, the Windows version could be started either as a stand-alone
EXE or as a Service.

For those great C developers out there: What do you think of this
idea?

Thank you.

_______________________________________________
sqlite-users mailing list
[hidden email]
http://sqlite.org:8080/cgi-bin/mailman/listinfo/sqlite-users
Reply | Threaded
Open this post in threaded view
|

Re: [server] HTTP + SQLite bundled as single EXE?

Simon Slavin-3

On 3 May 2010, at 8:14am, Gilles Ganault wrote:

> On Sun, 2 May 2010 20:31:15 +0100, Simon Slavin
> <[hidden email]> wrote:
>> How are you seeing this ?  You send your SQL queries via HTTP and it answers by replying with XML ?
>
> XML or TAB-separated text. Using regexes, it's easy to parse data,
> unless someone knows of a better way.
> [snip]

If you're going to mostly pass data for use with web applications then JSON is possibly a more appropriate format, since it can be used to construct JavaScript objects just by using the single command 'eval'.  A good implementation would do any of the three, depending on what was passed in the URL or URI.

> For those great C developers out there: What do you think of this
> idea?

The problem is not in coding it -- that's relatively easy.  The problem is in who would use it.  I think that would be mostly people who already use PHP to write a backend data server.  The advantage of this is that it can be done using just the hugely popular and tested Apache: it already has SQLite built in.

On the other hand, Apache is huge, complicated and hard to test.  A minimal kit including just HTTP and SQLite would be smaller and simpler and therefore more in the spirit of SQLite.

Simon.
_______________________________________________
sqlite-users mailing list
[hidden email]
http://sqlite.org:8080/cgi-bin/mailman/listinfo/sqlite-users
Reply | Threaded
Open this post in threaded view
|

Re: [server] HTTP + SQLite bundled as single EXE?

Gilles Ganault-3
On Mon, 3 May 2010 11:24:49 +0100, Simon Slavin
<[hidden email]> wrote:
>If you're going to mostly pass data for use with web applications then JSON is possibly a more appropriate format

Thanks, I'll check it out.

>The problem is not in coding it -- that's relatively easy.  The problem is in who would use it.

Anyone who is currently using SQLite but needs...
0. a supported (so it's updated when a new version of SQLite comes out
that might require some changes in the solution)
1. cross-platform (so the server can run on Windows, Linux, MacOS)
2. easy-to-deploy client/server alternative since it's a single binary
3. that simply listens on a TCP port instead of the headaches of
sharing a directory with SMB/CIFS
4. to safely share an SQLite database among a few concurrent clients
(otherwise, people would just use a full-fledged DMBS)
5. and uses HTTP so that no specific client-side component is required

I don't know if it'd be easier to combine existing HTTP server +
SQLite, or go from Fossil and remove things that aren't needed.

_______________________________________________
sqlite-users mailing list
[hidden email]
http://sqlite.org:8080/cgi-bin/mailman/listinfo/sqlite-users
Reply | Threaded
Open this post in threaded view
|

Re: [server] HTTP + SQLite bundled as single EXE?

Alexey Pechnikov-2
See http://wiki.tcl.tk/15722 Add SQLite into it - about few minuts of time.

2010/5/3 Gilles Ganault <[hidden email]>:
> I don't know if it'd be easier to combine existing HTTP server +
> SQLite

--
Best regards, Alexey Pechnikov.
http://pechnikov.tel/
_______________________________________________
sqlite-users mailing list
[hidden email]
http://sqlite.org:8080/cgi-bin/mailman/listinfo/sqlite-users
Reply | Threaded
Open this post in threaded view
|

Re: [server] HTTP + SQLite bundled as single EXE?

Gilles Ganault-3
On Mon, 3 May 2010 15:01:26 +0400, Alexey Pechnikov
<[hidden email]> wrote:

>See http://wiki.tcl.tk/15722 Add SQLite into it - about few minuts of time.

Thanks. If no one is interested in launching a project that would
offer a single binary and maintain it, I'll try TCL-TK.

_______________________________________________
sqlite-users mailing list
[hidden email]
http://sqlite.org:8080/cgi-bin/mailman/listinfo/sqlite-users
Reply | Threaded
Open this post in threaded view
|

Re: [server] HTTP + SQLite bundled as single EXE?

Sylvain Pointeau
How do you authenticate to your http sqlite web server?
is it not a security issue then?

normally you would also need a server side language, so I would say apache
is the only way to go,
and also I don't understand why you need something specific to return JSON
object.
you can do it in 3 seconds in PHP or ASP.NET.

is there something I didn't understand?

Best regards,
Sylvain


On Mon, May 3, 2010 at 1:06 PM, Gilles Ganault <[hidden email]>wrote:

> On Mon, 3 May 2010 15:01:26 +0400, Alexey Pechnikov
> <[hidden email]> wrote:
>
> >See http://wiki.tcl.tk/15722 Add SQLite into it - about few minuts of
> time.
>
> Thanks. If no one is interested in launching a project that would
> offer a single binary and maintain it, I'll try TCL-TK.
>
> _______________________________________________
> sqlite-users mailing list
> [hidden email]
> http://sqlite.org:8080/cgi-bin/mailman/listinfo/sqlite-users
>
_______________________________________________
sqlite-users mailing list
[hidden email]
http://sqlite.org:8080/cgi-bin/mailman/listinfo/sqlite-users
Reply | Threaded
Open this post in threaded view
|

Re: [server] HTTP + SQLite bundled as single EXE?

Gilles Ganault-3
On Mon, 3 May 2010 14:41:10 +0200, Sylvain Pointeau
<[hidden email]> wrote:
>How do you authenticate to your http sqlite web server?
>is it not a security issue then?

SQLite is meant for local use, so people interested in an SQLite
server would operate on a small LAN, protected from the Net by a
firewall.

If authentication/obfuscation is needed, what about .htaccess and
HTTPS?

>is there something I didn't understand?

I'd like a single EXE so it's as easy to deploy as SQLite. Otherwise,
I'd just use MySQL or PostgreSQL.

_______________________________________________
sqlite-users mailing list
[hidden email]
http://sqlite.org:8080/cgi-bin/mailman/listinfo/sqlite-users
Reply | Threaded
Open this post in threaded view
|

Re: [server] HTTP + SQLite bundled as single EXE?

Sylvain Pointeau
if you speak about MySQL or POSTGRESQL
then you mean database server, not a web server.

Do you want to have a server where to connect for making your SELECT, UPDATE
DELETE, CREATE?
or do you want a webserver to just do some SELECT? (and having a XML, JSON
or whatever)

Best regards,
Sylvain


On Mon, May 3, 2010 at 2:43 PM, Gilles Ganault <[hidden email]>wrote:

> On Mon, 3 May 2010 14:41:10 +0200, Sylvain Pointeau
> <[hidden email]> wrote:
> >How do you authenticate to your http sqlite web server?
> >is it not a security issue then?
>
> SQLite is meant for local use, so people interested in an SQLite
> server would operate on a small LAN, protected from the Net by a
> firewall.
>
> If authentication/obfuscation is needed, what about .htaccess and
> HTTPS?
>
> >is there something I didn't understand?
>
> I'd like a single EXE so it's as easy to deploy as SQLite. Otherwise,
> I'd just use MySQL or PostgreSQL.
>
> _______________________________________________
> sqlite-users mailing list
> [hidden email]
> http://sqlite.org:8080/cgi-bin/mailman/listinfo/sqlite-users
>
_______________________________________________
sqlite-users mailing list
[hidden email]
http://sqlite.org:8080/cgi-bin/mailman/listinfo/sqlite-users
Reply | Threaded
Open this post in threaded view
|

Re: [server] HTTP + SQLite bundled as single EXE?

Gilles Ganault-3
On Mon, 3 May 2010 14:47:48 +0200, Sylvain Pointeau
<[hidden email]> wrote:
>if you speak about MySQL or POSTGRESQL
>then you mean database server, not a web server.

Yes. Please read the thread, starting with my original post where I
explain the idea.

_______________________________________________
sqlite-users mailing list
[hidden email]
http://sqlite.org:8080/cgi-bin/mailman/listinfo/sqlite-users
Reply | Threaded
Open this post in threaded view
|

Re: [server] HTTP + SQLite bundled as single EXE?

Sylvain Pointeau
this is not clear for me.

On Mon, May 3, 2010 at 2:49 PM, Gilles Ganault <[hidden email]>wrote:

> On Mon, 3 May 2010 14:47:48 +0200, Sylvain Pointeau
> <[hidden email]> wrote:
> >if you speak about MySQL or POSTGRESQL
> >then you mean database server, not a web server.
>
> Yes. Please read the thread, starting with my original post where I
> explain the idea.
>
> _______________________________________________
> sqlite-users mailing list
> [hidden email]
> http://sqlite.org:8080/cgi-bin/mailman/listinfo/sqlite-users
>
_______________________________________________
sqlite-users mailing list
[hidden email]
http://sqlite.org:8080/cgi-bin/mailman/listinfo/sqlite-users
Reply | Threaded
Open this post in threaded view
|

Re: [server] HTTP + SQLite bundled as single EXE?

jreidthompson
In reply to this post by Alexey Pechnikov-2
On Mon, May 03, 2010 at 03:01:26PM +0400, Alexey Pechnikov wrote:
> See http://wiki.tcl.tk/15722 Add SQLite into it - about few minuts of time.
>
> 2010/5/3 Gilles Ganault <[hidden email]>:
> > I don't know if it'd be easier to combine existing HTTP server +
> > SQLite

ditto
http://code.google.com/p/mongoose/
_______________________________________________
sqlite-users mailing list
[hidden email]
http://sqlite.org:8080/cgi-bin/mailman/listinfo/sqlite-users
12