Browse Source

chore(starclass): deploy verified release to production

apple 2 weeks ago
parent
commit
4d2af84e2a

+ 39 - 0
docs/06_生产运维与部署/starclass_release_20261110/01_precheck.sql

@@ -0,0 +1,39 @@
+whenever sqlerror exit sql.sqlcode
+set pagesize 200
+set linesize 12000
+set feedback on
+set heading on
+alter session set container=ORCLPDB;
+
+prompt ===== 星级班正式发布前检查 =====
+
+select count(*) ACTIVE_CLASSES
+  from C##DC.BJ
+ where JLZTM in(51,22,25) and BJZTM<>81;
+
+select b.BJID,b.MC,b.JLZTM,b.BJZTM,b.ZYID
+  from C##DC.BJ b
+ where b.JLZTM in(51,22,25) and b.BJZTM<>81
+   and not exists(select 1 from C##DC.ZY z where z.ZYID=b.ZYID)
+ order by b.BJID;
+
+select 'XJB_PZ' OBJ from dual
+ where exists(select 1 from all_tables where owner='C##DC' and table_name='XJB_PZ')
+union all
+select 'XJB_PZMX' from dual
+ where exists(select 1 from all_tables where owner='C##DC' and table_name='XJB_PZMX')
+union all
+select 'XJB_JGMX' from dual
+ where exists(select 1 from all_tables where owner='C##DC' and table_name='XJB_JGMX')
+union all
+select 'XJB_JD.PZID' from dual
+ where exists(select 1 from all_tab_columns
+              where owner='C##DC' and table_name='XJB_JD'
+                and column_name='PZID');
+
+select count(*) JD_ROWS from C##DC.XJB_JD;
+select count(*) JG_ROWS from C##DC.XJB_JG;
+select count(*) PM_ROWS from C##DC.XJB_PM;
+select count(*) JFJL_ROWS from C##DC.XJB_JFJL;
+
+exit;

+ 48 - 0
docs/06_生产运维与部署/starclass_release_20261110/02_backup.sql

@@ -0,0 +1,48 @@
+whenever sqlerror exit sql.sqlcode rollback
+set serveroutput on
+alter session set container=ORCLPDB;
+
+declare
+    v_count number;
+
+    procedure assert_absent(p_name varchar2) is
+    begin
+        select count(*) into v_count
+          from all_tables
+         where owner='C##DC' and table_name=p_name;
+        if v_count<>0 then
+            raise_application_error(-20001,
+                '备份表已存在,停止覆盖:' || p_name);
+        end if;
+    end;
+begin
+    assert_absent('BAK_20261110_PROD_STAR_JD');
+    assert_absent('BAK_20261110_PROD_STAR_JG');
+    assert_absent('BAK_20261110_PROD_STAR_PM');
+    assert_absent('BAK_20261110_PROD_STAR_JFJL');
+
+    execute immediate
+        'create table C##DC.BAK_20261110_PROD_STAR_JD as '
+        || 'select * from C##DC.XJB_JD';
+    execute immediate
+        'create table C##DC.BAK_20261110_PROD_STAR_JG as '
+        || 'select * from C##DC.XJB_JG';
+    execute immediate
+        'create table C##DC.BAK_20261110_PROD_STAR_PM as '
+        || 'select * from C##DC.XJB_PM';
+    execute immediate
+        'create table C##DC.BAK_20261110_PROD_STAR_JFJL as '
+        || 'select * from C##DC.XJB_JFJL';
+end;
+/
+
+select 'XJB_JD' TABLE_NAME,count(*) ROWS_CNT
+  from C##DC.BAK_20261110_PROD_STAR_JD
+union all
+select 'XJB_JG',count(*) from C##DC.BAK_20261110_PROD_STAR_JG
+union all
+select 'XJB_PM',count(*) from C##DC.BAK_20261110_PROD_STAR_PM
+union all
+select 'XJB_JFJL',count(*) from C##DC.BAK_20261110_PROD_STAR_JFJL;
+
+exit;

+ 211 - 0
docs/06_生产运维与部署/starclass_release_20261110/03_ddl.sql

@@ -0,0 +1,211 @@
+whenever sqlerror exit sql.sqlcode rollback
+set serveroutput on
+alter session set container=ORCLPDB;
+
+prompt ===== 星级班配置版本与月结指标明细 =====
+
+declare
+    v_count number;
+    v_pzid number;
+
+    procedure add_column(
+        p_table varchar2,
+        p_column varchar2,
+        p_definition varchar2
+    ) is
+    begin
+        select count(*) into v_count
+          from all_tab_columns
+         where owner='C##DC'
+           and table_name=p_table and column_name=p_column;
+        if v_count=0 then
+            execute immediate 'alter table C##DC.' || p_table
+                || ' add ' || p_column || ' ' || p_definition;
+        end if;
+    end;
+begin
+    add_column('XJB_JD', 'PZID', 'number');
+
+    select count(*) into v_count from all_tables
+     where owner='C##DC' and table_name='XJB_PZ';
+    if v_count=0 then
+        execute immediate '
+            create table C##DC.XJB_PZ(
+                PZID number primary key,
+                PZBB varchar2(32) not null,
+                MC varchar2(100) not null,
+                KSRQ date not null,
+                JSRQ date,
+                JLZTM number not null,
+                SM varchar2(500),
+                CJSJ date not null
+            )';
+        execute immediate
+            'create unique index C##DC.UX_XJB_PZ_BB on C##DC.XJB_PZ(PZBB)';
+    end if;
+
+    select count(*) into v_count from all_tables
+     where owner='C##DC' and table_name='XJB_PZMX';
+    if v_count=0 then
+        execute immediate '
+            create table C##DC.XJB_PZMX(
+                PZMXID number primary key,
+                PZID number not null,
+                XMLB varchar2(20) not null,
+                XMBM varchar2(32) not null,
+                XMMC varchar2(100) not null,
+                ZBZ number(12,4),
+                SM varchar2(500),
+                CJSJ date not null
+            )';
+        execute immediate
+            'create unique index C##DC.UX_XJB_PZMX_BM on C##DC.XJB_PZMX(PZID,XMLB,XMBM)';
+    end if;
+
+    select count(*) into v_count from all_tables
+     where owner='C##DC' and table_name='XJB_JGMX';
+    if v_count=0 then
+        execute immediate '
+            create table C##DC.XJB_JGMX(
+                JGMXID number primary key,
+                XJB_JDID number not null,
+                XJB_JGID number not null,
+                BJID number not null,
+                NDY varchar2(7) not null,
+                XMBM varchar2(32) not null,
+                XMMC varchar2(100) not null,
+                YSZ number(12,4),
+                QZ number(8,4),
+                DF number(12,4),
+                LYLX varchar2(32),
+                SM varchar2(1000),
+                SX number not null,
+                CJRYID number,
+                CJBM_ID number,
+                JLSJ date not null
+            )';
+        execute immediate
+            'create index C##DC.IX_XJB_JGMX_JD on C##DC.XJB_JGMX(XJB_JDID,BJID,SX)';
+        execute immediate
+            'create unique index C##DC.UX_XJB_JGMX_ITEM on C##DC.XJB_JGMX(XJB_JGID,XMBM)';
+    end if;
+
+    select count(*) into v_count from all_sequences
+     where sequence_owner='C##DC' and sequence_name='XJB_PZID';
+    if v_count=0 then
+        execute immediate
+            'create sequence C##DC.XJB_PZID start with 1 increment by 1 nocache';
+    end if;
+    select count(*) into v_count from all_sequences
+     where sequence_owner='C##DC' and sequence_name='XJB_PZMXID';
+    if v_count=0 then
+        execute immediate
+            'create sequence C##DC.XJB_PZMXID start with 1 increment by 1 nocache';
+    end if;
+    select count(*) into v_count from all_sequences
+     where sequence_owner='C##DC' and sequence_name='XJB_JGMXID';
+    if v_count=0 then
+        execute immediate
+            'create sequence C##DC.XJB_JGMXID start with 1 increment by 1 nocache';
+    end if;
+end;
+/
+
+declare
+    v_count number;
+    v_pzid number;
+begin
+    select count(*) into v_count from C##DC.XJB_PZ
+     where PZBB='SC-2024-10-V1';
+    if v_count=0 then
+        select C##DC.XJB_PZID.nextval into v_pzid from dual;
+        insert into C##DC.XJB_PZ(
+            PZID,PZBB,MC,KSRQ,JSRQ,JLZTM,SM,CJSJ
+        ) values(
+            v_pzid,'SC-2024-10-V1','星级班评分口径2024-10版',
+            date '2024-10-01',null,51,
+            '第三方公式版本B:考勤15%、风纪20%、清洁18%、升旗14%、宿舍20%、课堂5%;团体封顶3;总增分封顶8。',
+            sysdate
+        );
+    else
+        select PZID into v_pzid from C##DC.XJB_PZ
+         where PZBB='SC-2024-10-V1';
+    end if;
+
+    insert into C##DC.XJB_PZMX(PZMXID,PZID,XMLB,XMBM,XMMC,ZBZ,SM,CJSJ)
+    select C##DC.XJB_PZMXID.nextval,v_pzid,'WEIGHT','DORM','宿舍评分',0.2000,
+           '常规项权重',sysdate from dual
+     where not exists (select 1 from C##DC.XJB_PZMX
+                        where PZID=v_pzid and XMLB='WEIGHT' and XMBM='DORM');
+    insert into C##DC.XJB_PZMX(PZMXID,PZID,XMLB,XMBM,XMMC,ZBZ,SM,CJSJ)
+    select C##DC.XJB_PZMXID.nextval,v_pzid,'WEIGHT','CLASSROOM','课堂考核',0.0500,
+           '常规项权重',sysdate from dual
+     where not exists (select 1 from C##DC.XJB_PZMX
+                        where PZID=v_pzid and XMLB='WEIGHT' and XMBM='CLASSROOM');
+    insert into C##DC.XJB_PZMX(PZMXID,PZID,XMLB,XMBM,XMMC,ZBZ,SM,CJSJ)
+    select C##DC.XJB_PZMXID.nextval,v_pzid,'WEIGHT','FLAG','升旗礼',0.1400,
+           '常规项权重',sysdate from dual
+     where not exists (select 1 from C##DC.XJB_PZMX
+                        where PZID=v_pzid and XMLB='WEIGHT' and XMBM='FLAG');
+    insert into C##DC.XJB_PZMX(PZMXID,PZID,XMLB,XMBM,XMMC,ZBZ,SM,CJSJ)
+    select C##DC.XJB_PZMXID.nextval,v_pzid,'WEIGHT','CLEANING','清洁卫生',0.1800,
+           '常规项权重',sysdate from dual
+     where not exists (select 1 from C##DC.XJB_PZMX
+                        where PZID=v_pzid and XMLB='WEIGHT' and XMBM='CLEANING');
+    insert into C##DC.XJB_PZMX(PZMXID,PZID,XMLB,XMBM,XMMC,ZBZ,SM,CJSJ)
+    select C##DC.XJB_PZMXID.nextval,v_pzid,'WEIGHT','DISCIPLINE','风纪仪容',0.2000,
+           '常规项权重',sysdate from dual
+     where not exists (select 1 from C##DC.XJB_PZMX
+                        where PZID=v_pzid and XMLB='WEIGHT' and XMBM='DISCIPLINE');
+    insert into C##DC.XJB_PZMX(PZMXID,PZID,XMLB,XMBM,XMMC,ZBZ,SM,CJSJ)
+    select C##DC.XJB_PZMXID.nextval,v_pzid,'WEIGHT','ATTENDANCE','考勤',0.1500,
+           '常规项权重',sysdate from dual
+     where not exists (select 1 from C##DC.XJB_PZMX
+                        where PZID=v_pzid and XMLB='WEIGHT' and XMBM='ATTENDANCE');
+
+    insert into C##DC.XJB_PZMX(PZMXID,PZID,XMLB,XMBM,XMMC,ZBZ,SM,CJSJ)
+    select C##DC.XJB_PZMXID.nextval,v_pzid,'CAP','TEAM_BONUS','学生团体增分封顶',3,
+           '先封顶团体,再与其他增分合并',sysdate from dual
+     where not exists (select 1 from C##DC.XJB_PZMX
+                        where PZID=v_pzid and XMLB='CAP' and XMBM='TEAM_BONUS');
+    insert into C##DC.XJB_PZMX(PZMXID,PZID,XMLB,XMBM,XMMC,ZBZ,SM,CJSJ)
+    select C##DC.XJB_PZMXID.nextval,v_pzid,'CAP','TOTAL_BONUS','总增分封顶',8,
+           '最终增分封顶',sysdate from dual
+     where not exists (select 1 from C##DC.XJB_PZMX
+                        where PZID=v_pzid and XMLB='CAP' and XMBM='TOTAL_BONUS');
+
+    insert into C##DC.XJB_PZMX(PZMXID,PZID,XMLB,XMBM,XMMC,ZBZ,SM,CJSJ)
+    select C##DC.XJB_PZMXID.nextval,v_pzid,'THRESHOLD','FIVE_MIN','五星级下限',90,
+           '第三方口径为大于90',sysdate from dual
+     where not exists (select 1 from C##DC.XJB_PZMX
+                        where PZID=v_pzid and XMLB='THRESHOLD' and XMBM='FIVE_MIN');
+    insert into C##DC.XJB_PZMX(PZMXID,PZID,XMLB,XMBM,XMMC,ZBZ,SM,CJSJ)
+    select C##DC.XJB_PZMXID.nextval,v_pzid,'THRESHOLD','FOUR_MIN','四星级下限',80,
+           '第三方口径为大于80',sysdate from dual
+     where not exists (select 1 from C##DC.XJB_PZMX
+                        where PZID=v_pzid and XMLB='THRESHOLD' and XMBM='FOUR_MIN');
+    insert into C##DC.XJB_PZMX(PZMXID,PZID,XMLB,XMBM,XMMC,ZBZ,SM,CJSJ)
+    select C##DC.XJB_PZMXID.nextval,v_pzid,'THRESHOLD','THREE_MIN','三星级下限',75,
+           '第三方口径为大于75',sysdate from dual
+     where not exists (select 1 from C##DC.XJB_PZMX
+                        where PZID=v_pzid and XMLB='THRESHOLD' and XMBM='THREE_MIN');
+    insert into C##DC.XJB_PZMX(PZMXID,PZID,XMLB,XMBM,XMMC,ZBZ,SM,CJSJ)
+    select C##DC.XJB_PZMXID.nextval,v_pzid,'THRESHOLD','TWO_MIN','二星级下限',65,
+           '第三方口径为大于65',sysdate from dual
+     where not exists (select 1 from C##DC.XJB_PZMX
+                        where PZID=v_pzid and XMLB='THRESHOLD' and XMBM='TWO_MIN');
+    insert into C##DC.XJB_PZMX(PZMXID,PZID,XMLB,XMBM,XMMC,ZBZ,SM,CJSJ)
+    select C##DC.XJB_PZMXID.nextval,v_pzid,'THRESHOLD','ONE_MIN','一星级下限',55,
+           '第三方口径为大于55',sysdate from dual
+     where not exists (select 1 from C##DC.XJB_PZMX
+                        where PZID=v_pzid and XMLB='THRESHOLD' and XMBM='ONE_MIN');
+
+    commit;
+end;
+/
+
+select PZID,PZBB,MC,KSRQ,JSRQ,JLZTM from C##DC.XJB_PZ;
+select XMLB,count(*) CNT from C##DC.XJB_PZMX
+ where PZID=(select PZID from C##DC.XJB_PZ where PZBB='SC-2024-10-V1')
+ group by XMLB order by XMLB;
+exit;

+ 39 - 0
docs/06_生产运维与部署/starclass_release_20261110/04_verify.sql

@@ -0,0 +1,39 @@
+whenever sqlerror exit sql.sqlcode
+set pagesize 200
+set linesize 12000
+set feedback on
+set heading on
+alter session set container=ORCLPDB;
+
+prompt ===== 发布后结构验证 =====
+
+select 'XJB_PZ' OBJ from dual
+ where exists(select 1 from all_tables where owner='C##DC' and table_name='XJB_PZ')
+union all
+select 'XJB_PZMX' from dual
+ where exists(select 1 from all_tables where owner='C##DC' and table_name='XJB_PZMX')
+union all
+select 'XJB_JGMX' from dual
+ where exists(select 1 from all_tables where owner='C##DC' and table_name='XJB_JGMX')
+union all
+select 'XJB_JD.PZID' from dual
+ where exists(select 1 from all_tab_columns
+              where owner='C##DC' and table_name='XJB_JD'
+                and column_name='PZID');
+
+select PZID,PZBB,MC,KSRQ,JSRQ,JLZTM from C##DC.XJB_PZ;
+select XMLB,count(*) CNT from C##DC.XJB_PZMX
+ group by XMLB order by XMLB;
+
+select
+    (select count(*) from C##DC.XJB_JD) CUR_JD,
+    (select count(*) from C##DC.BAK_20261110_PROD_STAR_JD) BAK_JD,
+    (select count(*) from C##DC.XJB_JG) CUR_JG,
+    (select count(*) from C##DC.BAK_20261110_PROD_STAR_JG) BAK_JG,
+    (select count(*) from C##DC.XJB_PM) CUR_PM,
+    (select count(*) from C##DC.BAK_20261110_PROD_STAR_PM) BAK_PM,
+    (select count(*) from C##DC.XJB_JFJL) CUR_JFJL,
+    (select count(*) from C##DC.BAK_20261110_PROD_STAR_JFJL) BAK_JFJL
+  from dual;
+
+exit;

+ 28 - 0
docs/06_生产运维与部署/starclass_release_20261110/05_rollback.sql

@@ -0,0 +1,28 @@
+-- 仅在尚未由新代码生成任何 XJB_JGMX/新版本月结时执行。
+-- 已生成新批次时,应先保留审计数据,不得直接运行本脚本。
+
+whenever sqlerror exit sql.sqlcode rollback
+set serveroutput on
+alter session set container=ORCLPDB;
+
+declare
+    v_count number;
+begin
+    select count(*) into v_count from C##DC.XJB_JGMX;
+    if v_count<>0 then
+        raise_application_error(-20002,
+            'XJB_JGMX 已有数据,禁止自动回滚');
+    end if;
+end;
+/
+
+drop table C##DC.XJB_JGMX purge;
+drop table C##DC.XJB_PZMX purge;
+drop table C##DC.XJB_PZ purge;
+drop sequence C##DC.XJB_JGMXID;
+drop sequence C##DC.XJB_PZMXID;
+drop sequence C##DC.XJB_PZID;
+
+alter table C##DC.XJB_JD drop column PZID;
+
+exit;

+ 248 - 0
docs/06_生产运维与部署/starclass_release_20261110/06_实施记录.md

@@ -0,0 +1,248 @@
+# 星级班正式环境代码同步实施记录
+
+> 实施日期:2026-11-10
+>
+> 正式集群:`feifan-pms`
+>
+> 正式 Schema:`C##DC`
+>
+> 源码基线:`b70344f`
+
+## 1. 发布结论
+
+星级班最新代码和必要数据库对象已同步到正式环境。
+
+```text
+数据库 DDL:成功
+Java 编译:成功
+class 覆盖:成功
+SerCfg:成功
+Tomcat 滚动重启:成功
+PC 月结总表接口冒烟:成功
+历史 2025-01 月结数据:未变化
+2026-09 数据导入:未执行
+2026-10 正式月结:未执行
+```
+
+新 Pod:
+
+```text
+tomcat-pms-84b756d975-h4jm9
+1/1 Running
+```
+
+## 2. 发布前备份
+
+### 2.1 代码和配置备份
+
+```text
+/home/sxlg/starclass_prod_code_backup_20261110.tgz
+sha256=c1ab21d93ec9d97e37d70973681eb84448dd42ea22504f7fb100d4eec051402b
+size=79K
+entries=30
+```
+
+包含:
+
+```text
+XjbMonthCloseServ*.class
+BjStarClassMpServ*.class
+XjbJfServ*.class
+XjbJdPo.class
+xjbMonth.serv.xml
+xjbJf.timer.xml
+bj.page.xml
+ssnwjc_starClassSummary.jsp
+```
+
+### 2.2 数据库备份
+
+```text
+BAK_20261110_PROD_STAR_JD       1 行
+BAK_20261110_PROD_STAR_JG       1 行
+BAK_20261110_PROD_STAR_PM       1 行
+BAK_20261110_PROD_STAR_JFJL  1152 行
+```
+
+### 2.3 源码发布包
+
+```text
+/home/sxlg/starclass_release_src_20261110.tgz
+sha256=5732ede8d6ea9e7387d44f737ad754427480ac14d94fae79b9261fb0b92fed04
+```
+
+## 3. 数据库对象
+
+已创建:
+
+```text
+XJB_PZ
+XJB_PZMX
+XJB_JGMX
+sequence XJB_PZID
+sequence XJB_PZMXID
+sequence XJB_JGMXID
+```
+
+已增加:
+
+```text
+XJB_JD.PZID
+```
+
+已初始化:
+
+```text
+PZID=1
+PZBB=SC-2024-10-V1
+权重=6 条
+封顶=2 条
+星级阈值=5 条
+```
+
+当前状态:
+
+```text
+XJB_PZ=1
+XJB_PZMX=13
+XJB_JGMX=0
+XJB_JD=1
+XJB_JD.PZID 非空行=0
+```
+
+现有 `2025-01` 批次没有改写。
+
+## 4. Java 发布内容
+
+以下源码在正式 Pod 内使用 JDK 21 编译:
+
+```text
+src/base/po/XjbJdPo.java
+src/base/po/XjbPzPo.java
+src/base/po/XjbPzMxPo.java
+src/base/po/XjbJgmxPo.java
+src/biz/bj/XjbMonthCloseServ.java
+src/biz/bj/BjStarClassMpServ.java
+src/biz/bj/XjbJfServ.java
+```
+
+编译结果:
+
+```text
+COMPILE_OK
+29 个 class
+```
+
+正式 Pod 中关键 class SHA256:
+
+```text
+XjbMonthCloseServ.class  6944b8b1fcb98bcbaefeeba2e8b6683c998b1cc375c07ebb651d463aec82c074
+BjStarClassMpServ.class   df654dad6544c727ccbd53c3c44b52c914d5210ed37488d4c5b42f36b12d84cd
+XjbJfServ.class           4064679d533d92500834b2eafa40e7e7ddaa86fe134b72235d0b811a4d47a9e1
+XjbJdPo.class             a31d9ba4aacff4285f41008b66fe41f896b74f52d6dc6a0e37c0a55fdeb68eaa
+XjbPzPo.class             e5c614e3956162d44e539ff07459814357c685454179eae4617dfac7ea339659
+XjbPzMxPo.class           04a052f6893e5291a418e2e50695f3cebc30dbaff4d317ab97e69e7d90145d96
+XjbJgmxPo.class           c0c9989a36c864b652c1fa61d06be8cb873320321e519afe950461efce4e7741
+```
+
+`javap` 已确认正式 `XjbMonthCloseServ` 包含:
+
+```text
+rdImportedClasses
+calculateImported
+rdFormulaPzId
+insertResultDetail
+```
+
+## 5. 发布后验证
+
+配置编译:
+
+```text
+/SerCfg.jsp
+HTTP 200
+Serialize ConfigFile SUCCEED!!
+```
+
+基础页面:
+
+```text
+/             HTTP 200
+/fstLogin.jsp HTTP 200
+/home.jsp     HTTP 200
+```
+
+PC 月结总表:
+
+```text
+接口:xjbMonth_pcSummary
+月份:2025-01
+HTTP:200
+ssCode:0
+返回班级:1
+批次:1
+```
+
+数据库备份表与源表行数一致:
+
+```text
+XJB_JD=1 / BAK=1
+XJB_JG=1 / BAK=1
+XJB_PM=1 / BAK=1
+XJB_JFJL=1152 / BAK=1152
+```
+
+## 6. 本次未执行
+
+```text
+未导入第三方 2026-09 数据
+未生成 2026-09 正式批次
+未生成 2026-10 正式批次
+未修改正式菜单和岗位权限
+未修改页面 JSP
+未删除或修复正式历史数据
+```
+
+当前正式库仍只有原来的:
+
+```text
+2025-01 / 部门批次 / 1 个班
+```
+
+## 7. 已知遗留
+
+`SerCfg.jsp` 执行时日志仍会扫描到若干 macOS 上传残留文件,例如:
+
+```text
+cfg/biz/**/._*.xml
+WEB-INF/classes/**/._*.class
+```
+
+这些旁路文件会触发 `Content is not allowed in prolog` 或注解扫描警告,但本次:
+
+```text
+SerCfg 返回 SUCCEED
+PC 总表接口正常
+基础页面正常
+```
+
+该问题是已有部署残留,不属于本次 class 同步内容;后续可单独清理,但不得在未核对的情况下批量删除正式配置目录。
+
+正式启用月结前仍需处理:
+
+```text
+BJID=40211005 测试班缺少专业关系
+2026-10 课堂、升旗礼、清洁卫生和宿舍评分源数据为空
+```
+
+## 8. 回滚
+
+如果尚未由新代码生成任何 `XJB_JGMX` 数据:
+
+1. 解包 `/home/sxlg/starclass_prod_code_backup_20261110.tgz`;
+2. 恢复备份中的 class、XML 和 JSP;
+3. 执行 `05_rollback.sql`;
+4. 执行 `/SerCfg.jsp`;
+5. 滚动重启 `tomcat-pms`。
+
+如果已经生成新批次或 `XJB_JGMX` 数据,不得直接执行自动回滚脚本,应保留正式结果和审计数据后单独处理。

+ 107 - 0
docs/06_生产运维与部署/starclass_release_20261110/README.md

@@ -0,0 +1,107 @@
+# 星级班正式环境增量发布包
+
+> 发布日期:2026-11-10
+>
+> 正式 Schema:`C##DC`
+>
+> 源码基线:`b70344f`
+>
+> 目标:同步测试环境已验证的星级班月结、配置版本、月结明细、星级边界和第三方导入计算能力。
+
+## 1. 本次范围
+
+发布 Java:
+
+```text
+src/base/po/XjbJdPo.java
+src/base/po/XjbPzPo.java
+src/base/po/XjbPzMxPo.java
+src/base/po/XjbJgmxPo.java
+src/biz/bj/XjbMonthCloseServ.java
+src/biz/bj/BjStarClassMpServ.java
+src/biz/bj/XjbJfServ.java
+```
+
+数据库:
+
+```text
+XJB_PZ
+XJB_PZMX
+XJB_JGMX
+XJB_JD.PZID
+sequence XJB_PZID
+sequence XJB_PZMXID
+sequence XJB_JGMXID
+```
+
+不修改:
+
+```text
+菜单
+岗位权限
+页面 JSP
+bj.page.xml
+xjbMonth.serv.xml
+xjbJf.timer.xml
+现有月结数据
+正式源业务数据
+```
+
+本次不导入 2026-09 数据,不生成 2026-10 正式月结,不执行正式定时月结。
+
+## 2. 发布前备份
+
+代码备份:
+
+```text
+/home/sxlg/starclass_prod_code_backup_20261110.tgz
+```
+
+数据库备份表:
+
+```text
+BAK_20261110_PROD_STAR_JD
+BAK_20261110_PROD_STAR_JG
+BAK_20261110_PROD_STAR_PM
+BAK_20261110_PROD_STAR_JFJL
+```
+
+发布前必须确认备份文件存在、SHA256 已记录,数据库备份行数与源表一致。
+
+## 3. 执行顺序
+
+1. 执行 `01_precheck.sql`。
+2. 执行 `02_backup.sql`。
+3. 备份正式 class 和配置。
+4. 在正式 Pod 内用当前 JDK 编译白名单 Java。
+5. 执行 `03_ddl.sql`。
+6. 只复制本次白名单 class。
+7. 执行 `/SerCfg.jsp`。
+8. 滚动重启 `tomcat-pms`。
+9. 执行 `04_verify.sql`。
+10. 对 PC 总表、历史月结读取和相邻页面做冒烟。
+
+## 4. 发布后状态
+
+本次发布只同步代码和必要结构,不代表启用正式星级班月结。
+
+正式 2026-10 的课堂、升旗礼、清洁卫生和宿舍评分源数据仍为空,自动月结如执行会因数据不完整而失败,不会发布错误批次。
+
+正式库当前还存在:
+
+```text
+BJID=40211005 PMS测试班主任B班(勿用于教学)
+```
+
+该班无专业关系,正式启用前应停用或补齐专业关系。
+
+## 5. 回滚
+
+如果仅代码或 DDL 发布失败,且尚未产生新批次:
+
+1. 恢复代码备份包。
+2. 执行 `05_rollback.sql`。
+3. 执行 `/SerCfg.jsp`。
+4. 重启 `tomcat-pms`。
+
+如果已经生成新批次,不得直接删除列或新表,应先保留批次和审计数据,再单独制定数据回滚方案。