[erlang-questions] How to exchange sensitive data with ports?

Elena Garrulo egarrulo@REDACTED
Sat Aug 8 16:07:07 CEST 2009


2009/8/8 Richard Andrews <bflatmaj7th@REDACTED>:
> On Sat, Aug 8, 2009 at 9:35 PM, Elena Garrulo<egarrulo@REDACTED> wrote:
>> What if C calls are time consuming? Does whole Erlang VM stop until
>> the C procedure returns?
>
> IIRC the "control" style driver would block but the IO style driver
> model would not. I think this requires that there is another thread
> somewhere which can issue a callback into erlang with a result. I've
> never implemented one of these.

That's what I was thinking about: making a worker thread handle the
requests asynchronously, sending back the results when done. From your
answer, I understand that is feasible, it's just not sketched into
simpler (synchronous) examples.

>> And user? Can a user process watch another (same) user process?
>
> I don't think this is possible.
>

Well, that's what I did know about Windows, and wondered whether
things were different under Linux.

OK, here is my roadmap: first make the (simpler) ports solution work,
then implementing it as linked-in driver.

Thanks.


More information about the erlang-questions mailing list