Friday, 20 January 2017

ATG BCC Info


0)  The following ATG OOTB  modules will be used for BCC setup
 
DafEar.Admin,DCS-UI.Versioned, BIZUI, PubPortlet,DCS-UI.SiteAdmin.Versioned, SiteAdmin.Versioned,\
DCS.Versioned, DCS-UI, DAF.Endeca.Index.Versioned, DCS.Endeca.Index.Versioned, DCS.Endeca.Index.SKUIndexing,


1)Before doing BCC setup , we have to delete the following table in the  PUB schema.These scripts are already verified.


delete from DSI_SERVER_ID;
delete from DSS_SERVER_ID;
delete from EPUB_WF_SERVER_ID;
delete from EPUB_PROC_TASKINFO;
delete from EPUB_WORKFLOW_STRS;
delete from  epub_workflow_info;
delete  from epub_coll_workflow;
delete from EPUB_IND_WORKFLOW;

2)Agents removing at DB level.

 The following scripts removes the agents at DB level and verified also.

delete from EPUB_TR_AGENTS;
delete from EPUB_TARGET;
delete from EPUB_TL_TARGETS;
delete from EPUB_PRJ_TG_SNSHT;
delete from EPUB_PR_HISTORY;
delete from EPUB_AGENT_TRNPRT;
delete from EPUB_INCLUD_ASSET;
delete from EPUB_PRINC_ASSET;
delete from EPUB_AGENT;
delete from EPUB_PR_TG_STATUS;


3) Identify the project which modifies the asset using asset id(DB Script)

Script :: Need to run the below script at BCC DB

select workspace_id from dcs_sku where sku_id='733688474'
select * from avm_devline where id=14473
select * from epub_project where project_id='prj33181'


4) By pass the stage server in BCC


Generally, it will be used in Local system so that we can use only one set of schemas.

1)How to by pass the stage server in BCC ?
1) We have to remove the work flow from DB and on starting the server it will populate available work flow.
2) We have to remove the staging layer from run assembler. IN xx we have to remove from deploy-weblogic.xml file. (from local layer as well as from layer staging.) Build is required on removing this and also in server startup script also we have to remove.The file may be vary for different projects.Generally these arguments will be available where runAssember is invoking as part of build.

  <arg value="-layer"/>
  <arg value="staging"/>


5) REGISTER WORKFLOW DIRECTORY

If the we create the new workflow with different directory (other than /common) We are not ablet to see the project assets and state. So we need to override the CommerceActivitySource.properties initalize the workflow directory

workflowDirectories+=/feed/*


6) Fetch the all conflict projects


select * from epub_project where workspace in
(select name from avm_devline where id in
(select workspace_id from avm_asset_lock))

7) Find all conflicting projects for a particular asset

select * from epub_project where workspace in
(select name from avm_devline where id in
(select workspace_id from dcs_category where category_id = 'cat1234' and category_id in
(select repository_id from avm_asset_lock where descriptor_name='category')))



8) Finding project and workspace name based on product/asset

select * from dcs_product where product_id = '12345C' and is_head=1
select * from avm_workspace where ws_id in ('34114','34760','34760')
select * from epub_project where workspace in ('epub-prj229006','epub-prj234026')


9) Project State Change to Author


By executing the following scripts, we can change project state means move author state.
-- remove asset locks on the project. if any
delete from avm_asset_lock where workspace_id =
(select id from avm_devline where name =
(select workspace from epub_project where project_id = 'prj49001'));

-- change states. Locked to false and editable to true
--   locked to 0 and editable to 1
update epub_project
set locked=0
where project_id = 'prj49001';

update epub_project
set editable=1
where project_id = 'prj49001';

-- change states. Locked to false and editable to true
--   locked to 0 and editable to 1
update avm_workspace
set locked=0
where ws_id =
(select id from avm_devline where name =
(select workspace from epub_project where project_id = 'prj49001'));

update avm_workspace
set editable=1
where ws_id =
(select id from avm_devline where name =
(select workspace from epub_project where project_id = 'prj49001'));

-- finally change state to author which is 3 for all workflows
update epub_ind_workflow
set state=3
where process_id =
(select process_id from epub_process where project='prj49001');
commit;
Invalidate below repository caches after executing the above scripts
/atg/epub/PublishingRepository/
/atg/epub/version/VersionManagerRepository/



10) Complete Project delete from versioned

  Need to check this

-- Removing locks of the project if any
delete from avm_asset_lock where workspace_id in
(select id from avm_devline where name in
(select workspace from epub_project where project_id = '<Your Project ID>'));

-- delete history of the project
delete from EPUB_PR_HISTORY where project_id in
(select project_id from epub_project where project_id = '<Your Project ID>');

-- delete the project
delete from epub_project where project_id = '<Your Project ID>';

-- delete history of the process
delete from EPUB_PROC_HISTORY where process_id in
(select process_id from epub_process where project = '<Your Project ID>');

-- delete task information of process
delete from EPUB_PROC_TASKINFO where id in
(select process_id from epub_process where project = '<Your Project ID>');

-- delete states of project (if any)
delete from EPUB_WORKFLOW_STRS where id in
(select ID from EPUB_IND_WORKFLOW where process_id in
(select process_id from epub_process where project = '<Your Project ID>'));

delete  from EPUB_IND_WORKFLOW where process_id in
(select process_id from epub_process where project = '<Your Project ID>');

-- finally delete the process
delete from epub_process where project = '<Your Project ID>';

 

11) DELET LOCKED / ENTIRE PROJECT

 Need to validate the following one.

If the project has been locked or not in any states . Need to delete the following workflow or project using following Query:

If BCC instance is bounced while deploying a project to staging
we can get back the project previous state so that we can start from Author state


-- remove asset locks on the project. if any
delete from avm_asset_lock where workspace_id =
(select id from avm_devline where name =
(select workspace from epub_project where project_id = 'prj49001'));

-- change states. Locked to false and editable to true
-- locked to 0 and editable to 1
update epub_project
set locked=0
where project_id = 'prj49001';

update epub_project
set editable=1
where project_id = 'prj49001';

-- change states. Locked to false and editable to true
-- locked to 0 and editable to 1
update avm_workspace
set locked=0
where ws_id =
(select id from avm_devline where name =
(select workspace from epub_project where project_id = 'prj49001'));

update avm_workspace
set editable=1
where ws_id =
(select id from avm_devline where name =
(select workspace from epub_project where project_id = 'prj49001'));

-- finally change state to author which is 3 for all workflows
update epub_ind_workflow
set state=3
where process_id =
(select process_id from epub_process where project='prj49001');
commit;

Invalidate below repository caches
/atg/epub/PublishingRepository/


If BCC instance is bounced while deploying a project to production
we can get back the project previous state so that we can redeploy to
production.
-If project with workflow editCommerceAssets.wdl
--stuck while deploying to production

update epub_ind_workflow
set state=11
where process_id =
(select process_id from epub_process where project = 'prj49001');
commit;

-- For projects which are created by auto import workflow

-- If project with /Commerce/autoImportAssets.wdl workflow
-- stuck while production

update epub_ind_workflow
set state=10
where process_id =
(select process_id from epub_process where project = 'prj49001');
commit;

Invalidate only /atg/epub/PublishingRepository/


Completely delete a project
-- Removing locks of the project if any
delete from avm_asset_lock where workspace_id in
(select id from avm_devline where name in
(select workspace from epub_project where project_id = 'prj243002'))

-- delete history of the project
delete from EPUB_PR_HISTORY where project_id in
(select project_id from epub_project where project_id = 'prj243002');

-- delete the project
delete from epub_project where project_id = 'prj243002';

-- delete history of the process
delete from EPUB_PROC_HISTORY where process_id in
(select process_id from epub_process where project = 'prj49001');

-- delete task information of process
delete from EPUB_PROC_TASKINFO where id in
(select process_id from epub_process where project = 'prj49001');

-- delete states of project (if any)
delete  from EPUB_IND_WORKFLOW where process_id in
(select process_id from epub_process where project = 'prj49001');

-- finally delete the process
delete from epub_process where where project = 'prj49001';

commit;
---- Extra Sqls that may give more info --



12). Identification of the project names and projectIds based on resource like categoryId and producId



Syntax script

select PROJECT_ID,DISPLAY_NAME from epub_project where WORKSPACE in (select name from avm_devline where id in (select WORKSPACE_ID from ${resource table name} where ${id name} =’id value’))

Eg.,
select PROJECT_ID,DISPLAY_NAME from epub_project where WORKSPACE in (select name from avm_devline where id in (select WORKSPACE_ID from dcs_category where CATEGORY_ID ='cat20102'))


13) SNAPSHOT EXCEPTION


Any Snapshot related exception during the partial deployment need to forcely insert the snapshot id into the /atg/epub/DeploymentServer component

Q) How to get the last successful snapshot?

Execute the below query in the pub schema.

 select epub_target.display_name as "Target",
epub_prj_tg_snsht.snapshot_id as "Snapshot",
epub_project.display_name as "Project" from
epub_target, epub_project, epub_prj_tg_snsht
where
epub_prj_tg_snsht.project_id in
(
select project_id from epub_project where
workspace is not null and
checked_in = '1'
) and
epub_target.target_id = epub_prj_tg_snsht.target_id and
epub_prj_tg_snsht.project_id = epub_project.project_id
order by epub_project.checkin_date desc;

  [OR]

Select * from epub_PRJ_TG_SNSHT ORDER BY to_number(SNAPSHOT_ID) DESC;

or
 we can the snap shot from completed projects for stage as well as production.




14) BCC WorkBench Configuration

 Issue:On clincking the workbench url not redirecting to expected XM Workbench URL 

Solution: We change the following component

Atg/endeca/ApplicationConfiguration.properties

workbenchPort=0 (it can be empty also)
workbenchHostName=need to give host name(like abc.xy.com)


And also extended the class ApplicationConfiguration.java to override the method getWorkBenchURL().

  

15)In which component Data directory information will be configured

 

16)BCC Queries

Identification of workspace from project
select id from avm_devline where name = (select workspace from epub_project where project_id = 'prj48069');


17) SQL DEPLOYMENT

 SQL deployment is available in the following link


/atg/epub/DeploymentServer.properties

useDirectSQLReplication=true

/atg/epub/version/VersionManagerService.properties

replicationTransactionBatchSize=1000
maxReplicationThreadCount=9

 

18) BCC custom workflow info 

The following components involves in implementing custom workflow

1)ActivityManager
2) PublishingActivitySource
3) autoworkflow.wdl file
4)CommerceActivitySource
  hiddenWorkflowDirectories=/Commerce/deployment/*

 

 

19) BCC Project is stucked in Last state(Not done last step)

Solution: In Dyn/admin, Go the the following component.

/atg/epub/messaging/PublishingMessageSource/
  
Need to select the project and send Deployment complete the project
More inforamtion added in ATG error section .



20)Roll back the project.

We can roll back to a particular project by selecting target project in projects tab then click on Rollback option.
2)System navigates to other page, then select now option(to do immediately) .
3)Rollback values will be reflected at CATA/CATB not at PUB schema.



21)Display of any property values in BCC UI while associating to any other property. Need to configure as follow.
<item-descriptor name="xxx"   display-property="xxxName">

If we can give this, defaul the repository name and id  will be displayed.

  21)Use full References

https://docs.oracle.com/cd/E13188_01/jrockit/docs81/tuning/config.html#1010119


22)Fetching the table records using the project id

Using the following query ,we can fetch the records from product table using the project name

select * from dcs_product where WORKSPACE_ID in ((select id from avm_devline where name in (select WORKSPACE from epub_project where DISPLAY_NAME ='projectName')));

1 comment:

  1. Tech Solutions: Atg Bcc Info >>>>> Download Now

    >>>>> Download Full

    Tech Solutions: Atg Bcc Info >>>>> Download LINK

    >>>>> Download Now

    Tech Solutions: Atg Bcc Info >>>>> Download Full

    >>>>> Download LINK cE

    ReplyDelete