| Author |
Message |
|
| Guest |
Posted: Wed Dec 05, 2007 5:27 am |
|
|
|
Guest
|
>
> Rails uses a DSL for mapping routes to controllers,actions, and
> params, so you can concisely make clean and hackable urls like /posts/
> 2007/12/02, /posts/tag/holiday, and REST resources. The basic idea is
> to provide more structure, so that everyone does not have to implement
> their own custom route system.
I think that with the ErlyWeb app controller this is even easier, no?
hook(A) ->
NewAppmoddata =
case yaws_arg:appmoddata(A) of
"/posts/foo" -> "/posts/bar";
"/posts/bar" -> "/posts/foo";
Other -> "blah/" ++ Other
end,
{ewc, yaws_arg:appmoddata(A, NewAppmoddata)}.
>
>
> >
> > > * Standardized script interface (for migrations, generators/templates,
> > > tests, maintenance tasks )
> >
> > I'm open to suggestions here.
> >
> >
>
> Currently, erlyweb uses erlang for scripting tasks like generators
> etc, but maybe doing the scripting with a scripting language would be
> a better fit.
I'm not so keen on introducing another dependency. Plus, it kind of
hurts my head to frequently switch between Erlang and a scripting
language. I don't think there would be a big advantage (if any) to be
gained from using a scripting language -- and we should be eating our
own dogfood, no?
>
> Plugins do not migrate or modify the schema directly. Plugins often
> provide generators that the developer uses to generate migration
> files. The developer then does a "rake db:migrate" to actually apply
> any new migrations.
>
> Components are vertical slices of functionality. Plugins should also
> add horizontal slices of functionality, but that is harder to
> accomplish with a compiled language. I think Smerl could be used to
> cleverly add horizontal functionality via plugins, but they key is
> having a standard ized way for smerl to mixin behavior into existing
> modules.
That would certainly be possible -- even fun. In face, that's exactly
what the erlyweb_magic feature does. But what are other possible use
cases for it? Can you give us examples where horizontal slices of
functionality (that can't be done with erlyweb_magic) would be useful?
>
> Maybe plugins are a chicken and egg problem...the reason no body
> creates libs for erlyweb is because there is no standard way to share
> such libs. Perhaps a standard plugin structure would encourage folks
> to share their libs, and lead to a proliferation of contribution.
You can email them to the list
This problem can be solved like this: once people create 2 or more
addons that make sense as plugins as opposed to core framework
features, we will create a plugin system.
>
> Rails gradually got bigger and bigger up to version 1.2.x, and the
> soon to be released Rails 2.0 does not add much new functionality,
> instead it pulled all the non-vital stuff out to plugins. Therefore,
> the core can remain small, and features can be added with plugins.
This sounds like a good approach.
Thanks,
Yariv
--~--~---------~--~----~------------~-------~--~----~
You received this message because you are subscribed to the Google Groups "erlyweb" group.
To post to this group, send email to erlyweb@googlegroups.com
To unsubscribe from this group, send email to erlyweb-unsubscribe@googlegroups.com
For more options, visit this group at http://groups.google.com/group/erlyweb?hl=en
-~----------~----~----~----~------~----~------~--~---
Post recived from mailinglist |
|
|
| Back to top |
|
| Guest |
Posted: Wed Dec 05, 2007 5:41 am |
|
|
|
Guest
|
>
> 1) Steal a couple of ideas/features from seaside ( http://seaside.st/ ).
> Such as, and this is mostly from memory, session management that handle
> * forking of page state due to opening a new window
> * forward and back broswer buttons roll the session state forward and
> back along with the window display.
>
> To see why this could be important take a look at one of the shopping
> cart/e-commerce demos which I can't seem to locate at the moment. so try
> the examples from http://seaside.st/about/examples Having not looked at
> seaside for a while the Halos don't look like a bad idea either.
I confess that I've only looked briefly at Seaside. Its features made
sense to me in the context of its overall design (no meaningful URLs,
server-based continuations) but it didn't click to me how to use these
features in a REST-ful framework like ErlyWeb. I think it would be
possible to keep a bunch of stateful 'ewc' tuples in Mnesia and modify
them using on anchor-triggered continuations, but this is just a very
rough of how it might work -- and I'm not sure it would work very
well. Having said that, if someone wants to take a crack at it, I'll
be happy to let them check in their changes if they are useful.
>
> 2) Better distribution support out of the box. One of the things which
> Erlang makes easier is distributing an app or set of apps across
> multiple node yet erlyweb doesn't take advantage of this to date. What I
> specifically interested in is redundancy so that should one server fail
> for whatever reason the user will not notice, but this could equally
> apply to load balancing. There are ways of doing this with linux-HA,
> etc, but I think this is something better handled by the webserver
> directly for various reasons. Parts of this may be better done as a
> spin-off project.
Without having done it, I think this would be pretty easy -- keep
session data in Mnesia and replicate the table across nodes. If a
server goes down, other servers will maintain the same state and you
could just route traffic to them.
However, I think that unless you're building a banking application or
something, occasionally losing session state due to a server crash
isn't such a big deal. Most webapps don't need to worry about it too
much.
What I think would be useful is an automated deploy script that checks
out the latest code from the repository and deploys it across a
cluster of ErlyWeb servers (without restarting them, of course ).
However, this kind of project is generally best done out of concrete
rather than hypothetical needs -- there are always some details that
you would miss unless you actually need this feature in your
production environment.
Is anyone out there running an ErlyWeb cluster by any chance?
Thanks,
Yariv
--~--~---------~--~----~------------~-------~--~----~
You received this message because you are subscribed to the Google Groups "erlyweb" group.
To post to this group, send email to erlyweb@googlegroups.com
To unsubscribe from this group, send email to erlyweb-unsubscribe@googlegroups.com
For more options, visit this group at http://groups.google.com/group/erlyweb?hl=en
-~----------~----~----~----~------~----~------~--~---
Post recived from mailinglist |
|
|
| Back to top |
|
| Guest |
Posted: Wed Dec 05, 2007 5:45 am |
|
|
|
Guest
|
> Whoops. Knew I forgot something. I second this. I don't think this would
> be too hard - someone correct me if I'm wrong. Erlyweb would only need
> to have a couple of new HTTP methods added on top of the GET/POST
> already supported which mean doing something like
>
> case yaws_arg:method(A) of
> 'POST' -> do_something1;
> 'GET' -> do_something2;
> 'PUT' -> do_something3;
> 'DELETE' -> do_something4;
> _ -> oops
> end
>
> in your app_controller or where ever you needed to differentiate between
> the methods. Now, I haven't been playing with erlyweb of late so the
> foregoing is most likely wrong-ish at best.
As I suggested before, you can do this in the hook/1 function. Just
rewrite the appmoddata field of the arg before passing it down to
ErlyWeb.
Yariv
--~--~---------~--~----~------------~-------~--~----~
You received this message because you are subscribed to the Google Groups "erlyweb" group.
To post to this group, send email to erlyweb@googlegroups.com
To unsubscribe from this group, send email to erlyweb-unsubscribe@googlegroups.com
For more options, visit this group at http://groups.google.com/group/erlyweb?hl=en
-~----------~----~----~----~------~----~------~--~---
Post recived from mailinglist |
|
|
| Back to top |
|
| ketralnis |
Posted: Wed Dec 05, 2007 5:48 am |
|
|
|
User
Joined: 20 Jul 2007
Posts: 151
Location: San Francisco, CA
|
>> Rails uses a DSL for mapping routes to controllers,actions, and
>> params, so you can concisely make clean and hackable urls like /
>> posts/
>> 2007/12/02, /posts/tag/holiday, and REST resources. The basic idea
>> is
>> to provide more structure, so that everyone does not have to
>> implement
>> their own custom route system.
> I think that with the ErlyWeb app controller this is even easier, no?
> hook(A) ->
> NewAppmoddata =
> case yaws_arg:appmoddata(A) of
> "/posts/foo" -> "/posts/bar";
> "/posts/bar" -> "/posts/foo";
> Other -> "blah/" ++ Other
> end,
> {ewc, yaws_arg:appmoddata(A, NewAppmoddata)}.
For the record, I prefer it this way
--~--~---------~--~----~------------~-------~--~----~
You received this message because you are subscribed to the Google Groups "erlyweb" group.
To post to this group, send email to erlyweb@googlegroups.com
To unsubscribe from this group, send email to erlyweb-unsubscribe@googlegroups.com
For more options, visit this group at http://groups.google.com/group/erlyweb?hl=en
-~----------~----~----~----~------~----~------~--~---
Post recived from mailinglist |
|
|
| Back to top |
|
| Guest |
Posted: Wed Dec 05, 2007 7:17 am |
|
|
|
Guest
|
> This problem can be solved like this: once people create 2 or more
> addons that make sense as plugins as opposed to core framework
> features, we will create a plugin system.
By the way, if anyone wants to volunteer to create a plugin system,
I'll be happy to let him/her add it to ErlyWeb. I'm just trying to
prioritize the stuff that's on my plate.
Yariv
--~--~---------~--~----~------------~-------~--~----~
You received this message because you are subscribed to the Google Groups "erlyweb" group.
To post to this group, send email to erlyweb@googlegroups.com
To unsubscribe from this group, send email to erlyweb-unsubscribe@googlegroups.com
For more options, visit this group at http://groups.google.com/group/erlyweb?hl=en
-~----------~----~----~----~------~----~------~--~---
Post recived from mailinglist |
|
|
| Back to top |
|
| Guest |
Posted: Wed Dec 05, 2007 8:27 am |
|
|
|
Guest
|
Some good examples of plugin based horizontal functionality, are all
the Rails acts_as_* plugins.
Has anyone looked at Faxien by Erlware?
Faxien does dependencies and versioning of erlang packages, so it
could be a "plugin system".
On Dec 4, 11:16 pm, "Yariv Sadan" <yarivsa...@gmail.com> wrote:
> > This problem can be solved like this: once people create 2 or more
> > addons that make sense as plugins as opposed to core framework
> > features, we will create a plugin system.
>
> By the way, if anyone wants to volunteer to create a plugin system,
> I'll be happy to let him/her add it to ErlyWeb. I'm just trying to
> prioritize the stuff that's on my plate.
>
> Yariv
--~--~---------~--~----~------------~-------~--~----~
You received this message because you are subscribed to the Google Groups "erlyweb" group.
To post to this group, send email to erlyweb@googlegroups.com
To unsubscribe from this group, send email to erlyweb-unsubscribe@googlegroups.com
For more options, visit this group at http://groups.google.com/group/erlyweb?hl=en
-~----------~----~----~----~------~----~------~--~---
Post recived from mailinglist |
|
|
| Back to top |
|
| ketralnis |
Posted: Fri Dec 07, 2007 2:23 am |
|
|
|
User
Joined: 20 Jul 2007
Posts: 151
Location: San Francisco, CA
|
> Also, we should start planning the next release. What features do you
> think will be most useful (web services support is on the list)?
Have you considered using an existing database abstraction system like
ODBC instead of using a home-brewed one? That might help avoid these
cross-database issues.
--~--~---------~--~----~------------~-------~--~----~
You received this message because you are subscribed to the Google Groups "erlyweb" group.
To post to this group, send email to erlyweb@googlegroups.com
To unsubscribe from this group, send email to erlyweb-unsubscribe@googlegroups.com
For more options, visit this group at http://groups.google.com/group/erlyweb?hl=en
-~----------~----~----~----~------~----~------~--~---
Post recived from mailinglist |
|
|
| Back to top |
|
| Guest |
Posted: Fri Dec 07, 2007 8:45 am |
|
|
|
Guest
|
On Dec 6, 2007 6:22 PM, David King <dking@ketralnis.com> wrote:
>
> > Also, we should start planning the next release. What features do you
> > think will be most useful (web services support is on the list)?
>
> Have you considered using an existing database abstraction system like
> ODBC instead of using a home-brewed one? That might help avoid these
> cross-database issues.
Isn't ODBC a Windows thing?
I think using a whole new database abstraction strategy to avoid bugs
like the ones we've seen is overkill. We just need people to use the
existing drivers so the bugs are actually discovered before the code
is released. The MySQL driver works great because I've been using it
and fixing its bugs. Apparently the Postgres driver hasn't gotten the
same kind of love
Yariv
>
>
> >
>
--~--~---------~--~----~------------~-------~--~----~
You received this message because you are subscribed to the Google Groups "erlyweb" group.
To post to this group, send email to erlyweb@googlegroups.com
To unsubscribe from this group, send email to erlyweb-unsubscribe@googlegroups.com
For more options, visit this group at http://groups.google.com/group/erlyweb?hl=en
-~----------~----~----~----~------~----~------~--~---
Post recived from mailinglist |
|
|
| Back to top |
|
| ketralnis |
Posted: Fri Dec 07, 2007 4:21 pm |
|
|
|
User
Joined: 20 Jul 2007
Posts: 151
Location: San Francisco, CA
|
>> Have you considered using an existing database abstraction system
>> like
>> ODBC instead of using a home-brewed one? That might help avoid these
>> cross-database issues.
> Isn't ODBC a Windows thing?
I don't know much about ODBC specifically (it's *supposed* to be cross-
patform, I don't know how well that works in practise), and there are
probably other similar systems. but my point is that very smart people
have already solved the problem of database abstraction, it seems a
waste and is clearly error-prone to re-invent their wheel
> I think using a whole new database abstraction strategy to avoid bugs
> like the ones we've seen is overkill. We just need people to use the
> existing drivers so the bugs are actually discovered before the code
> is released. The MySQL driver works great because I've been using it
> and fixing its bugs. Apparently the Postgres driver hasn't gotten the
> same kind of love
--~--~---------~--~----~------------~-------~--~----~
You received this message because you are subscribed to the Google Groups "erlyweb" group.
To post to this group, send email to erlyweb@googlegroups.com
To unsubscribe from this group, send email to erlyweb-unsubscribe@googlegroups.com
For more options, visit this group at http://groups.google.com/group/erlyweb?hl=en
-~----------~----~----~----~------~----~------~--~---
Post recived from mailinglist |
|
|
| Back to top |
|
| ketralnis |
Posted: Fri Dec 07, 2007 4:58 pm |
|
|
|
User
Joined: 20 Jul 2007
Posts: 151
Location: San Francisco, CA
|
>> Isn't ODBC a Windows thing?
<http://en.wikipedia.org/wiki/
Open_Database_Connectivity#Implementations>
> The designers of ODBC aimed to make it independent of programming
> languages, database systems, and operating systems
> ODBC implementations run on many operating systems, including
> Microsoft Windows, Unix, Linux, OS/2, OS400, IBM i5/OS, and Mac OS
> X. Hundreds of ODBC drivers exist, including drivers for Oracle,
> DB2, Microsoft SQL Server, Sybase, Pervasive SQL, MySQL, PostgreSQL,
> and desktop database products such as FileMaker, and Microsoft Access
Erlang ships with an ODBC implementation <http://www.erlang.org/doc/apps/odbc/index.html
>
<http://www.erlang.org/doc/apps/odbc/getting_started.html>: The Erlang
ODBC application should run on all Unix dialects including Linux,
Windows 2000, Windows XP and NT. But currently it is only tested for
Solaris, Windows 2000, Windows XP and NT
I'm not advocating ODBC specifically (although I am advocating using
an existing hammer for this nail), I just wanted to point that out for
the curious.
--~--~---------~--~----~------------~-------~--~----~
You received this message because you are subscribed to the Google Groups "erlyweb" group.
To post to this group, send email to erlyweb@googlegroups.com
To unsubscribe from this group, send email to erlyweb-unsubscribe@googlegroups.com
For more options, visit this group at http://groups.google.com/group/erlyweb?hl=en
-~----------~----~----~----~------~----~------~--~---
Post recived from mailinglist |
|
|
| Back to top |
|
|
|
All times are GMT
|
|
You cannot post new topics in this forum You cannot reply to topics in this forum You cannot edit your posts in this forum You cannot delete your posts in this forum You cannot vote in polls in this forum You cannot attach files in this forum You cannot download files in this forum
|
|
|