首页 文章 精选 留言 我的

精选列表

搜索[网站开发],共10000篇文章
优秀的个人博客,低调大师

Chrome开发者工具里的一个隐藏技能:chrome://net-internals

During my holiday I was writing a small tool for fun, which extracts my personal posts from http://www.baidu.com for further analysis.I am using AJAX in jQuery to perform a synchronous call to fetch html source code of given url specified by argument requestURL.、 function getPostByAJAX(requestURL){ var html = $.ajax({ url: requestURL, async: false}).responseText; return html; } The requestURL I am using is http://tieba.baidu.com/i/i/my_tie However when I try to access it via my JavaScript code above, it failed.And Chrome development tool didn’t give me enough information for trouble shooting. How to deal with this issue then? Then I found the useful tool from Google: chrome://net-internalsNow let’s continue to trouble shoot with this tool. (1) type chrome://net-internals in Chrome address bar, press enter key.Then click Event hyperlink. (2) Go to my own html page which will send AJAX request via jQuery, click F5 to send a new request, then go back to Chrome tool.Now I have found the trace entry for the sent request.Here below is the request detail which contains much more information compared with the one in Chrome development Tool-Network tab. And here below are response header fields: The return code 302 and location “http://static.tieba.baidu.com/tb/error.html?ErrType=1” give me a reminder that this issue might be related to logon state of BAIDU website, since I would like to return my personal information, it makes sense that the url can only return personal data if cookie is available or user credential is specified ( not supported by BAIDU in this case ).In order to verify my assumption, I request the url directly in Chrome and check its request header fields this time, and yes, the cookie field is there: So now the question is, how to send my cookie information together with the AJAX call in JavaScript code?I found this article from Google.According to the article, I add the following code in my function: And it works now: By the way, via this tool I can also figure out how the jQuery library file jquery1.7.1.js stored in local laptop is loaded by Chrome.Chrome reads this file by chunks with size 32768 ( the file consists of 8 chunks ). The total size 251661 matches exactly with the number I see in windows, perfect isn’t it? Further reading For more tips I gained during my daily work about Chrome development tools, please refer to this blog Chrome Development Tool tips used in my daily work. 本文来自云栖社区合作伙伴“汪子熙”,了解相关信息可以关注微信公众号"汪子熙"。

优秀的个人博客,低调大师

Atlas(元数据管理)从扫盲到和Hive、HBase、Kafka、Flink等集成开发

先对数据分个类 企业数据管理的内容及范畴通常包括交易数据、主数据以及元数据。(1)交易数据:用于纪录业务事件,如客户的订单,投诉记录,客服申请等,它往往用于描述在某一个时间点上业务系统发生的行为。(2)主数据:主数据则定义企业核心业务对象,如客户、产品、地址等,与交易流水信息不同,主数据一旦被记录到数据库中,需要经常对其进行维护,从而确保其时效性和准确性;主数据还包括关系数据,用以描述主数据之间的关系,如客户与产品的关系、产品与地域的关系、客户与客户的关系、产品与产品的关系等。(3)元数据:即关于数据的数据,用以描述数据及其环境的结构化信息,便于查找、理解、使用和管理数据。 什么是元数据管理 我们前面讲解的技术和平台都在解决主数据和交易数据的采集、加工、存储、计算等问题。但面对海量且持续增加的各式各样的数据时,你一定想知道数据从哪里来以及它如何随时间而变化?采用Hadoop必须考虑数据管理的实际情况,元数据与数据治理成为企业级数据湖的重要部分。所谓元数据管理其实通俗来讲就两点:(1)把各个组件(一般是存储)的元数据收集起来统一管控(2)利用这些收集的元数据去实现各种上层应用以满足各种数据治理场景(数组资产目录、数据分类、搜索与血缘等等) Atlas是什么 Apache Atlas是Hadoop社区为解决Hadoop生态系统的元数据治理问题而产生的开源项目,它为Hadoop集群提供了包括 数据分类、集中策略引擎、数据血缘、安全和生命周期管理在内的元数据治理核心能力。可以帮助企业构建其数据资产目录,对这些资产进行分类和管理,并为数据分析师和数据治理团队,提供围绕这些数据资产的协作功能。Atlas不尽致力于管理共享元数据、数据分级、审计、安全性以及数据保护等方面,同时努力与Apache Ranger整合,用于数据权限控制策略。Apache Atlas是hadoop的数据治理和元数据框架,它提供了一个可伸缩和可扩展的核心基础数据治理服务集,使得 企业可以有效的和高效的满足Hadoop中的合规性要求,并允许与整个企业的数据生态系统集成。 Atlas架构与原理 Atlas 是一个可伸缩且功能丰富的数据管理系统,深度集成了 Hadoop 大数据组件。简单理解就是一个跟 Hadoop 关系紧密的,可以用来做元数据管理的一个系统,整个结构 图如下所示: Atlas核心功能分层及说明 集成Hive 集成原理 验证Hive元数据采集效果 (1)先查看Atlas里是否有Hive元数据(2)进入Hive创建一个库表create database if not exists foo;(3)再次进入Atlas查看元数据 历史元数据处理 在上线Atlas之前Hive可能运行很久了,所以历史上的元数据无法触发hook,因此需要一个工具来做初始化导入。Apache Atlas提供了一个命令行脚本 import-hive.sh ,用于将Apache Hive数据库和表的元数据导入Apache Atlas。该脚本可用于使用Apache Hive中的数据库/表初始化Apache Atlas。此脚本支持导入特定表的元数据,特定数据库中的表或所有数据库和表。导入工具调用的是对应的Bridge:org.apache.atlas.hive.bridge.HiveMetaStoreBridge执行导入脚本任意找一台安装过Atlas client的节点,执行如下命令:注意:一定要进入atlas用户,因为Atlas的Linux管理账户是atlas,其他账户下可能会报没有权限的错误。脚本执行过程中会要求输入Atlas的管理员账号/密码(admin/admin%123),看到如下信息就成功了: 查看元数据

资源下载

更多资源
腾讯云软件源

腾讯云软件源

为解决软件依赖安装时官方源访问速度慢的问题,腾讯云为一些软件搭建了缓存服务。您可以通过使用腾讯云软件源站来提升依赖包的安装速度。为了方便用户自由搭建服务架构,目前腾讯云软件源站支持公网访问和内网访问。

Spring

Spring

Spring框架(Spring Framework)是由Rod Johnson于2002年提出的开源Java企业级应用框架,旨在通过使用JavaBean替代传统EJB实现方式降低企业级编程开发的复杂性。该框架基于简单性、可测试性和松耦合性设计理念,提供核心容器、应用上下文、数据访问集成等模块,支持整合Hibernate、Struts等第三方框架,其适用范围不仅限于服务器端开发,绝大多数Java应用均可从中受益。

Sublime Text

Sublime Text

Sublime Text具有漂亮的用户界面和强大的功能,例如代码缩略图,Python的插件,代码段等。还可自定义键绑定,菜单和工具栏。Sublime Text 的主要功能包括:拼写检查,书签,完整的 Python API , Goto 功能,即时项目切换,多选择,多窗口等等。Sublime Text 是一个跨平台的编辑器,同时支持Windows、Linux、Mac OS X等操作系统。

WebStorm

WebStorm

WebStorm 是jetbrains公司旗下一款JavaScript 开发工具。目前已经被广大中国JS开发者誉为“Web前端开发神器”、“最强大的HTML5编辑器”、“最智能的JavaScript IDE”等。与IntelliJ IDEA同源,继承了IntelliJ IDEA强大的JS部分的功能。

用户登录
用户注册