首页 \ 问答 \ HTTP状态码(HTTP status code)

HTTP状态码(HTTP status code)

如何从HttpStatusCode的对象(在ASP.NET中)获取HTTP状态代码ID例如,我得到“HttpStatusCode.NotFound”我想获得错误代码404。


How to get HTTP status code id from object of HttpStatusCode (in ASP.NET? For example I get "HttpStatusCode.NotFound" I would like get error code 404.


原文:https://stackoverflow.com/questions/9328237
更新时间:2022-03-17 17:03

最满意答案

好吧,我使用命令deletetable -f -p Test.*删除了所有表。 这将删除前缀为“Test”的所有表。 简而言之,我们可以编写一个脚本来删除所有表。

要从accumulo中删除所有hadoop文件,请按照以下步骤操作:

  1. 停止累积
  2. 运行$ hdfs dfs -rm -R -skipTrash hdfs://localhost:9000/accumulo 。 其中hdfs://localhost:9000/accumulo是accumulo数据的路径。
  3. 重新运行$ accumulo init
  4. 启动Accumulo $ ./bin/start-all.sh

Well, I deleted all the tables using command deletetable -f -p Test.*. Which will delete all tables with prefix "Test". In short we can write a script to delete all tables.

To remove all the hadoop files from accumulo, follow the steps:

  1. Stop accumulo
  2. Run$ hdfs dfs -rm -R -skipTrash hdfs://localhost:9000/accumulo. Where hdfs://localhost:9000/accumulo is path to accumulo data.
  3. Re-run $ accumulo init.
  4. Start Accumulo $ ./bin/start-all.sh.

相关问答

更多
  • 它应该像进入bin目录并运行适当的标记脚本一样简单。 cd accumulo-1.7.0/bin ./stop-all.sh 然后重新开始: ./start-all.sh Thanks for the help, the problem was that i need set the directory where the snapshot is stored for zookeeper, because by default it is stored in "/tmp". I modify file ...
  • 提供的AccumuloInputFormat和AccumuloOutputFormat有一种方法,可以使用Accumulo*putFormat.setConnectorInfo(job, principle, token)在作业配置中设置Accumulo*putFormat.setConnectorInfo(job, principle, token) 。 您还可以使用AuthenticationTokenSerializer在HDFS中的文件中序列化令牌,并使用接受文件名的setConnectorInfo ...
  • 正如@FuriousGeorge建议的那样,我调查了Apache Spark。 这确实提供了一种在不使用临时文件的情况下执行kmeans聚类的方法,如下所示: import org.apache.accumulo.core.client.mapreduce.AccumuloInputFormat; import org.apache.accumulo.core.data.Key; import org.apache.accumulo.core.data.Value; import org.apache.ac ...
  • 如果我知道我想要人员表中的所有对象,是否有更快的方法来只查询该表? 如果您要阅读所有人,那么使用索引是没有意义的。 只需扫描您的人员表。 如果您只想在每个人身上使用某些属性,则可以在Scanner / BatchScanner上使用fetchColumn(Text, Text)方法。 当键改变时,你知道你在下一个对象上 如果您只处理每一行,可以尝试使用WholeRowIterator。 If I know I am going to want all objects in the person table, ...
  • 当执行新的Mutation单元格序列化Mutation时,它看起来像spark-notebook中发生的一切。 序列化后,你不能调用变种。 我会尝试将mutation.put调用添加到与新Mutation命令相同的笔记本单元格中。 看起来clientRqrdTble / bwConfig / batchWriter命令位于单个多行单元格中,所以希望这也可以用于Mutation。 so it seems as though the code that works perfectly well with jav ...
  • 截至撰写本文时的最新版本(1.8.1),对表名的长度没有硬编码限制。 这可能(也可能最终)在未来版本中发生变化。 过大的表名可能会假想地导致内部数据结构的性能问题或内存不足错误。 我建议让它们保持一个合理的长度,因为这些名字的目的是为了人类可读。 任何大于50个字符的字符对我来说似乎都是过分的,但高于这个数量级可能不会引起明显的问题。 As of the latest version at the time of this writing (1.8.1), there is no hard-coded li ...
  • 这与前一个答案所说的相同,但我认为显示一行代码可能会有所帮助。 如果你有一个巧妙命名为“scanner”的扫描仪,你可以使用setRange()方法设置扫描仪的范围。 因为默认范围是(-inf,+ inf),所以传递setRange新创建的范围对象将为扫描仪提供一系列(-inf,+ inf)扫描整个表的能力。 示例代码如下所示: scanner.setRange(new Range()); This is the same thing that the previous answer is saying, ...
  • 好吧,我使用命令deletetable -f -p Test.*删除了所有表。 这将删除前缀为“Test”的所有表。 简而言之,我们可以编写一个脚本来删除所有表。 要从accumulo中删除所有hadoop文件,请按照以下步骤操作: 停止累积 运行$ hdfs dfs -rm -R -skipTrash hdfs://localhost:9000/accumulo 。 其中hdfs://localhost:9000/accumulo是accumulo数据的路径。 重新运行$ accumulo init 。 ...
  • 通过手动应用此补丁,我能够使Accumulo监视器绑定到所有网络接口: https ://git-wip-us.apache.org/repos/asf?p = accumulo.git; a = commit; h = 7655de68 在conf/accumulo-env.sh添加: # Should the monitor bind to all network interfaces -- default: false export ACCUMULO_MONITOR_BIND_ALL="true" ...
  • Apache Accumulo基于Google BigTable论文,与Apache HBase有许多相似之处。 所有这三个系统都是CP,其中节点将简单地下降而不是提供不一致的数据。 Apache Accumulo is based on the Google BigTable paper, and shares a lot of similarities with Apache HBase. All three of these systems are intended to be CP, where n ...

相关文章

更多

最新问答

更多
  • 获取MVC 4使用的DisplayMode后缀(Get the DisplayMode Suffix being used by MVC 4)
  • 如何通过引用返回对象?(How is returning an object by reference possible?)
  • 矩阵如何存储在内存中?(How are matrices stored in memory?)
  • 每个请求的Java新会话?(Java New Session For Each Request?)
  • css:浮动div中重叠的标题h1(css: overlapping headlines h1 in floated divs)
  • 无论图像如何,Caffe预测同一类(Caffe predicts same class regardless of image)
  • xcode语法颜色编码解释?(xcode syntax color coding explained?)
  • 在Access 2010 Runtime中使用Office 2000校对工具(Use Office 2000 proofing tools in Access 2010 Runtime)
  • 从单独的Web主机将图像传输到服务器上(Getting images onto server from separate web host)
  • 从旧版本复制文件并保留它们(旧/新版本)(Copy a file from old revision and keep both of them (old / new revision))
  • 西安哪有PLC可控制编程的培训
  • 在Entity Framework中选择基类(Select base class in Entity Framework)
  • 在Android中出现错误“数据集和渲染器应该不为null,并且应该具有相同数量的系列”(Error “Dataset and renderer should be not null and should have the same number of series” in Android)
  • 电脑二级VF有什么用
  • Datamapper Ruby如何添加Hook方法(Datamapper Ruby How to add Hook Method)
  • 金华英语角.
  • 手机软件如何制作
  • 用于Android webview中图像保存的上下文菜单(Context Menu for Image Saving in an Android webview)
  • 注意:未定义的偏移量:PHP(Notice: Undefined offset: PHP)
  • 如何读R中的大数据集[复制](How to read large dataset in R [duplicate])
  • Unity 5 Heighmap与地形宽度/地形长度的分辨率关系?(Unity 5 Heighmap Resolution relationship to terrain width / terrain length?)
  • 如何通知PipedOutputStream线程写入最后一个字节的PipedInputStream线程?(How to notify PipedInputStream thread that PipedOutputStream thread has written last byte?)
  • python的访问器方法有哪些
  • DeviceNetworkInformation:哪个是哪个?(DeviceNetworkInformation: Which is which?)
  • 在Ruby中对组合进行排序(Sorting a combination in Ruby)
  • 网站开发的流程?
  • 使用Zend Framework 2中的JOIN sql检索数据(Retrieve data using JOIN sql in Zend Framework 2)
  • 条带格式类型格式模式编号无法正常工作(Stripes format type format pattern number not working properly)
  • 透明度错误IE11(Transparency bug IE11)
  • linux的基本操作命令。。。