Re: I want to publish my PHP Extension in PECL
| From: | Ferenc Kovacs | Date: | Fri, 08 Aug 2014 14:47:04 +0000 |
| Subject: | Re: I want to publish my PHP Extension in PECL | ||
| References: | 1 2 3 4 5 6 7 | Groups: | php.pecl.dev |
| Request: | Send a blank email to pecl-dev+get-12157@lists.php.net to get a copy of this message | ||
On Fri, Aug 8, 2014 at 3:14 PM, China 陈毓端 <83868008@qq.com> wrote:
> > Are you sure about that? Or do you refer to "libhdfs can be used in
> > threaded applications using the Posix Threads" from their doc? Which
> > means something different (libhdfs is thread safe, given that the
> > global functions are called correctly.).
>
>
>
>
>
>
> libdhfs is thread safe.
>
>
> Concurrency and Hadoop FS "handles"
> The Hadoop FS implementation includes a FS handle cache which caches based
> on the URI of the namenode along with the user connecting. So, all calls to
> hdfsConnect will return the same handle but calls to hdfsConnectAsUser with
> different users will return different handles. But, since HDFS client
> handles are completely thread safe, this has no bearing on concurrency.
>
>
> Concurrency and libhdfs/JNI
> The libhdfs calls to JNI should always be creating thread local storage,
> so (in theory), libhdfs should be as thread safe as the underlying calls to
> the Hadoop FS.
>
>
>
> '.~Ic9É
> øÌ�,}„http://hadoop.apache.org/docs/r2.2.0/hadoop-project-dist/hadoop-hdfs/LibHdfs.html
>
libhdfs being thread-safe means that it can be used in ZTS builds(without
problems) not that it can only be used in ZTS builds.
--
Ferenc Kovács
@Tyr43l - http://tyrael.hu