当前位置: 首页>>代码示例>>Java>>正文


Java BufferSizeParam类代码示例

本文整理汇总了Java中org.apache.hadoop.hdfs.web.resources.BufferSizeParam的典型用法代码示例。如果您正苦于以下问题:Java BufferSizeParam类的具体用法?Java BufferSizeParam怎么用?Java BufferSizeParam使用的例子?那么, 这里精选的类代码示例或许可以为您提供帮助。


BufferSizeParam类属于org.apache.hadoop.hdfs.web.resources包,在下文中一共展示了BufferSizeParam类的15个代码示例,这些例子默认根据受欢迎程度排序。您可以为喜欢或者感觉有用的代码点赞,您的评价将有助于系统推荐出更棒的Java代码示例。

示例1: postRoot

import org.apache.hadoop.hdfs.web.resources.BufferSizeParam; //导入依赖的package包/类
/** Handle HTTP POST request for the root for the root. */
@POST
@Path("/")
@Consumes({"*/*"})
@Produces({MediaType.APPLICATION_OCTET_STREAM, MediaType.APPLICATION_JSON})
public Response postRoot(
    final InputStream in,
    @Context final UserGroupInformation ugi,
    @QueryParam(DelegationParam.NAME) @DefaultValue(DelegationParam.DEFAULT)
        final DelegationParam delegation,
    @QueryParam(NamenodeAddressParam.NAME)
    @DefaultValue(NamenodeAddressParam.DEFAULT)
        final NamenodeAddressParam namenode,
    @QueryParam(PostOpParam.NAME) @DefaultValue(PostOpParam.DEFAULT)
        final PostOpParam op,
    @QueryParam(BufferSizeParam.NAME) @DefaultValue(BufferSizeParam.DEFAULT)
        final BufferSizeParam bufferSize
    ) throws IOException, InterruptedException {
  return post(in, ugi, delegation, namenode, ROOT, op, bufferSize);
}
 
开发者ID:Nextzero,项目名称:hadoop-2.6.0-cdh5.4.3,代码行数:21,代码来源:DatanodeWebHdfsMethods.java

示例2: getRoot

import org.apache.hadoop.hdfs.web.resources.BufferSizeParam; //导入依赖的package包/类
/** Handle HTTP GET request for the root. */
@GET
@Path("/")
@Produces({MediaType.APPLICATION_OCTET_STREAM, MediaType.APPLICATION_JSON})
public Response getRoot(
    @Context final UserGroupInformation ugi,
    @QueryParam(DelegationParam.NAME) @DefaultValue(DelegationParam.DEFAULT)
        final DelegationParam delegation,
    @QueryParam(NamenodeAddressParam.NAME)
    @DefaultValue(NamenodeAddressParam.DEFAULT)
        final NamenodeAddressParam namenode,
    @QueryParam(GetOpParam.NAME) @DefaultValue(GetOpParam.DEFAULT)
        final GetOpParam op,
    @QueryParam(OffsetParam.NAME) @DefaultValue(OffsetParam.DEFAULT)
        final OffsetParam offset,
    @QueryParam(LengthParam.NAME) @DefaultValue(LengthParam.DEFAULT)
        final LengthParam length,
    @QueryParam(BufferSizeParam.NAME) @DefaultValue(BufferSizeParam.DEFAULT)
        final BufferSizeParam bufferSize
    ) throws IOException, InterruptedException {
  return get(ugi, delegation, namenode, ROOT, op, offset, length,
      bufferSize);
}
 
开发者ID:Nextzero,项目名称:hadoop-2.6.0-cdh5.4.3,代码行数:24,代码来源:DatanodeWebHdfsMethods.java

示例3: create

import org.apache.hadoop.hdfs.web.resources.BufferSizeParam; //导入依赖的package包/类
@Override
public FSDataOutputStream create(final Path f, final FsPermission permission,
    final boolean overwrite, final int bufferSize, final short replication,
    final long blockSize, final Progressable progress) throws IOException {
  statistics.incrementWriteOps(1);

  final HttpOpParam.Op op = PutOpParam.Op.CREATE;
  return new Runner(op, f, 
      new PermissionParam(applyUMask(permission)),
      new OverwriteParam(overwrite),
      new BufferSizeParam(bufferSize),
      new ReplicationParam(replication),
      new BlockSizeParam(blockSize))
    .run()
    .write(bufferSize);
}
 
开发者ID:ict-carch,项目名称:hadoop-plus,代码行数:17,代码来源:WebHdfsFileSystem.java

示例4: postRoot

import org.apache.hadoop.hdfs.web.resources.BufferSizeParam; //导入依赖的package包/类
/** Handle HTTP POST request for the root. */
@POST
@Path("/")
@Consumes({"*/*"})
@Produces({MediaType.APPLICATION_OCTET_STREAM, MediaType.APPLICATION_JSON})
public Response postRoot(
    @Context final UserGroupInformation ugi,
    @QueryParam(DelegationParam.NAME) @DefaultValue(DelegationParam.DEFAULT)
        final DelegationParam delegation,
    @QueryParam(UserParam.NAME) @DefaultValue(UserParam.DEFAULT)
        final UserParam username,
    @QueryParam(DoAsParam.NAME) @DefaultValue(DoAsParam.DEFAULT)
        final DoAsParam doAsUser,
    @QueryParam(PostOpParam.NAME) @DefaultValue(PostOpParam.DEFAULT)
        final PostOpParam op,
    @QueryParam(ConcatSourcesParam.NAME) @DefaultValue(ConcatSourcesParam.DEFAULT)
        final ConcatSourcesParam concatSrcs,
    @QueryParam(BufferSizeParam.NAME) @DefaultValue(BufferSizeParam.DEFAULT)
        final BufferSizeParam bufferSize
    ) throws IOException, InterruptedException {
  return post(ugi, delegation, username, doAsUser, ROOT, op, concatSrcs, bufferSize);
}
 
开发者ID:ict-carch,项目名称:hadoop-plus,代码行数:23,代码来源:NamenodeWebHdfsMethods.java

示例5: getRoot

import org.apache.hadoop.hdfs.web.resources.BufferSizeParam; //导入依赖的package包/类
/** Handle HTTP GET request for the root. */
@GET
@Path("/")
@Produces({MediaType.APPLICATION_OCTET_STREAM, MediaType.APPLICATION_JSON})
public Response getRoot(
    @Context final UserGroupInformation ugi,
    @QueryParam(DelegationParam.NAME) @DefaultValue(DelegationParam.DEFAULT)
        final DelegationParam delegation,
    @QueryParam(UserParam.NAME) @DefaultValue(UserParam.DEFAULT)
        final UserParam username,
    @QueryParam(DoAsParam.NAME) @DefaultValue(DoAsParam.DEFAULT)
        final DoAsParam doAsUser,
    @QueryParam(GetOpParam.NAME) @DefaultValue(GetOpParam.DEFAULT)
        final GetOpParam op,
    @QueryParam(OffsetParam.NAME) @DefaultValue(OffsetParam.DEFAULT)
        final OffsetParam offset,
    @QueryParam(LengthParam.NAME) @DefaultValue(LengthParam.DEFAULT)
        final LengthParam length,
    @QueryParam(RenewerParam.NAME) @DefaultValue(RenewerParam.DEFAULT)
        final RenewerParam renewer,
    @QueryParam(BufferSizeParam.NAME) @DefaultValue(BufferSizeParam.DEFAULT)
        final BufferSizeParam bufferSize
    ) throws IOException, InterruptedException {
  return get(ugi, delegation, username, doAsUser, ROOT, op,
      offset, length, renewer, bufferSize);
}
 
开发者ID:ict-carch,项目名称:hadoop-plus,代码行数:27,代码来源:NamenodeWebHdfsMethods.java

示例6: postRoot

import org.apache.hadoop.hdfs.web.resources.BufferSizeParam; //导入依赖的package包/类
/** Handle HTTP POST request for the root for the root. */
@POST
@Path("/")
@Consumes({"*/*"})
@Produces({MediaType.APPLICATION_OCTET_STREAM, MediaType.APPLICATION_JSON})
public Response postRoot(
    final InputStream in,
    @Context final UserGroupInformation ugi,
    @QueryParam(DelegationParam.NAME) @DefaultValue(DelegationParam.DEFAULT)
        final DelegationParam delegation,
    @QueryParam(NamenodeRpcAddressParam.NAME)
    @DefaultValue(NamenodeRpcAddressParam.DEFAULT)
        final NamenodeRpcAddressParam namenodeRpcAddress,
    @QueryParam(PostOpParam.NAME) @DefaultValue(PostOpParam.DEFAULT)
        final PostOpParam op,
    @QueryParam(BufferSizeParam.NAME) @DefaultValue(BufferSizeParam.DEFAULT)
        final BufferSizeParam bufferSize
    ) throws IOException, InterruptedException {
  return post(in, ugi, delegation, namenodeRpcAddress, ROOT, op, bufferSize);
}
 
开发者ID:ict-carch,项目名称:hadoop-plus,代码行数:21,代码来源:DatanodeWebHdfsMethods.java

示例7: getRoot

import org.apache.hadoop.hdfs.web.resources.BufferSizeParam; //导入依赖的package包/类
/** Handle HTTP GET request for the root. */
@GET
@Path("/")
@Produces({MediaType.APPLICATION_OCTET_STREAM, MediaType.APPLICATION_JSON})
public Response getRoot(
    @Context final UserGroupInformation ugi,
    @QueryParam(DelegationParam.NAME) @DefaultValue(DelegationParam.DEFAULT)
        final DelegationParam delegation,
    @QueryParam(NamenodeRpcAddressParam.NAME)
    @DefaultValue(NamenodeRpcAddressParam.DEFAULT)
        final NamenodeRpcAddressParam namenodeRpcAddress,
    @QueryParam(GetOpParam.NAME) @DefaultValue(GetOpParam.DEFAULT)
        final GetOpParam op,
    @QueryParam(OffsetParam.NAME) @DefaultValue(OffsetParam.DEFAULT)
        final OffsetParam offset,
    @QueryParam(LengthParam.NAME) @DefaultValue(LengthParam.DEFAULT)
        final LengthParam length,
    @QueryParam(BufferSizeParam.NAME) @DefaultValue(BufferSizeParam.DEFAULT)
        final BufferSizeParam bufferSize
    ) throws IOException, InterruptedException {
  return get(ugi, delegation, namenodeRpcAddress, ROOT, op, offset, length,
      bufferSize);
}
 
开发者ID:ict-carch,项目名称:hadoop-plus,代码行数:24,代码来源:DatanodeWebHdfsMethods.java

示例8: post

import org.apache.hadoop.hdfs.web.resources.BufferSizeParam; //导入依赖的package包/类
private Response post(final UserGroupInformation ugi,
    final DelegationParam delegation, final UserParam username,
    final DoAsParam doAsUser, final String fullpath, final PostOpParam op,
    final ConcatSourcesParam concatSrcs, final BufferSizeParam bufferSize)
    throws IOException, URISyntaxException {
  final NameNode namenode = (NameNode) context.getAttribute("name.node");

  switch (op.getValue()) {
    case APPEND: {
      final URI uri =
          redirectURI(namenode, ugi, delegation, username, doAsUser, fullpath,
              op.getValue(), -1L, -1L, bufferSize);
      return Response.temporaryRedirect(uri)
          .type(MediaType.APPLICATION_OCTET_STREAM).build();
    }
    case CONCAT: {
      namenode.getRpcServer().concat(fullpath, concatSrcs.getAbsolutePaths());
      return Response.ok().build();
    }
    default:
      throw new UnsupportedOperationException(op + " is not supported");
  }
}
 
开发者ID:hopshadoop,项目名称:hops,代码行数:24,代码来源:NamenodeWebHdfsMethods.java

示例9: postRoot

import org.apache.hadoop.hdfs.web.resources.BufferSizeParam; //导入依赖的package包/类
/**
 * Handle HTTP POST request for the root for the root.
 */
@POST
@Path("/")
@Consumes({"*/*"})
@Produces({MediaType.APPLICATION_OCTET_STREAM, MediaType.APPLICATION_JSON})
public Response postRoot(final InputStream in,
    @Context
    final UserGroupInformation ugi,
    @QueryParam(DelegationParam.NAME)
    @DefaultValue(DelegationParam.DEFAULT)
    final DelegationParam delegation,
    @QueryParam(NamenodeRpcAddressParam.NAME)
    @DefaultValue(NamenodeRpcAddressParam.DEFAULT)
    final NamenodeRpcAddressParam namenodeRpcAddress,
    @QueryParam(PostOpParam.NAME)
    @DefaultValue(PostOpParam.DEFAULT)
    final PostOpParam op,
    @QueryParam(BufferSizeParam.NAME)
    @DefaultValue(BufferSizeParam.DEFAULT)
    final BufferSizeParam bufferSize)
    throws IOException, InterruptedException {
  return post(in, ugi, delegation, namenodeRpcAddress, ROOT, op, bufferSize);
}
 
开发者ID:hopshadoop,项目名称:hops,代码行数:26,代码来源:DatanodeWebHdfsMethods.java

示例10: postRoot

import org.apache.hadoop.hdfs.web.resources.BufferSizeParam; //导入依赖的package包/类
/** Handle HTTP POST request for the root. */
@POST
@Path("/")
@Consumes({"*/*"})
@Produces({MediaType.APPLICATION_OCTET_STREAM, MediaType.APPLICATION_JSON})
public Response postRoot(
    @Context final UserGroupInformation ugi,
    @QueryParam(DelegationParam.NAME) @DefaultValue(DelegationParam.DEFAULT)
        final DelegationParam delegation,
    @QueryParam(UserParam.NAME) @DefaultValue(UserParam.DEFAULT)
        final UserParam username,
    @QueryParam(DoAsParam.NAME) @DefaultValue(DoAsParam.DEFAULT)
        final DoAsParam doAsUser,
    @QueryParam(PostOpParam.NAME) @DefaultValue(PostOpParam.DEFAULT)
        final PostOpParam op,
    @QueryParam(BufferSizeParam.NAME) @DefaultValue(BufferSizeParam.DEFAULT)
        final BufferSizeParam bufferSize
    ) throws IOException, InterruptedException {
  return post(ugi, delegation, username, doAsUser, ROOT, op, bufferSize);
}
 
开发者ID:Seagate,项目名称:hadoop-on-lustre,代码行数:21,代码来源:NamenodeWebHdfsMethods.java

示例11: getRoot

import org.apache.hadoop.hdfs.web.resources.BufferSizeParam; //导入依赖的package包/类
/** Handle HTTP GET request for the root. */
@GET
@Path("/")
@Produces({MediaType.APPLICATION_OCTET_STREAM, MediaType.APPLICATION_JSON})
public Response getRoot(
    @Context final UserGroupInformation ugi,
    @QueryParam(DelegationParam.NAME) @DefaultValue(DelegationParam.DEFAULT)
        final DelegationParam delegation,
    @QueryParam(UserParam.NAME) @DefaultValue(UserParam.DEFAULT)
        final UserParam username,
    @QueryParam(DoAsParam.NAME) @DefaultValue(DoAsParam.DEFAULT)
        final DoAsParam doAsUser,
    @QueryParam(GetOpParam.NAME) @DefaultValue(GetOpParam.DEFAULT)
        final GetOpParam op,
    @QueryParam(OffsetParam.NAME) @DefaultValue(OffsetParam.DEFAULT)
        final OffsetParam offset,
    @QueryParam(LengthParam.NAME) @DefaultValue(LengthParam.DEFAULT)
        final LengthParam length,
    @QueryParam(RenewerParam.NAME) @DefaultValue(RenewerParam.DEFAULT)
        final RenewerParam renewer,
    @QueryParam(BufferSizeParam.NAME) @DefaultValue(BufferSizeParam.DEFAULT)
        final BufferSizeParam bufferSize
    ) throws IOException, URISyntaxException, InterruptedException {
  return get(ugi, delegation, username, doAsUser, ROOT, op,
      offset, length, renewer, bufferSize);
}
 
开发者ID:Seagate,项目名称:hadoop-on-lustre,代码行数:27,代码来源:NamenodeWebHdfsMethods.java

示例12: putRoot

import org.apache.hadoop.hdfs.web.resources.BufferSizeParam; //导入依赖的package包/类
/** Handle HTTP PUT request for the root. */
@PUT
@Path("/")
@Consumes({"*/*"})
@Produces({MediaType.APPLICATION_OCTET_STREAM, MediaType.APPLICATION_JSON})
public Response putRoot(
    final InputStream in,
    @Context final UserGroupInformation ugi,
    @QueryParam(DelegationParam.NAME) @DefaultValue(DelegationParam.DEFAULT)
        final DelegationParam delegation,
    @QueryParam(PutOpParam.NAME) @DefaultValue(PutOpParam.DEFAULT)
        final PutOpParam op,
    @QueryParam(PermissionParam.NAME) @DefaultValue(PermissionParam.DEFAULT)
        final PermissionParam permission,
    @QueryParam(OverwriteParam.NAME) @DefaultValue(OverwriteParam.DEFAULT)
        final OverwriteParam overwrite,
    @QueryParam(BufferSizeParam.NAME) @DefaultValue(BufferSizeParam.DEFAULT)
        final BufferSizeParam bufferSize,
    @QueryParam(ReplicationParam.NAME) @DefaultValue(ReplicationParam.DEFAULT)
        final ReplicationParam replication,
    @QueryParam(BlockSizeParam.NAME) @DefaultValue(BlockSizeParam.DEFAULT)
        final BlockSizeParam blockSize
    ) throws IOException, InterruptedException {
  return put(in, ugi, delegation, ROOT, op, permission, overwrite, bufferSize,
      replication, blockSize);
}
 
开发者ID:Seagate,项目名称:hadoop-on-lustre,代码行数:27,代码来源:DatanodeWebHdfsMethods.java

示例13: postRoot

import org.apache.hadoop.hdfs.web.resources.BufferSizeParam; //导入依赖的package包/类
/** Handle HTTP POST request for the root for the root. */
@POST
@Path("/")
@Consumes({"*/*"})
@Produces({MediaType.APPLICATION_OCTET_STREAM, MediaType.APPLICATION_JSON})
public Response postRoot(
    final InputStream in,
    @Context final UserGroupInformation ugi,
    @QueryParam(DelegationParam.NAME) @DefaultValue(DelegationParam.DEFAULT)
        final DelegationParam delegation,
    @QueryParam(PostOpParam.NAME) @DefaultValue(PostOpParam.DEFAULT)
        final PostOpParam op,
    @QueryParam(BufferSizeParam.NAME) @DefaultValue(BufferSizeParam.DEFAULT)
        final BufferSizeParam bufferSize
    ) throws IOException, InterruptedException {
  return post(in, ugi, delegation, ROOT, op, bufferSize);
}
 
开发者ID:Seagate,项目名称:hadoop-on-lustre,代码行数:18,代码来源:DatanodeWebHdfsMethods.java

示例14: getRoot

import org.apache.hadoop.hdfs.web.resources.BufferSizeParam; //导入依赖的package包/类
/** Handle HTTP GET request for the root. */
@GET
@Path("/")
@Produces({MediaType.APPLICATION_OCTET_STREAM, MediaType.APPLICATION_JSON})
public Response getRoot(
    @Context final UserGroupInformation ugi,
    @QueryParam(DelegationParam.NAME) @DefaultValue(DelegationParam.DEFAULT)
        final DelegationParam delegation,
    @QueryParam(GetOpParam.NAME) @DefaultValue(GetOpParam.DEFAULT)
        final GetOpParam op,
    @QueryParam(OffsetParam.NAME) @DefaultValue(OffsetParam.DEFAULT)
        final OffsetParam offset,
    @QueryParam(LengthParam.NAME) @DefaultValue(LengthParam.DEFAULT)
        final LengthParam length,
    @QueryParam(BufferSizeParam.NAME) @DefaultValue(BufferSizeParam.DEFAULT)
        final BufferSizeParam bufferSize
    ) throws IOException, InterruptedException {
  return get(ugi, delegation, ROOT, op, offset, length, bufferSize); 
}
 
开发者ID:Seagate,项目名称:hadoop-on-lustre,代码行数:20,代码来源:DatanodeWebHdfsMethods.java

示例15: create

import org.apache.hadoop.hdfs.web.resources.BufferSizeParam; //导入依赖的package包/类
@Override
public FSDataOutputStream create(final Path f, final FsPermission permission,
    final boolean overwrite, final int bufferSize, final short replication,
    final long blockSize, final Progressable progress) throws IOException {
  statistics.incrementWriteOps(1);

  final HttpOpParam.Op op = PutOpParam.Op.CREATE;
  return new FsPathRunner(op, f,
      new PermissionParam(applyUMask(permission)),
      new OverwriteParam(overwrite),
      new BufferSizeParam(bufferSize),
      new ReplicationParam(replication),
      new BlockSizeParam(blockSize))
    .run()
    .write(bufferSize);
}
 
开发者ID:Seagate,项目名称:hadoop-on-lustre2,代码行数:17,代码来源:WebHdfsFileSystem.java


注:本文中的org.apache.hadoop.hdfs.web.resources.BufferSizeParam类示例由纯净天空整理自Github/MSDocs等开源代码及文档管理平台,相关代码片段筛选自各路编程大神贡献的开源项目,源码版权归原作者所有,传播和使用请参考对应项目的License;未经允许,请勿转载。