Loading ...
Sorry, an error occurred while loading the content.

Re: Can't locate object method "RequestRec", upgrade ?

Expand Messages
  • Stas Bekman
    ... eh? where is this code from? Should be: return DECLINED unless unless $r- is_initial_req ... You should do that in any case. 1.99_05 is a way too old and
    Message 1 of 5 , May 2 12:16 AM
    • 0 Attachment
      Addady wrote:
      > Hello,
      >
      > I'm trying to upgrade an old mod_perl module to v2.0 on RedHat 8.0 (apache
      > 2.0.40 mod_perl 1.99_05-3)
      >
      > It fail on:
      > Can't locate object method "RequestRec" via package ... line 41.
      >
      > === Some of the code :
      > use Apache::Connection;
      > use Apache::RequestRec;
      > use Apache::RequestUtil;
      > use Apache::Const qw(OK DECLINED);
      > use Apache::Log;
      > ...
      > sub handler : method {
      > my $r = shift;
      > return DECLINED unless $r->RequestRec->is_initial_req; # <== line 41

      eh? where is this code from?

      Should be:

      return DECLINED unless unless $r->is_initial_req

      > ===
      >
      > I read in previous posts that RequestRec was not fully implemented.
      > Should I upgrade to the latest mod_perl 1.99_09 or csv ?

      You should do that in any case. 1.99_05 is a way too old and so many things
      have changed since that version was released.

      > If I need/want to upgrade what to set as MP_AP_PREFIX ?
      >
      >>perl Makefile.PL MP_AP_PREFIX=/usr/local/apache2

      if that's where you apache is, that's correct.

      > I'm using the binary installation of apache came with RedHat 8.0


      --


      __________________________________________________________________
      Stas Bekman JAm_pH ------> Just Another mod_perl Hacker
      http://stason.org/ mod_perl Guide ---> http://perl.apache.org
      mailto:stas@... http://use.perl.org http://apacheweek.com
      http://modperlbook.org http://apache.org http://ticketmaster.com
    • Addady
      Hello, I m trying to upgrade an old mod_perl module to v2.0 on RedHat 8.0 (apache 2.0.40 mod_perl 1.99_05-3) It fail on: Can t locate object method
      Message 2 of 5 , May 2 1:06 AM
      • 0 Attachment
        Hello,

        I'm trying to upgrade an old mod_perl module to v2.0 on RedHat 8.0 (apache
        2.0.40 mod_perl 1.99_05-3)

        It fail on:
        Can't locate object method "RequestRec" via package ... line 41.

        === Some of the code :
        use Apache::Connection;
        use Apache::RequestRec;
        use Apache::RequestUtil;
        use Apache::Const qw(OK DECLINED);
        use Apache::Log;
        ...
        sub handler : method {
        my $r = shift;
        return DECLINED unless $r->RequestRec->is_initial_req; # <== line 41
        ...
        ===

        I read in previous posts that RequestRec was not fully implemented.
        Should I upgrade to the latest mod_perl 1.99_09 or csv ?

        If I need/want to upgrade what to set as MP_AP_PREFIX ?
        >perl Makefile.PL MP_AP_PREFIX=/usr/local/apache2
        I'm using the binary installation of apache came with RedHat 8.0

        thanks,
        addady
      • Addady
        ... I m using the binary installation of apache came with RedHat 8.0, I don t know where should I point MP_AP_PREFIX ? Addady ... From: Stas Bekman
        Message 3 of 5 , May 2 2:14 AM
        • 0 Attachment
          >> If I need/want to upgrade what to set as MP_AP_PREFIX ?
          >>>perl Makefile.PL MP_AP_PREFIX=/usr/local/apache2
          >
          >if that's where you apache is, that's correct.

          I'm using the binary installation of apache came with RedHat 8.0,
          I don't know where should I point MP_AP_PREFIX ?

          Addady





          ----- Original Message -----
          From: "Stas Bekman" <stas@...>
          To: "Addady" <addady@...>
          Cc: <modperl@...>
          Sent: Friday, May 02, 2003 9:16 AM
          Subject: Re: Can't locate object method "RequestRec", upgrade ?


          > Addady wrote:
          > > Hello,
          > >
          > > I'm trying to upgrade an old mod_perl module to v2.0 on RedHat 8.0
          (apache
          > > 2.0.40 mod_perl 1.99_05-3)
          > >
          > > It fail on:
          > > Can't locate object method "RequestRec" via package ... line 41.
          > >
          > > === Some of the code :
          > > use Apache::Connection;
          > > use Apache::RequestRec;
          > > use Apache::RequestUtil;
          > > use Apache::Const qw(OK DECLINED);
          > > use Apache::Log;
          > > ...
          > > sub handler : method {
          > > my $r = shift;
          > > return DECLINED unless $r->RequestRec->is_initial_req; # <== line 41
          >
          > eh? where is this code from?
          >
          > Should be:
          >
          > return DECLINED unless unless $r->is_initial_req
          >
          > > ===
          > >
          > > I read in previous posts that RequestRec was not fully implemented.
          > > Should I upgrade to the latest mod_perl 1.99_09 or csv ?
          >
          > You should do that in any case. 1.99_05 is a way too old and so many
          things
          > have changed since that version was released.
          >
          > > If I need/want to upgrade what to set as MP_AP_PREFIX ?
          > >
          > >>perl Makefile.PL MP_AP_PREFIX=/usr/local/apache2
          >
          > if that's where you apache is, that's correct.
          >
          > > I'm using the binary installation of apache came with RedHat 8.0
          >
          >
          > --
          >
          >
          > __________________________________________________________________
          > Stas Bekman JAm_pH ------> Just Another mod_perl Hacker
          > http://stason.org/ mod_perl Guide ---> http://perl.apache.org
          > mailto:stas@... http://use.perl.org http://apacheweek.com
          > http://modperlbook.org http://apache.org http://ticketmaster.com
          >
        • Ged Haywood
          Hi there, ... which httpd might be safer. 73, Ged.
          Message 4 of 5 , May 2 11:43 AM
          • 0 Attachment
            Hi there,

            On Fri, 2 May 2003, Marc M. Adkins wrote:

            > For the binary you might try (if I recall properly):
            >
            > whereis httpd

            which httpd

            might be safer.

            73,
            Ged.
          • Marc M. Adkins
            ... Having not built mod_perl I m not sure what MP_AP_PREFIX is supposed to be, whether it s the location of the binary, library, or source directory. If I
            Message 5 of 5 , May 2 11:56 AM
            • 0 Attachment
              > >> If I need/want to upgrade what to set as MP_AP_PREFIX ?
              > >>>perl Makefile.PL MP_AP_PREFIX=/usr/local/apache2
              > >
              > >if that's where you apache is, that's correct.
              >
              > I'm using the binary installation of apache came with RedHat 8.0,
              > I don't know where should I point MP_AP_PREFIX ?

              Having not built mod_perl I'm not sure what MP_AP_PREFIX is supposed to be,
              whether it's the location of the binary, library, or source directory.

              If I recall properly, many Apache installations have an installation
              directory that contains all of the above, a symbolic link from
              /usr/bin/httpd (or something like that) to the binary in the installation
              directory, and some configuration files somewhere under /etc. You're
              probably looking for the installation directory, but that's just a guess.

              For the binary you might try (if I recall properly):

              whereis httpd

              For everything else, there's always the arcane:

              find / -name 'apache*' -print

              which will search your entire hard disk and (probably) find your
              source/library/configuration directories.

              YMMV and I'm working mostly on W2K these days so I might be wa-a-ay off
              here.

              mma
            Your message has been successfully submitted and would be delivered to recipients shortly.