从零开发短视频电商 AWS OpenSearch Service开发环境申请以及Java客户端介绍

文章目录

    • 创建域
      • 1.创建域
      • 2.输入配置
        • 部署选项
        • 数据节点
        • 网络
        • 精细访问控制
        • 访问策略
    • 获取域端点
    • 数据如何插入到OpenSearch Service
    • Java连接OpenSearch Service
      • spring-data-opensearch
      • elasticsearch-rest-high-level-client
      • opensearch-rest-client
      • opensearch-java

因为是开发测试使用,所以选的都是低配,单机,便宜的配置。

地址:https://aws.amazon.com/cn/opensearch-service/

价格:https://aws.amazon.com/cn/opensearch-service/pricing/

  • 实例小时数 +
  • 所需的存储量 +
  • 传入和传出 Amazon OpenSearch Service 的数据

文档:https://docs.aws.amazon.com/zh_cn/opensearch-service/

创建域

一般在15-30分钟内创建一个OpenSearch集群,所以请尿完尿再来搞,别憋坏了。

1.创建域

2.输入配置

  • 域名:后面用java等客户端连接时会在URL中显示。

  • 域创建方法:请选择标准创建

    • 轻松创建:快速创建 OpenSearch 域以实现高可用性 含备用节点的多可用区,我们要自定义标准创建便宜点。可以理解为一个产线的标准套餐。
    • 标准创建:就是自选套餐。
  • 模板:选择开发/测试

  • 部署选项:选择不含备用节点的域,主打的就是便宜能用就行。
  • 可用区:选择一个可用区。
  • 版本:请选择最新版本。
部署选项

数据节点
  • 实例类型:默认是内存优化 - r6g.large.search,2C16G 价格为USD 0.167/H,下面列几个便宜的。
    • t3.small.search 2C2G USD 0.036 ,自己用来个最便宜的,又不是不能用。
    • t3.medium.search 2C4G USD 0.073
  • 节点数:1个就行。
  • 存储大小:40G就行。

忽略其他冷热数据存储专用主节点快照配置,以及自定义终端节点部分。

网络
  • 网络:选择 Public access(公有访问权限)
    • 开发测试环境,选择公共访问权限,生成用VPC访问

精细访问控制

启用细粒度访问控制复选框。选择创建主用户输入用户名和密码,用户名和密码很关键,后面访问dashboard和远程客户端连接都要。

忽略 SAML 身份验证Amazon Cognito 身份验证

访问策略

选择 Only use fine-grained access control(仅使用精细访问控制)

忽略其余设置,然后选择 Create(创建)。新域初始化过程通常需要 15-30 分钟,但可能需要更长的时间,具体取决于配置。

获取域端点

点击创建后,通常需要 15-30 分钟,然后从控制台 -> 域 -> 一般信息 获取域端点。

这里给了IPV6和IPV4的dashboard地址和域端点地址。

数据如何插入到OpenSearch Service

  • 对于大规模数据,我们建议使用 Amazon Kinesis Data Firehose,这是一项完全托管的服务,可以自动扩展以匹配您的数据吞吐量,并且不需要进行持续的管理。它还可以在加载数据前对其进行转换、批处理和压缩。
  • Amazon OpenSearch Service 支持与 Logstash 的集成。您可以将 Amazon OpenSearch Service 域配置为数据存储,用于存储所有来自 Logstash 的日志。
  • 可以使用索引 API 和批量 API 等原生 Elasticsearch(7.10 及更低版本)或 OpenSearch API 将数据加载到域中。

Java连接OpenSearch Service

当使用 Java 连接 OpenSearch 时,有几个选择,包括 Spring Data Elasticsearch/opensearch、原生 Elasticsearch 和 OpenSearch 客户端。下面是每种方式的简要介绍:

  • spring-data-xxx
  • 原生Elasticsearch
  • OpenSearch

建议基本的CRUD用 spring-data-xxx

复杂的查询用低级client,如opensearch-java
RestClient lowLevelClient = highLevelClient.getLowLevelClient();
lowLevelClient . lowLevelClient.performRequest()

验证分为用户名和密码进行身份验证AWS访问密钥(Access Key和Secret Key)
我们当前选的精细控制用的是用户名密码验证,后面生产建议改为IAM验证。

spring-data-opensearch

  • Github:https://github.com/opensearch-project/spring-data-opensearch

  • 官方示例:https://github.com/opensearch-project/spring-data-opensearch/tree/main/spring-data-opensearch-examples

Spring Boot 3.x

1.添加依赖。

<dependency>
	<groupId>org.opensearch.client</groupId>
	<artifactId>spring-data-opensearch-starter</artifactId>
	<version>1.3.0</version>
</dependency>

2.启动类去除ElasticsearchDataAutoConfiguration自动配置。

@SpringBootApplication(exclude = {ElasticsearchDataAutoConfiguration.class})
public class OpenSearchDemoApplication {
  public static void main(String[] args) {
    SpringApplication.run(OpenSearchDemoApplication.class, args);
  }
}

3.application.yml增加配置

opensearch:
  uris: https://localhost:9200
  username: admin
  password: admin

spring:
  jackson:
    serialization:
      INDENT_OUTPUT: true

4.新增model

import java.math.BigDecimal;
import org.springframework.data.annotation.Id;
import org.springframework.data.elasticsearch.annotations.Document;
import org.springframework.data.elasticsearch.annotations.Field;
import org.springframework.data.elasticsearch.annotations.FieldType;

@Document(indexName = "marketplace")
public class Product {
    @Id
    private String id;

    @Field(type = FieldType.Text, name = "name")
    private String name;

    @Field(type = FieldType.Double, name = "price")
    private BigDecimal price;

    @Field(type = FieldType.Integer, name = "quantity")
    private Integer quantity;

    @Field(type = FieldType.Text, name = "description")
    private String description;

    @Field(type = FieldType.Keyword, name = "vendor")
    private String vendor;

5.新增Repository

import java.math.BigDecimal;
import java.util.List;
import org.opensearch.data.example.model.Product;
import org.springframework.data.elasticsearch.repository.ElasticsearchRepository;
import org.springframework.stereotype.Repository;

@Repository
public interface MarketplaceRepository extends ElasticsearchRepository<Product, String> {
    List<Product> findByNameLikeAndPriceGreaterThan(String name, BigDecimal price);
}

6.新增service

@Service
public class  MarketplaceService {

  private final MarketplaceRepository repository;

  public MyService(MarketplaceRepository repository) {
    this.repository = repository;
  }

  public void doWork() {

    repository.deleteAll();

    Product product = new Product();
    product.setName("xxx");
    product.setxxx("xxx");
    repository.save(product);

    List<Product> results = repository.findByNameLikeAndPriceGreaterThan("Gierke",xx);
 }
}

我们还可以通过RestHighLevelClient获得lowLevelRest()客户端。

  @Autowired
  RestHighLevelClient highLevelClient;

  RestClient lowLevelClient = highLevelClient.getLowLevelClient();

IndexRequest request = new IndexRequest("spring-data")
  .id(randomID())
  .source(singletonMap("feature", "high-level-rest-client"))
  .setRefreshPolicy(IMMEDIATE);
IndexResponse response = highLevelClient.index(request,RequestOptions.DEFAULT);

 // 构建请求
        Request request = new Request("GET", "/your-index-name/_search");

        // 添加请求参数,如果需要的话
        request.addParameter("q", "field:value");

        // 执行请求
        Response response = lowLevelClient.performRequest(request);

        // 处理响应
        int statusCode = response.getStatusLine().getStatusCode();
        String responseBody = EntityUtils.toString(response.getEntity());

        System.out.println("Status Code: " + statusCode);
        System.out.println("Response Body: " + responseBody);

elasticsearch-rest-high-level-client

1.添加依赖

<dependencies>
    <dependency>
        <groupId>org.elasticsearch.client</groupId>
        <artifactId>elasticsearch-rest-high-level-client</artifactId>
        <version>7.10.2</version> <!-- 替换为你使用的OpenSearch版本 -->
    </dependency>
</dependencies>

2.示例代码

import org.elasticsearch.action.index.IndexRequest;
import org.elasticsearch.action.index.IndexResponse;
import org.elasticsearch.action.search.SearchRequest;
import org.elasticsearch.action.search.SearchResponse;
import org.elasticsearch.client.RequestOptions;
import org.elasticsearch.client.RestClient;
import org.elasticsearch.client.RestHighLevelClient;
import org.elasticsearch.common.xcontent.XContentType;
import org.elasticsearch.index.query.QueryBuilders;
import org.elasticsearch.search.builder.SearchSourceBuilder;

import java.io.IOException;
import java.util.HashMap;
import java.util.Map;

public class OpenSearchExample {

    public static void main(String[] args) {
        // OpenSearch连接配置
        String hostname = "your_opensearch_host"; // 替换为你的OpenSearch服务器主机名或IP地址
        int port = 9200; // 替换为你的OpenSearch服务器端口
        String scheme = "https"; // 如果使用HTTPS,否则使用"http"
        String username = "laker";
        String password = "lakerpwd";

        try (RestHighLevelClient client = new RestHighLevelClient(
                RestClient.builder(hostname)
                        .setPort(port)
                        .setScheme(scheme)
                        .setHttpClientConfigCallback(httpClientBuilder ->
                                httpClientBuilder.setDefaultCredentialsProvider(() ->
                                        new org.apache.http.auth.UsernamePasswordCredentials(username, password))
                        )
        )) {
            // 上传数据
            Map<String, Object> jsonMap = new HashMap<>();
            jsonMap.put("field1", "value1");
            jsonMap.put("field2", "value2");

            IndexRequest indexRequest = new IndexRequest("your_index")
                    .id("your_document_id") // 替换为文档的ID
                    .source(jsonMap, XContentType.JSON);

            IndexResponse indexResponse = client.index(indexRequest, RequestOptions.DEFAULT);
            System.out.println("Index created with ID: " + indexResponse.getId());

            // 查询数据
            SearchRequest searchRequest = new SearchRequest("your_index");
            SearchSourceBuilder searchSourceBuilder = new SearchSourceBuilder();
            searchSourceBuilder.query(QueryBuilders.matchAllQuery());
            searchRequest.source(searchSourceBuilder);

            SearchResponse searchResponse = client.search(searchRequest, RequestOptions.DEFAULT);
            // 处理查询结果
            System.out.println("Search hits: " + searchResponse.getHits().getTotalHits());
        } catch (IOException e) {
            e.printStackTrace();
        }
    }
}

opensearch-rest-client

  • 文档:https://opensearch.org/docs/latest/clients/java-rest-high-level/

1.添加依赖

        <dependency>
            <groupId>org.opensearch.client</groupId>
            <artifactId>opensearch-rest-high-level-client</artifactId>
            <version>2.11.1</version>
        </dependency>

2.示例代码

import org.apache.http.HttpHost;
import org.apache.http.auth.AuthScope;
import org.apache.http.auth.UsernamePasswordCredentials;
import org.apache.http.client.CredentialsProvider;
import org.apache.http.impl.client.BasicCredentialsProvider;
import org.apache.http.impl.nio.client.HttpAsyncClientBuilder;
import org.opensearch.action.admin.indices.delete.DeleteIndexRequest;
import org.opensearch.action.delete.DeleteRequest;
import org.opensearch.action.delete.DeleteResponse;
import org.opensearch.action.get.GetRequest;
import org.opensearch.action.get.GetResponse;
import org.opensearch.action.index.IndexRequest;
import org.opensearch.action.index.IndexResponse;
import org.opensearch.action.support.master.AcknowledgedResponse;
import org.opensearch.client.RequestOptions;
import org.opensearch.client.RestClient;
import org.opensearch.client.RestClientBuilder;
import org.opensearch.client.RestHighLevelClient;
import org.opensearch.client.indices.CreateIndexRequest;
import org.opensearch.client.indices.CreateIndexResponse;
import org.opensearch.common.settings.Settings;

import java.io.IOException;
import java.util.HashMap;

public class RESTClientSample {

  public static void main(String[] args) throws IOException {

    final CredentialsProvider credentialsProvider = new BasicCredentialsProvider();

    credentialsProvider.setCredentials(AuthScope.ANY,
      new UsernamePasswordCredentials("lakertest", "xxxx"));

    //Create a client.
    RestClientBuilder builder = RestClient.builder(new HttpHost("search-laker-search-xxxx.us-east-2.es.amazonaws.com", 443, "https"))
      .setHttpClientConfigCallback(httpClientBuilder -> httpClientBuilder.setDefaultCredentialsProvider(credentialsProvider));
    RestHighLevelClient client = new RestHighLevelClient(builder);

    //Create a non-default index with custom settings and mappings.
    CreateIndexRequest createIndexRequest = new CreateIndexRequest("custom-index");

    createIndexRequest.settings(Settings.builder() //Specify in the settings how many shards you want in the index.
      .put("index.number_of_shards", 4)
      .put("index.number_of_replicas", 3)
      );
    //Create a set of maps for the index's mappings.
    HashMap<String, String> typeMapping = new HashMap<String,String>();
    typeMapping.put("type", "integer");
    HashMap<String, Object> ageMapping = new HashMap<String, Object>();
    ageMapping.put("age", typeMapping);
    HashMap<String, Object> mapping = new HashMap<String, Object>();
    mapping.put("properties", ageMapping);
    createIndexRequest.mapping(mapping);
    CreateIndexResponse createIndexResponse = client.indices().create(createIndexRequest, RequestOptions.DEFAULT);

    //Adding data to the index.
    IndexRequest request = new IndexRequest("custom-index"); //Add a document to the custom-index we created.
    request.id("1"); //Assign an ID to the document.

    HashMap<String, String> stringMapping = new HashMap<String, String>();
    stringMapping.put("message:", "Testing Java REST client");
    request.source(stringMapping); //Place your content into the index's source.
    IndexResponse indexResponse = client.index(request, RequestOptions.DEFAULT);

    // 查询
    GetRequest getRequest = new GetRequest("custom-index", "1");
    GetResponse response = client.get(getRequest, RequestOptions.DEFAULT);

    System.out.println(response.getSourceAsString());

    // 删除文档
    DeleteRequest deleteDocumentRequest = new DeleteRequest("custom-index", "1"); //Index name followed by the ID.
    DeleteResponse deleteResponse = client.delete(deleteDocumentRequest, RequestOptions.DEFAULT);

    // 删除索引
    DeleteIndexRequest deleteIndexRequest = new DeleteIndexRequest("custom-index"); //Index name.
    AcknowledgedResponse deleteIndexResponse = client.indices().delete(deleteIndexRequest, RequestOptions.DEFAULT);

    client.close();
  }
}

opensearch-java

  • 文档:https://opensearch.org/docs/latest/clients/java/
  • 示例代码:https://github.com/opensearch-project/opensearch-java/tree/main/samples
    • 里面很详细,包含knn部分。
<dependency>
  <groupId>org.opensearch.client</groupId>
  <artifactId>opensearch-java</artifactId>
  <version>2.8.1</version>
</dependency>
@Data
public class IndexData {
    private String title;
    private String text;

    public IndexData() {
    }
    public IndexData(String title, String text) {
        this.title = title;
        this.text = text;
    }
}
import org.apache.http.HttpHost;
import org.apache.http.auth.AuthScope;
import org.apache.http.auth.UsernamePasswordCredentials;
import org.apache.http.client.CredentialsProvider;
import org.apache.http.impl.client.BasicCredentialsProvider;
import org.opensearch.client.RestClient;
import org.opensearch.client.json.jackson.JacksonJsonpMapper;
import org.opensearch.client.opensearch.OpenSearchClient;
import org.opensearch.client.opensearch._types.mapping.IntegerNumberProperty;
import org.opensearch.client.opensearch._types.mapping.Property;
import org.opensearch.client.opensearch._types.mapping.TypeMapping;
import org.opensearch.client.opensearch.core.IndexRequest;
import org.opensearch.client.opensearch.core.SearchResponse;
import org.opensearch.client.opensearch.indices.CreateIndexRequest;
import org.opensearch.client.opensearch.indices.DeleteIndexRequest;
import org.opensearch.client.opensearch.indices.IndexSettings;
import org.opensearch.client.transport.OpenSearchTransport;
import org.opensearch.client.transport.rest_client.RestClientTransport;

import java.io.IOException;

public class OpenSearchClientExample {
    public static void main(String[] args) throws IOException {

        final CredentialsProvider credentialsProvider = new BasicCredentialsProvider();
        credentialsProvider.setCredentials(AuthScope.ANY,
                new UsernamePasswordCredentials("admin", "admin"));

        // 私有 opensearch
        RestClient restClient = RestClient.builder(new HttpHost("localhost", 9200, "https")).
                setHttpClientConfigCallback(httpClientBuilder -> httpClientBuilder.setDefaultCredentialsProvider(credentialsProvider)).build();
        OpenSearchTransport transport = new RestClientTransport(restClient, new JacksonJsonpMapper());
        OpenSearchClient client = new OpenSearchClient(transport);

        //Create the index
        String indexName = "sample-index";
        //Add some settings to the index
        IndexSettings settings = new IndexSettings.Builder().numberOfShards("2").numberOfReplicas("1").build();
        TypeMapping mapping = new TypeMapping.Builder().properties(
                "age",
                new Property.Builder().integer(new IntegerNumberProperty.Builder().build()).build()
        ).build();
        CreateIndexRequest createIndexRequest = new CreateIndexRequest.Builder().index(indexName)
                .settings(settings)
                .mappings(mapping)
                .build();
        client.indices().create(createIndexRequest);

        //Index some data

        IndexData indexData = new IndexData("Document 1", "Text for document 1");
        IndexRequest<IndexData> indexRequest = new IndexRequest.Builder<IndexData>().index(indexName)
                .id("1")
                .document(indexData)
                .build();
        client.index(indexRequest);


        //Search for the document
        SearchResponse<IndexData> searchResponse = client.search(s -> s.index(indexName), IndexData.class);
        for (int i = 0; i < searchResponse.hits().hits().size(); i++) {
            System.out.println(searchResponse.hits().hits().get(i).source());
        }

        //Delete the document
        client.delete(b -> b.index(indexName).id("1"));

        // Delete the index
        DeleteIndexRequest deleteIndexRequest = new DeleteIndexRequest.Builder().index(indexName).build();
        client.indices().delete(deleteIndexRequest);

        try {
            if (restClient != null) {
                restClient.close();
            }
        } catch (IOException e) {
            System.out.println(e.toString());
        }
    }
}

本文来自互联网用户投稿,该文观点仅代表作者本人,不代表本站立场。本站仅提供信息存储空间服务,不拥有所有权,不承担相关法律责任。如若转载,请注明出处:/a/228728.html

如若内容造成侵权/违法违规/事实不符,请联系我们进行投诉反馈qq邮箱809451989@qq.com,一经查实,立即删除!

相关文章

喜讯!云起无垠上榜《成长型初创企业推荐10强》

近期&#xff0c;由中国计算机学会抗恶劣环境计算机专业委员会、信息产业信息安全测评中心和安全牛联合发起的第十一版《中国网络安全企业100强》榜单正式发布。在这份备受关注的榜单中&#xff0c;云起无垠凭借其创新的技术能力&#xff0c;荣登《成长型初创企业推荐10强》榜单…

echarts绘制一个环形图

其他echarts&#xff1a; echarts绘制一个柱状图&#xff0c;柱状折线图 echarts绘制一个饼图 echarts绘制一个环形图2 效果图&#xff1a; 代码&#xff1a; <template><div class"wrapper"><!-- 环形图 --><div ref"doughnutChart…

CCKS2023-面向金融领域的主体事件检测-亚军方案分享

赛题分析 大赛地址 https://tianchi.aliyun.com/competition/entrance/532098/introduction?spma2c22.12281925.0.0.52b97137bpVnmh 任务描述 主体事件检测是语言文本分析和金融领域智能应用的重要任务之一&#xff0c;如在金融风控领域往往会对公司主体进行风险事件的检测…

【C#设计模式 + Filter】装饰器模式专项——过滤器

c# 装饰器模式专项——过滤器 装饰器模式专项——过滤器Filter1.winform实现通过特性改控件名称&#xff08;.Framework)2.手写过滤器 (.NET Core) 装饰器模式专项——过滤器Filter 左边为api启动流程。 右边为需要实现的winform启动流程。右边大框里面需要我们手动实现。 1.wi…

python pyaudio实时读取音频数据并展示波形图

python pyaudio实时读取音频数据并展示波形图 下面代码可以驱动电脑接受声音数据&#xff0c;并实时展示音波图&#xff1a; import numpy as np import matplotlib.pyplot as plt import matplotlib.animation as animation import pyaudio import wave import os import op…

Michael.W基于Foundry精读Openzeppelin第41期——ERC20Capped.sol

Michael.W基于Foundry精读Openzeppelin第41期——ERC20Capped.sol 0. 版本0.1 ERC20Capped.sol 1. 目标合约2. 代码精读2.1 constructor() && cap()2.2 _mint(address account, uint256 amount) 0. 版本 [openzeppelin]&#xff1a;v4.8.3&#xff0c;[forge-std]&…

2023年全球软件开发大会(QCon广州站2023)-核心PPT资料下载

一、峰会简介 本次峰会包含&#xff1a;泛娱乐时代的边缘计算与通讯、稳定性即生命线、下一代软件架构、出海的思考、现代数据架构、AGI 与 AIGC 落地、大前端技术探索、编程语言实战、DevOps vs 平台工程、新型数据库、AIGC 浪潮下的企业出海、AIGC 浪潮下的效能智能化、数据…

使用Rust 构建C 组件

协议解析&#xff0c;这不就很快了&#xff0c;而且原生的标准库红黑树和avl 树支持&#xff0c;异步tokio 这些库&#xff0c;编写应用组件就很快了 rust 标准库不支持 unix 的消息队列&#xff0c;但是支持 shm 和 uds&#xff0c;后者从多方面考虑都比&#xff0c;消息队列更…

python爬取 HTTP_2 网站超时问题的解决方案

问题背景 在进行网络数据爬取时&#xff0c;使用 Python 程序访问支持 HTTP/2 协议的网站时&#xff0c;有时会遇到超时问题。这可能会导致数据获取不完整&#xff0c;影响爬虫程序的正常运行。 问题描述 在实际操作中&#xff0c;当使用 Python 编写的爬虫程序访问支持 HTT…

SAP物料会计视图的价格确定MLAST为空后台补录

物料10013812 工厂会计视图的价格确定为空&#xff0c;前台目前无法修改&#xff0c;申请修改底表&#xff0c;将价格确定调整为2 解决&#xff1a; 该字段涉及&#xff1a;MBEW表和CKMLHD表的MLAST字段两个地方&#xff0c;经修改后&#xff0c;前后台数据一致。 只改技术信…

2023_Spark_实验二十五:SparkStreaming读取Kafka数据源:使用Direct方式

SparkStreaming读取Kafka数据源&#xff1a;使用Direct方式 一、前提工作 安装了zookeeper 安装了Kafka 实验环境&#xff1a;kafka zookeeper spark 实验流程 二、实验内容 实验要求&#xff1a;实现的从kafka读取实现wordcount程序 启动zookeeper zk.sh start# zk.sh…

性能测试(超详细)

近期公司为了节省成本搞了一波机房迁移&#xff0c;整合了一些南美部署架构。有一些上google云和有些下阿里云等大的调整。 在做机房迁移项目当中就需要思考如何进行性能测试&#xff0c;这种大的机房迁移SRE&#xff08;运维&#xff09;会针对组件会做一些单组件的性能测试&a…

服务器配置免密SSH

在当今互联网时代&#xff0c;远程工作和网络安全已成为信息技术领域的热点话题。无论是管理远程服务器、维护网络设备还是简单地从家中连接到办公室&#xff0c;安全始终是首要考虑的因素。这就是为什么 SSH&#xff08;Secure Shell&#xff09;成为了网络专业人士的首选工具…

【FreeRTOS】信号量——简介、常用API函数、注意事项、项目实现

在FreeRTOS中&#xff0c;信号量是一种非常重要的同步机制&#xff0c;用于实现任务间的互斥访问和同步操作。通过信号量&#xff0c;不同的任务可以安全地共享资源&#xff0c;避免竞争和冲突&#xff0c;从而确保系统的稳定性和可靠性。本篇博客将介绍FreeRTOS中信号量的基本…

MacBook 逆水寒下载安装使用教程,支持最新版本 MacOS 流畅不闪退

最近 MacBook 系统更新到了 MacOS 14.1 很多朋友的逆水寒玩不了了&#xff0c;我尝试了一番可以正常玩了&#xff0c;看图&#xff1a; 其实操作也很简单&#xff0c;我们从头开始&#xff0c;因为 MacOS 系统的更新所以我们也需要更新新版本的 playCover 来适配新的系统&#…

SpringSecurity(二)

SpringSecurity源码的初探 一、SpringSecurity中的核心组件 在SpringSecurity中的jar分为4个&#xff0c;作用分别为 jar作用spring-security-coreSpringSecurity的核心jar包&#xff0c;认证和授权的核心代码都在这里面spring-security-config如果使用Spring Security XML名称…

速查!软考出成绩了

2023年11月软考成绩出来啦&#xff01;大家赶紧查一下&#xff0c;各科都45分就是通过&#xff01; 01 如何查成绩 1、打开“中国计算机技术职业资格网”&#xff0c;网址&#xff1a;https://www.ruankao.org.cn/ 2、点击↘的“成绩查询”按钮。 3、输入“手机号/证件号密码验…

C //例10.3 从键盘读入若干个字符串,对它们按字母大小的顺序排序,然后把排好序的字符串送到磁盘文件中保存。

C程序设计 &#xff08;第四版&#xff09; 谭浩强 例10.3 例10.3 从键盘读入若干个字符串&#xff0c;对它们按字母大小的顺序排序&#xff0c;然后把排好序的字符串送到磁盘文件中保存。 IDE工具&#xff1a;VS2010 Note: 使用不同的IDE工具可能有部分差异。 代码块 方法…

搭乘“低代码”快车,引领食品行业数字化转型全新升级

数字化技术作为重塑传统行业重要的力量&#xff0c;正以不可逆转的趋势改变着企业经营与客户消费的方式。 在近些年的企业数字化服务与交流过程中&#xff0c;织信团队切实感受到大多数企业经营者们从怀疑到犹豫再到焦虑最终转为坚定的态度转变。 在这场数字化转型的竞赛中&a…

[wp]“古剑山”第一届全国大学生网络攻防大赛 Web部分wp

“古剑山”第一届全国大学生网络攻防大赛 群友说是原题杯 哈哈哈哈 我也不懂 我比赛打的少 Web Web | unse 源码&#xff1a; <?phpinclude("./test.php");if(isset($_GET[fun])){if(justafun($_GET[fun])){include($_GET[fun]);}}else{unserialize($_GET[…