COMP2046 POSIX API in Linux

SpringBoot+Vue+MySQL 高校学科竞赛平台 完整可运行版(源码+文档) 本项目基于SpringBoot+Vue+MySQL构建高校学科竞赛管理平台,覆盖学生、教师、领队教师、管理员四大角色,实现竞赛发布、报名、刷题、评分、公示等全流程闭环管理。系统架构清晰,技术主流,配套完整源码、数据库脚本、万字论文、开题报告、答辩PPT及部署文档,支持一键运行,适用于毕业设计、课程设计及院系二次开发,真正实现“开箱即用”。 阅读详情

COMP2046 Coursework Autumn 2024

Weight: 20% module marks

Deadline: 27th December 2024, 5pm Beijing time 

Submission: Create a single scyXXX.zip (Student account) file containing your source code files and files 

provided along with this coursework. We will need to rebuild your code to test your implementation. You 

should submit your single zip file through Moodle.

Overview

The goal of this coursework is to make use of operating system APIs (specifically, the POSIX API in Linux) 

and simple concurrency directives to solve a number of synchronisation problems that occur on 

scheduling systems that are similar to the ones that you may find in fairly simple operating systems. 

Completing all tasks will give you a good understanding of: 

• The use of operating system APIs in Linux. 

• Critical sections, semaphores, mutexes, and the principles of synchronisation/mutual exclusion. 

• The implementation of linear bounded buffers of a fixed size using linked lists. 

• The basics of concurrent/parallel programming using an operating system’s facilities (e.g. 

semaphores, mutex).

• Basic process creation, memory image overwriting and shared memory usage.

Getting Help

You MAY ask Dr Qian Zhang and Dr Fiseha B. Tesema for help in understanding coursework requirements 

if they are not clear (i.e. what you need to achieve). Any necessary clarifications will then be added to the 

Moodle page so that everyone can see them.

You may NOT get help from anybody else to actually do the coursework (i.e. how to do it), including 

ourselves. You may get help on any of the code samples provided, since these are designed to help you 

to do the coursework without giving you the answers directly.

Background Information

All code should be implemented in C and tested on the school’s Linux servers. Code that cannot be 

successfully compiled on the school’s Linux servers using the provided source/header files will affect your 

marks.

Additional information on programming in Linux, the use of POSIX APIs, and the specific use of threads 

and concurrency directives in Linux can be found, e.g., here (it is my understanding that this book was 

published freely online by the authors and that there are no copyright violations because of this).

Additional information on the bounded buffer problem can be found in, e.g.:

• Tanenbaum, Andrew S. 2014 Modern Operating Systems. 4th ed. Prentice Hall Press, Upper 

Saddle River, NJ, USA., Chapter 2, section 2.3.4

• Silberschatz, Abraham, Peter Baer Galvin, Greg Gagne. 2008. Operating System Concepts. 8th 

ed. Wiley Publishing, Chapter 4 and 5

• Stallings, William. 2008. Operating Systems: Internals and Design Principles. 6th ed. Prentice Hall 

Press, Upper Saddle River, NJ, USA, Chapter 5

• In addition to these books, much of the information in the lecture notes should be extremely 

helpful 

Please use only the system calls or POSIX libraries discussed in the lab. The use of any other system calls 

or POSIX libraries is not allowed.

Coding and Compiling Your Coursework 

You are free to use a code editor of your choice, but your code MUST compile and run on the school’s 

Linux servers. It will be tested and marked on these machines.

For task 1

We have provided a header file, linkedlist.h, which contains three function prototypes. The source 

file, linkedlist.c, includes the implementation of these functions. This code implements a basic singly 

linked list with the following three functions:

1. addLast: Adds a new element to the end of the list.

2. addFirst: Adds a new element to the beginning of the list.

3. removeFirst: Removes and returns the first element from the list.

It dynamically manages memory for the list nodes and handles edge cases, such as empty lists. The list 

structure is defined using a struct element that holds a data pointer and a next pointer, making the 

implementation flexible for various data types.

To ensure consistency across all students, changes are not to be made on the given source files. Note that, 

in order to use these files with your own code, you will be required to specify the file on the command 

line when using the gcc compiler (e.g. (updated Dec 4)

and include the linkedlist.c file in your code (using #include “linkedlist.h”).

For task 2

You should ensure that your code compiles using the GNU C-compiler, e.g., with the command:

(updated Dec 4)

(updated Nov28)

gcc –std=c99 TASKX.c -o TASKX linkedlist.c -pthread 

gcc TASK2.c -o TASK2output -lrt -pthread

Copying Code and Plagiarism

You are allowed to freely copy and adapt code samples provided in lab exercises or lectures. Additionally, 

you may use examples from Linux/POSIX websites, which offer many code snippets to help with specific 

tasks. This coursework assumes and encourages the use of these resources as part of the learning process. 

Since you are not claiming this code as your own original work, this does not constitute plagiarism.

Please note that some provided examples may omit error checking for clarity. It is your responsibility to 

include appropriate error checking in your implementation.

However, you must not copy code from any other sources, including:

• Another student, whether from this course or any other course.

• Any third-party sources, such as ChatGPT or similar tools.

If you do so, it will be considered an attempt to pass someone else’s work as your own, which is plagiarism. 

The University treats plagiarism very seriously. Consequences may include receiving a zero for the 

coursework, failing the module, or facing more severe penalties.

Task 1: Concurrency problem: Bounded buffers (60 %)

In this task you will implement a bounded buffer (i.e. of fixed size) of characters in two different ways. 

In task 1a, you will: 

• Use a single producer and single consumer. 

• Synchronise using binary semaphores (or mutexes where appropriate). 

In task 1b, you will: 

• Use multiple producers and multiple consumers. 

• Synchronise using counting semaphores (or mutexes where appropriate).

In both cases, you will produce/consume a pre-determined number of elements. Both tasks will give you 

good insights into the different synchronisation approaches for bounded buffers. 

Task 1a: Bounded buffer with binary semaphores (30 marks)

You are asked to implement a FCFS bounded buffer (represented as linked list). The buffer can contain at 

most MAX_BUFFER_SIZE (defined in the task1a.c code templet) elements, and each element contains one 

character (a ‘*’ in this case). You are asked to implement a single producer and a single consumer. The 

producer generates MAX_NUMBER_OF_JOBS (defined in the task1a.c code templet) ‘*’ characters and 

adds them to the end of the buffer (provided that empty spaces are available). The consumer removes ‘*’ 

characters from the start of the buffer (provided that full elements are available). Each time the producer 

(consumer) adds (removes) an element, the number of elements currently in the buffer is shown on the 

screen as a line of stars (see output sample provided task1a.txt). Different implementations and 

synchronisation approaches are possible, however, we are asking you to use only binary semaphores (or 

mutexes where appropriate) in your implementation. 

The final version of your code will include:

• A linked list of characters representing the bounded buffer utilised in the correct manner. The 

maximum size of this list should be configured to not exceed, e.g., 50 elements. 

• A producer function that generates stars (‘*’) and adds them to the end of the buffer (using addLast) 

as soon as space is available. 

• A consumer function that removes elements from the start of the buffer using removeFirst (one at 

a time).

• A visualisation function that displays the exact number of elements currently in the buffer (using a 

line of stars) on the screen every time an element is added to or removed from the buffer. 

• The code to: 

o Declare all necessary semaphores/mutexes and initialise them to the correct values. 

o Create the producer/consumer threads. 

o Join all threads with the main thread to prevent the main thread from finishing before 

the consumers/producers have ended. 

o Generate output similar in format to the example provided for this requirement

(task1a.txt) (for 100 jobs, using a buffer size of 10). 

Task 1b: Bounded buffer with counting semaphores (30 marks)

You are asked to, similar to task1a, implement a bounded buffer of characters, however, this time with 

multiple producers (NUMBER_OF_PRODUCERS defined in task1b.c code templet), multiple consumers

(NUMBER_OF_CONSUMERS defined in task1b.c code templet), and counting semaphores. The producers 

generate a total of MAX_NUMBER_OF_JOBS (defined in the task1b.c code templet) elements, which are 

removed by multiple consumers. Every time one of the producers or consumers adds or removes an 

element, the number of elements currently in the buffer is shown as a line of ‘*’ characters (see output 

sample on Moodle). Note that every producer/consumer has a unique Id assigned to them in the output. 

Similar to task1a, a correct implementation of this requirement includes: 

• A linked list of characters representing the bounded buffer utilised in the correct manner. The 

maximum size of this list should be configured to not exceed, e.g., 50 elements. 

• Multiple producer threads that generate a total number of MAX_NUMBER_OF_JOBS ‘*’ 

characters, and not more. That is, the number of elements produced by the different threads 

sums up to MAX_NUMBER_OF_JOBS. Elements are added to the buffer as soon as free spaces are 

available. Note that every producer may end up producing a different number of elements, 

depending on the way threads are interleaved, but that the total items produced should be equal 

to MAX_NUMBER_OF_JOBS. 

• A consumer function that removes elements from the start of the buffer using removeFirst (one 

at a time). 

• A mechanism to ensure that all consumers terminate gracefully when MAX_NUMBER_OF_JOBS 

have been consumed. 

• A visualisation function that displays the exact number of elements currently in the buffer (using 

a line of stars) on the screen every time an element is added to or removed from the buffer. 

• The code to: 

o Declare all necessary semaphores/mutexes and initialise them to the correct values. 

o Create the producer/consumer threads. 

o Join all threads with the main thread to prevent the main thread from finishing before 

the consumers/producers have ended. 

o Generate output similar in format to the example provided in this coursework (task1b.txt) 

for this requirement (for 100 jobs, using a buffer size of 10). 

Marking criteria:

The criteria used in the marking task1a and task1b of your coursework include: 

• Whether you have submitted the code and you are using the correct naming conventions and 

format. 

• Whether the code compiles correctly, and runs in an acceptable manner. 

• Whether you utilise and manipulate your linked list in the correct manner. 

• Whether semaphores/mutexes are correctly defined, initialised, and utilised. 

• Whether consumers and producers are joined correctly. 

• Whether the correct number of producers and consumers has been utilised, as specified in the 

coursework description. 

• Whether consumers and producers end gracefully/in a correct manner.

• Whether consumers/producers have been assigned a unique id (as can be seen from the output 

provided on Moodle). 

• Whether the exact number of elements is produced and consumed. 

• Whether your code is efficient, easy to understand, and allows for maximum parallelism (i.e. no 

unnecessary synchronisation is applied). 

• Whether unnecessary/inefficient/excessive busy waiting is used in your code. 

• Whether your code runs free of deadlocks.

• Whether the output generated by your code follows the format of the examples provided on 

Moodle.

Submission requirements: 

• Give your solutions extending the given code template task1a.c and task1b.c

• Name your output for the tasks “task1a.txt” and “task1b.txt” respectively. Please stick rigorously 

to the naming conventions, including capitalisation. 

• Add your task1a.c and task1b.c code files, as well as the output files task1a.txt and task1b.txt, to 

your submission folder. Include the provided linkedlist.c and linkedlist.h files in the submission 

folder as well.

• Your code must compile using (updated Nov28)

gcc -std=c99 task1a.c -o task1a linkedlist.c -pthread and 

gcc -std=c99 task1b.c -o task1b linkedlist.c -pthread on the school’s linux

servers. 

Task 2: Shared Memory (40 marks)

Use the knowledge you’ve obtained during the labs, finish the following question. You are asked to 

implement a solution for using shared memory for inter-process communication. Requirements of 

implementation are:

• A parent process (TASK2.c) that creates two new child processes;

• The process image of the two child processes is overwritten to execute ChildP1.c and ChildP2.c 

respectively.

• In TASK2.c, you are required to randomly generate an integer (RandInt) within the range of 1 to 

20 and print out the value of RandInt. The integer RandInt will be stored in shared memory with 

an appropriate structure for future usage.

• The ChildP1 will wait for a random amount of time and then double the value of RandInt. As soon 

as ChildP1 modified the RandInt, the other child process ChildP2 subtracting a value of 10 from 

the existing value.

• ChildP1 and ChildP2 need to take turn performing doubling and subtraction on RandInt 10 times. 

You are not permitted to use sleep() or any similar function to manually control the execution 

order of processes.

• Make sure that the ChildP2.c won’t be able to access to the RndInt before ChildP1.c finishes its 

task.

• Use shared memory to store all the values (intermediate results) of RandInt.

• Once all child processes have finished their tasks, the parent process needs to print out the value 

of RandInt at each instance.

• Your code must be compired using: (updated Dec 4)

gcc -lrt ChildP1.c -o ChildP1 -pthread 

gcc -lrt ChildP2.c -o ChildP2 -pthread 

gcc -lrt TASK2.c -o TASK2output -plhtread 

For this task, you are required to submit three files: TASK2.c, ChildP1.c and ChildP2.c

使用广播星历进行 GPS 卫星位置的计算 目录1.计算卫星运动的平均角速度 n2.计算观测瞬间卫星的近地点角3.计算偏近点角4.计算真近点角 f5.计算升交角距 6.计算摄动改正项7.进行摄动改正 8.计算卫星在轨道面坐标系中的位置9.计算观测瞬间升交点的经度 L10.计算卫星在瞬时地球坐标系中的位置11.计算卫星在协议地球坐标系中的位置使用广播星历进行GPS卫星位置的计算的详细步骤如下:关于在广播星历中各参数的分布情况可以参考下图:首先根据广播星历中给出的参数 计算参考时刻(TOE) 的平均角速度 式中,GM为万有引力常数 G 与地球总质量 阅读详情

相关推荐

认知网络分析实战:用Python复现课堂对话研究(含LSA代码)

本文通过Python实战,详细演示了如何运用认知网络分析(ENA)和滞后序列分析(LSA)两种方法,对课堂对话数据进行深度挖掘。文章提供了从数据清洗、行为编码到网络构建、序列统计及可视化的完整代码流程,帮助教育研究者和数据分析师量化分析对话中的认知结构与动态互动模式,从而获得超越文本表面的研究洞见。

weixin_28559803的博客 155

COMP2046 C/C++

Overviewmarks.helpfulFor task 1For task 2a time).format.Moodle.servers.

stratch5的博客 741

STM32F103C8T6+HX711实战:从零打造智能体重秤(附OLED显示与语音播报)

本文详细介绍了基于STM32F103C8T6微控制器和HX711称重模块,从零构建智能体重秤的完整实战教程。内容涵盖硬件选型、系统架构、驱动编写、数据滤波校准算法,并实现了OLED显示与语音播报功能。该项目是嵌入式学习的综合性实践,尤其适合作为毕业设计课题,帮助开发者掌握传感器应用、数据处理及人机交互等核心技能。

weixin_28285943的博客 520

InnoDB 内存结构总览:Change Buffer、AHI 与 Log Buffer

本文系统梳理InnoDB内存结构中的ChangeBuffer、Adaptive Hash Index(AHI)与LogBuffer。ChangeBuffer缓存二级索引页不在内存时的变更,减少随机IO,仅在页加载时合并;聚簇索引修改立即执行,因数据本身不可延后。AHI基于高频等值查询自动构建哈希索引,加速定位,仅支持等值操作。LogBuffer为redo log内存缓冲,配合磁盘日志实现崩溃恢复。三者均服务于性能优化,其中ChangeBuffer与AHI共享BufferPool空间,而LogBuffer独立

bksczm的博客 309

内网(极空间)搭建gitlab跳板机转发端口及域名配置

然后,回头尝试用内网地址+15022 clone,成功,用公网的ip+15222 clone失败,那就是定位到时nginx转发的问题了。首先想到的就是 git clone是通过ssh的22端口进行下载的,那就需要打通22端口,则又配置22端口的nginx转发。然后,我通过ssh命令,做一个端口转发,以实现内网穿透,将服务端口链接到跳板机上。然后穿透到阿里云服务器跳板机的端口,只能内网访问,需要用nginx做个转发,才能用公网ip进行访问。然后,如上,我的80端口,映射15080,22端口映射15022。

God丶Davide的博客 6078

达梦7实时主备集群

达梦7实时主备配置实时主备数据环境说明配置主库配置 dm.ini配置dmmal.ini配置dmarch.ini配置dmwatcher.ini配置dmwatcher.ini以mount方式启动主库设置OGUID修改数据库为primary模式配置备库 在服务器部署过程中,通常搭建有数据库主备集群,用于防备数据库服务器产生问题影响数据正常,在此,我们分享一下在虚拟机环境中模拟搭建实时主备的数据守护模式。 在搭建环境之前,需用户确认主备DM7的数据库已安装完成,且版本一致,同时还应注意各实例所在主机的操作系统位数、

g360382的博客 1022

信创环境下PageOffice文档控件适配与实践

信创适配做到文档控件这一层,拼的已经不是"有没有国产版本",而是同一个功能在两类终端上是否真的等价。等价的标准很具体:同一次点击能得到同样的结果,同一份公文能得到同样的版式,同一个项目不需要维护两套代码。这背后是三件并不轻松的工作:服务端用一套接口同时支撑两类终端,客户端把两种系统与四种芯片的安装包分发清楚,文档内核层由产品侧跟着 WPS 的版本走。浏览器这一层的压力,则被收进了产品自己的窗口里——升级节奏由产品掌握,不再交给运气。

zi_wu_xian的专栏 336

告别Failed to start错误!保姆级教程:用Ubuntu20.04安装盘搞定GRUB与系统服务修复

本文提供Ubuntu20.04系统启动失败的专业修复指南,详细讲解如何利用安装盘解决GRUB与系统服务问题,避免重装系统导致的数据丢失。涵盖分区挂载、chroot环境操作、服务诊断与修复等实用技巧,帮助用户高效恢复系统正常运行。

weixin_32578161的博客 332

第三篇 第 6 课

前置:第三篇第 1 课(stdx 引入),第二篇第 1 课(std.regex)。环境:仓颉 SDK 1.2.0。本文所有代码与输出均逐行实测。

weixin_41618057的博客 557

Comsol有限元网格剖分实战:从基础操作到高效仿真技巧

本文系统介绍了COMSOL有限元网格剖分的核心实战技巧。从基础的物理场控制与用户控制网格选择,到三角形、四边形、四面体等网格单元类型的适用场景,再到扫掠网格、边界层网格与复制网格等高效剖分方法,最后讲解了网格质量评估与几何预处理的关键步骤。旨在帮助用户掌握从自动到手动、从基础到高效的网格剖分艺术,实现仿真精度与计算效率的最佳平衡。

j7k8l的博客 377

⑤单细胞学习-cellchat组间通讯差异分析

参考:

hx2024的博客 1983

【从零理解 Spring AI · 12】MCP 的两种角色:做客户端还是做服务端

上一篇讲了 MCP 的概念:标准协议、三大角色、M+N 替代 M×N。

nice_lcj520的博客 614

R语言做一个 GM (1,1)灰色预测模型

累加生成是GM(1,1)模型的另一个重要步骤,它通过构造累加生成序列,把非线性非平稳时间序列转化为线性平稳时间序列。GM(1,1)是一种基于灰色系统理论的预测模型,通常用于中小样本的非线性、非平稳时间序列数据分析。灰色预测模型的核心是灰度处理,将原始时间序列转化为灰色时间序列。这里使用R语言中的diff函数对时间序列进行一次差分,然后对结果取累加和得到灰度序列。以上是GM(1,1)灰色预测模型在R语言中的实现步骤。需要注意的是,GM(1,1)模型适用于中小样本的时间序列预测,对于长期预测效果可能较差。

Mrrunsen的博客 3842

pcl2启动器下载(Minecraft PCL2 启动器 最新版 安装与使用说明)

摘要:PCL2(Plain Craft Launcher 2)是一款面向 Minecraft 的第三方启动器,支持正式版与快照版本管理、模组与整合包安装、Java 运行时自动匹配,绿色免安装、双击即可运行。适合在 Windows 上玩单机整合包、需要多版本共存或离线启动的用户使用

2611_96675819的博客 226

汉书HE8,好用的汇编代码编写工具

汉书HE8,好用的汇编代码编写工具早期编写汇编代码所用功能强大

C# WinForm 基于DirectShow.dll编写的程序,可边预览边保存视频,音频和图片

基于微软的DirectShow.dll的二次开发1.自动识别连接的摄像头跟麦克风且可以对其进行选择(默认选中第一个)2.可录制wmv和avi两种格式的视频并且都带有音频,avi可以录制的分辨率和帧数进行选择,wmv默认进行了淸晰度优化如不喜欢可去除代码中有相关提示3.可在预览点开之后进行拍照,也可边录制视频边拍照4.添加了视频和音频的压缩功能(酌情使用)这次二次开发发现C#对DirectShow的相关信息太少,这次做完也不敢藏私共享出来,还望大家指正

spring boot 4集成SQLLite,及其SQLLite的建库

spring boot 4集成SQLLite,及其SQLLite的建库

weixin_41463944的博客 231

霍尼韦尔SoftMaster使用说明

霍尼韦尔SoftMaster使用说明

Java 集合容器高频面试题全解:HashMap 树化阈值、1.7 死循环与 ConcurrentHashMap 演进(2026 招聘 JD 真题复盘)

HashMap 树化阈值 8 的泊松分布依据、退化阈值 6 的防抖设计、JDK 1.7 头插成环死循环的排查与修复、1.8 尾插后为何仍线程不安全、ConcurrentHashMap 放弃分段锁的原因与 ForwardingNode 协作扩容、computeIfAbsent 死锁陷阱、大集合找重复的场景题选型,附三层追问链自测。题目来源为 38 期公开招聘 JD 样本与字节、拼多多、建行、美团、快手公开面经。

蒙眼过河 427

Data-Structures-and-Algorithm-Analysis-in-Java.pdf

作者: Weiss, Mark A. 出版社: Addison Wesley Data Structures and Algorithm Analysis in Java is an “advanced algorithms” book that fits between traditional CS2 and Algorithms Analysis courses. In the old ACM Curriculum Guidelines, this course was known as CS7. This text is for readers who want to learn good programming and algorithm analysis skills simultaneously so that they can develop such programs with the maximum amo...

spdlog 同步日志库使用详解

spdlog是一个轻量级 C++ 日志库,支持同步日志、异步日志、多线程日志、日志文件轮转和自定义日志格式。对于嵌入式 Linux 应用开发,我建议先使用。它可以帮我们完成:日志级别过滤。时间戳和线程 ID 输出。日志格式化。终端和文件输出。多线程安全写入。日志文件按大小或时间轮转。我们不需要自己实现互斥锁、文件写入、日志格式化和轮转等底层功能。

zengjiajun2006的博客 1124

JavaSE通关手册:数据类型与变量

代码无需额外处理,编译时编译器自动完成转换。

xys_678的博客 236

IDEA 简介:从零认识 IntelliJ IDEA

IDEA 全称,是由 JetBrains 公司开发的一款主流 Java 集成开发环境(IDE)。它集代码编辑、编译、调试、测试、版本控制、构建管理等功能于一体,被大量 Java 开发者视为日常开发的首选工具。所谓 IDE(Integrated Development Environment,集成开发环境),就是把写代码所需的各类工具整合到同一个界面中。相比只用文本编辑器加命令行编译,IDE 能显著减少重复操作,让开发者把精力集中在业务逻辑上。

ztI10的博客 184

Docker部署linkding:HTTPS与数据备份

部署私人书签库,除了让页面能够打开,还需要考虑几个实际问题:重建容器后数据是否保留、登录和保存是否正常、升级前怎样备份,以及出现 502 或 CSRF 错误时从哪里检查。本文使用 Docker Compose 部署 linkding,采用默认 SQLite 数据库,通过 Caddy 提供 HTTPS,并完成账户创建、数据持久化验证和备份。如果重建后账户或书签消失,应先检查是否换了项目目录、改了挂载路径,或者启动了另一套实例,不要急着重新初始化。遇到权限问题,应根据日志确认具体目录和运行用户,再调整权限。

tedcloud123的博客 193

C++20协程怎么运行?原理与三大核心组件深度剖析

C++20协程是轻量级的无栈状态机,通过co_await、co_yield、co_return实现挂起与恢复,由Promise、协程句柄和Awaitable三大组件协同工作。协程与线程互补,适用于高效管理大量并发I/O任务,显著降低上下文切换开销。其核心在于编译器生成的状态机机制,需配合库(如cppcoro)使用。掌握Promise控制逻辑、句柄生命周期管理及Awaitable语义,是构建高性能异步程序的基础。

Lucis__的博客 335

动态代理两大流派:JDK 代理与子类代理

业务类想加日志,最直白的写法是侵入式修改: 问题很明显:每个方法都要改一遍,改一个业务要动十处。代理模式的解法是:调用方不直接依赖 ,而是依赖一个代理对象。代理对象长得跟目标一模一样,调用它 → 代理先执行增强逻辑 → 再转调真实对象。 关键在于:代理对象的类型是哪来的?这就是"动态"二字的含义:代理类在运行时才诞生。两个角色: 承载增强逻辑, 负责生成代理类。 组装代理并调用: 输出: 业务代码 一行没动,增强逻辑全在 里。这就是 AOP 的味道。 内部四步: 第 2 步 内部:先查 (同一个接口

Android的专栏 661

c++ explicit关键字详解

explicit。

拒绝AI文,努力在AI时代写出感动人心的好文章 169

Java 项目实战:交友项目后台系统——网关统一鉴权与 B 端管理后台

本次改造通过引入SpringCloud Gateway实现网关统一鉴权与路由,新建mf-admin管理端复用C端域服务(Dubbo调用),实现管理员登录与用户管理四件查询。核心套路:网关白名单+双体系JWT(同工具不同payload)、管理端零直连业务库、分页形态区分(MySQL自动count/Mongo手动count)、浏览器端独立聚合。踩坑12条,附自检清单与后续改造方向,可复用于多角色后台系统。

Wang的专栏 63

Teamcenter Java SOA 开发:连接、查询与保存

本文介绍如何通过 Java 调用 Teamcenter SOA 接口实现外部系统对接,涵盖连接登录、查询保存等核心操作。以最小闭环示例展示 Connection、Service、ModelObject 等关键组件的使用,强调错误处理与事务管理要点。梳理了 DataManagement、Query、File Management 等 API 模块分工,并结合“工作移交WebService”案例,说明幂等性设计与流程状态返回的重要性。适用于 Web 门户、ERP 集成等场景,建议批量操作用 bulk 接口优化性

软件工程师文艺 277

TRingBuffer两端都能增删(快递站版)

TRingBuffer 是一个支持两端增删、下标访问且容量动态增长的环形双端队列。它通过无符号索引的永不归零设计,利用减法自动模运算实现空满判断与元素计数,避免了传统环形缓冲浪费格子的问题。内部以票号(索引)标记首尾,扩容时重排元素为连续存储,保证 O(1) 操作与高缓存效率。虽不线程安全,但其高效性使其成为游戏开发中事件队列、命令缓冲等场景的理想选择。

u013768914的博客 315
上一篇: DTS207TC Database Development and Design
下一篇: SOCS0100 Computational Tools
wx____codehelp
博客等级 码龄2年 538粉丝 99原创
评论
成就一亿技术人!
拼手气红包6.0元
还能输入1000个字符
 
 条评论被折叠 查看
添加红包

请填写红包祝福语或标题

个

红包个数最小为10个

元

红包金额最低5元

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

抵扣说明:

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

余额充值