Uploaded image for project: 'Nutch'
  1. Nutch
  2. NUTCH-2253

ProtocolFactory still not thread-safe

    XMLWordPrintableJSON

Details

    • Bug
    • Status: Closed
    • Major
    • Resolution: Duplicate
    • 1.10, 1.11
    • 1.16
    • fetcher
    • None

    Description

      Hi, as I can see in 1.11 release, ProtocolFactory class still has an issue in getProtocol method. This is because every fetcher thread has its own ProtocolFactory instance (this.protocolFactory = new ProtocolFactory(conf); in FetcherThread constructor.)
      So have this method synchronized is useless, because each thread has its own monitor.
      In our project we have issue of having multiple Protocol instances.
      Issue can be fixed if getProtocol method will use shared conf instance as lock object or by having one ProtocolFactory for all fetcher threads.

      Attachments

        Issue Links

          Activity

            People

              Unassigned Unassigned
              l.misakyan@gmail.com Leon Misakyan
              Votes:
              0 Vote for this issue
              Watchers:
              2 Start watching this issue

              Dates

                Created:
                Updated:
                Resolved: