barries wrote:
>
> On Thu, Mar 29, 2001 at 12:47:35PM -0600, elble@stripped wrote:
> > > In a wild moment of engineering excess, I considered
> > > adding perl to mysqld to make writing the algrithms easier, but wised up
> > > quickly (has anyone done that for writing Procedure callbacks?).
> >
> > i've actually been thinking about this quite a bit, and drawing tenative
> > parallels to mod_perl for apache.
>
> Yeah, that's the parallel I've been making internally. It's have to be
> interpreter per-thread, due to perl5's threading instabilities, and
> right now MySQL doesn't have enough hooks to make it really useful,
> though a subclass of Procedure and a call-into-perl udf abstraction
> would be useful.
>
> > my thoughts were evolving along the lines of:
> >
> > MySQL <-> Trigger API <-> Module
> >
> > and then you could code whatever you wanted into the module
> > (support for perl, python, whatever... my interest would
> > be perl)
> >
> > i'd be interested to hear monty's views on the subject.
> > one of my questions would be on where the trigger routines'
> > text would be stored (if a module supports interpret-on-the-fly).
>
> I'd put non-native triggers in a "triggers" table in each database.
>
> That's all armchair quarterbacking, I'm not persuing a perl-in mysqld
> approach because our datasets are too big to do that, and because it's
> all relatively simple integer based foreign & primary key, so Perl's not
> bringing too much advantage to the party.
>
> But I think it would be cool. OTOH, the mysqld-as-linkable-library
> approach might let you combine
>
> Apache2.0 <-> mod_perl <-> mysqld
>
> in a one process, multiple threads configuration that would scream. But
> that's prolly OT for the mysql internals list...
I kinda like the idea of using Java classes/jars which can then be
stored in BLOBs in a table for Java stored procedures/triggers. The APIs
to call into Java from C/C++ is pretty standardised and usually supports
threading in all supported platforms.
If the table only stores classes, there are ways to compact a suite of
classes into one class file for more complex stored procedures and being
stored in a table, it would be persistant.
--
ANTONY T CURTIS Tel: +44 (1635) 36222
Abacus Polar Holdings Ltd Fax: +44 (1635) 38670
> Immigration is the sincerest form of flattery.
> -- Jack Paar