[Ur] New website?
Adam Chlipala
adamc at csail.mit.edu
Sun Aug 9 08:42:27 EDT 2015
I remain confused by your description below. Ur/Web has RPCs built into
it, including support for exposing RPC entry points callable from other
languages over HTTP. There is also a standard library for marshalling
and unmarshalling JSON from native types. I don't understand what new
_general_ support for RPCs you're working on that isn't duplicating
built-in functionality.
As for urweb-callback, the mailing-list archives will show my skepticism
of the basic abstraction, at the time it was being designed. I remain
unconvinced that it's necessary, given the periodic-tasks functionality
built into Ur/Web.
On 08/09/2015 05:39 AM, Timothy Beyer wrote:
> At Thu, 06 Aug 2015 11:56:27 -0400,
> Adam Chlipala wrote:
>> Right now, I'm focusing on library stuff, rather than tutorials, such as GUI
>> components similar to what I've used on big Javascript projects, and JSON RPC.
>>
>> Can you elaborate on the JSON RPC part? I can't think of anything of that kind that wasn't
>> already well-supported by Ur/Web and its extended standard library 5 years ago.
> I don't have any specific affection for JSON RPC or RPC in general, but rather
> that I have an odd use case.
>
> I plan on writing desktop type applications that are highly stateful that use
> Ur/Web for the UI and transactional portions of the server side (I'm porting a
> number of Emacs applications that I wrote years ago). A small yet important
> chunk of that state is long running, and I wanted to keep that part away from
> transactional portions of the application.
>
> I opted to have most of that state live on the server side, which is invoked in
> a completely separate process on the server. Perhaps this isn't an optimal
> arrangement, but thus far it seems to work for my requirements, and I was able
> to make a working proof of concept in a few days.
>
> For this purpose, I was able to use the Ur/Web C FFI to call a JSON RPC client
> written in Haskell, which I use to specify stateful actions to run on the
> server side process, which in turn writes to the PostgreSQL database. It is
> only intended to return database related content, at most just pinging back
> Ur/Web so that it knows to update the display.
>
> Sergey recently mentioned to me that he wrote urweb-callback some time ago,
> which might work for many cases that I describe (at the time I wrote the code,
> I wasn't aware of it), although I have to investigate it in more detail to see
> if it is a suitable replacement for what I had in mind (although some of the
> cases aren't well suited to being batch executables or shell scripts).
> Speaking of which, is there any reason why it was not incorporated as part of
> Ur/Web, since applying patches isn't ideal?
>
> Regards,
> Tim
More information about the Ur
mailing list