The easiest way to make data generated by A.perl available to a separate process running B.perl may be to have A.perl write the data to external storage that B.perl can read. This would commonly be a database or file.

To learn how to use a database you might read some of the material in Database Programming.

To use a file, you have many options for formatting your data. You might search CPAN for serialize. In particular, you might be interested in YAML. There are also many modules that would help you if you wanted to save your data in the form of an XML file: you can search cpan for xml for options.

Another set of modules that you might find helpful are the Tie modules. Tie::Concurrent comes to mind as it appears you want concurrent access to the data. If you are certain that concurrency is not an issue then Tie::Simple or Tie::Persistent may be adequate.

Otherwise, you might consider the options presented in perlipc.


In reply to Re: Perl - unix process by ig
in thread Perl - unix process by Deeepu

Title:
Use:  <p> text here (a paragraph) </p>
and:  <code> code here </code>
to format your post, it's "PerlMonks-approved HTML":



  • Posts are HTML formatted. Put <p> </p> tags around your paragraphs. Put <code> </code> tags around your code and data!
  • Titles consisting of a single word are discouraged, and in most cases are disallowed outright.
  • Read Where should I post X? if you're not absolutely sure you're posting in the right place.
  • Please read these before you post! —
  • Posts may use any of the Perl Monks Approved HTML tags:
    a, abbr, b, big, blockquote, br, caption, center, col, colgroup, dd, del, details, div, dl, dt, em, font, h1, h2, h3, h4, h5, h6, hr, i, ins, li, ol, p, pre, readmore, small, span, spoiler, strike, strong, sub, summary, sup, table, tbody, td, tfoot, th, thead, tr, tt, u, ul, wbr
  • You may need to use entities for some characters, as follows. (Exception: Within code tags, you can put the characters literally.)
            For:     Use:
    & &amp;
    < &lt;
    > &gt;
    [ &#91;
    ] &#93;
  • Link using PerlMonks shortcuts! What shortcuts can I use for linking?
  • See Writeup Formatting Tips and other pages linked from there for more info.