学不来了阿阿阿

<!DOCTYPE html>
<html lang="en">
<head>
    <meta charset="UTF-8">
    <meta name="viewport" content="width=device-width, initial-scale=1.0">
    <title>登录</title>
    <style>
        * {
            margin: 0;
            padding: 0;
        }

        html, body {
            height: 100%;
            height: 100%;
        }

        body {
            background-image: url('../static/beijing.jpg');
            background-size: cover; /* 设置背景图片大小 */
            background-repeat: no-repeat; /* 设置背景图片不重复 */
        }

        .login {
            width: 358px;
            height: 588px;
            border-radius: 15px;
            padding: 0 50px;
            position: absolute;
            left: 75%;
            top: 50%;
            transform: translate(-50%, -50%);
            background-color: #282c34;
        }

        .header {
            font-size: 80px;
            font-weight: bold;
            text-align: center;
            line-height: 200px;
            color: #61d7fb;
            font-family: 'Helvetica', cursive; /* 将字体设置为艺术字体 */
        }

        .container {
            height: 30px;
            width: 250px;
            position: absolute;
            left: 50%;
            top: 40%;
            transform: translate(-50%, -50%);
        }

        input {
            width: 100%;
            height: 100%;
            position: relative;
            outline: none;
            border: none;
            box-sizing: border-box;
            padding-left: 5px;
            background-color: #282c34;
            color: #61dafb;
            caret-color: #61dafb;
        }

        input::placeholder {
            color: #61dafb;
        }

        span {
            position: absolute;
            content: "";
            display: block;
            background-color: #61dafb;
            transition: transform .1s ease-in-out;
        }

        .top,
        .bottom {
            left: 0px;
            right: 0px;
            height: 2px;
        }

        .left,
        .right {
            top: 0px;
            bottom: 0px;
            width: 2px;
            transform: scaleY(0);
        }

        .top {
            top: 0px;
            transform: scaleX(0);
            transform-origin: left center;
            transition-delay: .2s;
        }

        .left {
            left: 0px;
            transform-origin: bottom center;
            transition-delay: .3s;
        }

        .bottom {
            bottom: 0px;
        }

        .right {
            right: 0px;
            transform-origin: top center;
            transition-delay: .1s;
        }

        input:focus ~ .right {
            transform: scaleY(1);
            transform-origin: bottom center;
        }

        input:focus ~ .left {
            transform: scaleY(1);
            transform-origin: top center;
        }

        input:focus ~ .top {
            transform: scaleY(1);
            transform-origin: right center;
        }

        .container1 {
            height: 30px;
            width: 250px;
            position: absolute;
            left: 50%;
            top: 50%;
            transform: translate(-50%, -50%);
        }

        .btn {
            position: absolute;
            left: 50%;
            top: 54%;
            transform: translate(-50%, -50%);
            text-align: center;
            padding: 5px;
            width: 52%;
            margin-top: 40px;
            font-size: 24px; /* 调整字体大小 */
            background-color: #61dafb;
            color: #fff;
        }

        .register {
            position: absolute;
            left: 50%;
            top: 62%;
            transform: translate(-50%, -50%);
            text-align: center;
            padding: 5px;
            width: 52%;
            margin-top: 40px;
            color: #6192fb;
            text-decoration: underline; /* 添加下划线 */
        }


    </style>
</head>
<body>
<div class="login">
    <div class="header">灵犀社</div>
    <div class="container">
        <input type="text" placeholder="请输入用户名">
        <span class="left"></span>
        <span class="right"></span>
        <span class="top"></span>
        <span class="bottom"></span>
    </div>
    <div class="container1">
        <input type="password" placeholder="请输入密码">
        <span class="left"></span>
        <span class="right"></span>
        <span class="top"></span>
        <span class="bottom"></span>
    </div>

    <div class="btn" οnclick="onRegister()"><a href="dologin.html">登录</a>
    <a href="login.html" class="register" οnclick="onlogin()">立即注册</a>
</div>

</body>
</html>
要实现Flume将Linux文件夹中的JSON文件上传到HDFS上而不改变文件格式,你需要配置Flume的Agent来监控源目录,并将数据流式传输到HDFS sink。以下是一个简单的配置示例: 首先,确保你的系统中已经安装了Flume和Hadoop,并且HDFS处于运行状态。 然后,创建一个Flume配置文件`flume-conf.properties`,配置内容大致如下: ``` # 定义agent的名字 agent1.name = Agent1 agent1.sources = Source1 agent1.sinks = Sink1 agent1.channels = Channel1 # 配置source:监控本地文件系统中的文件夹 agent1.sources.Source1.type = exec agent1.sources.Source1.command = tail -F /path/to/json/directory/*.json agent1.sources.Source1.channels = Channel1 # 配置sink:将数据写入HDFS agent1.sinks.Sink1.type = hdfs agent1.sinks.Sink1.hdfs.path = hdfs://namenode/path/to/hdfs/directory agent1.sinks.Sink1.hdfs.fileType = DataStream agent1.sinks.Sink1.hdfs.writeFormat = Text # 配置channel:用于source和sink之间的通信 agent1.channels.Channel1.type = memory agent1.channels.Channel1.capacity = 1000 agent1.channels.Channel1.transactionCapacity = 100 # 将source和sink与channel连接起来 agent1.sources.Source1.channels = Channel1 agent1.sinks.Sink1.channel = Channel1 ``` 在这个配置中,我们定义了一个名为`Agent1`的agent,它包含一个名为`Source1`的source,一个名为`Sink1`的sink和一个名为`Channel1`的channel。Source监控指定的文件夹,并将新创建的`.json`文件传输到channel。Sink则从channel读取数据,并将其以文本格式写入到指定的HDFS路径。 将上面的配置保存为`flume-conf.properties`文件,并确保修改`/path/to/json/directory`和`hdfs://namenode/path/to/hdfs/directory`为实际的源文件夹路径和HDFS目标路径。之后,启动Flume agent: ```shell flume-ng agent --conf /path/to/flume/conf --conf-file /path/to/flume-conf.properties --name Agent1 -Dflume.root.logger=INFO,console ``` 确保替换`/path/to/flume/conf`和`/path/to/flume-conf.properties`为你的实际Flume配置目录和配置文件路径。 请注意,上述配置是一个基本示例,实际情况可能需要根据你的具体需求和环境进行调整。
评论
添加红包

请填写红包祝福语或标题

红包个数最小为10个

红包金额最低5元

当前余额3.43前往充值 >
需支付:10.00
成就一亿技术人!
领取后你会自动成为博主和红包主的粉丝 规则
hope_wisdom
发出的红包
实付
使用余额支付
点击重新获取
扫码支付
钱包余额 0

抵扣说明:

1.余额是钱包充值的虚拟货币,按照1:1的比例进行支付金额的抵扣。
2.余额无法直接购买下载,可以购买VIP、付费专栏及课程。

余额充值