Wednesday, October 7, 2015

Publishing (BCC) Error - Role '/EPublishing/EPub-Super-Admin'

Follow bellow steps to solve the issue.

1. Clean the source code and build the code using favorite IDE. 2. Set the source code publishing data source. 
     This data source should be the similar data source name given in your application server.
     /config/atg/dynamo/service/jdbc/DirectJTDataSource_publishing.properties

     DirectJTDataSource_publishing.properties
     JNDIName=publishingDS
     $class=atg.nucleus.JNDIReference


3.  Run the publishing run assembler for your project.
      Ex :  /ATG-HOME/home/bin/runAssembler -server   /location-of-your-ear-deployment-path/your-publishing-ear-name.ear -layer  preview  -m DCS-UI.Versioned PubPortlet DafEar.Admin  DCS-UI.SiteAdmin.Versioned 

4. Configure data source in fake server.
    Fake servers can be used to directly connect with data bases and  import data.
    My Fake server name is my-fakexa
    My Fake server located at /ATG-HOME/home/servers/my-fakexa
    Brows the location /ATG-HOME/home/servers/my-fakexa/localconfig/atg/dynamo/service/jdbc

   Create property files called JTDataSource.properties and FakeXADataSource.properties with bellow content


    JTDataSource.properties
    $class=atg.service.jdbc.MonitoredDataSource
    dataSource=/atg/dynamo/service/jdbc/FakeXADataSource


    Now create FakeXADataSource.properties file with bellow content


   FakeXADataSource.properties

    $class=atg.service.jdbc.FakeXADataSource
    driver=oracle.jdbc.xa.client.OracleXADataSource
    URL=jdbc:oracle:thin:@localhost:1521:XE
    user=publishing-db-schema-username
    password=
publishing-db-schema-password

4. Change Directory to /ATG-HOME/BIZUI/install/data and find bellow XML files.
     portal.xml
     profile.xml
     viewmapping.xml

5. Import content of above XML file to publishing schema by referring to fake server
   /ATG-HOME/home/bin/startSQLRepository  -m BIZUI -s my-fakexa -repository /atg/portal
   /framework/PortalRepository -import    /ATG-HOME/BIZUI/install 
   /data/portal.xml


   /ATG-HOME/home/bin/startSQLRepository  -m BIZUI -s my-fakexa -repository /atg/portal
   /framework/PortalRepository -import    /ATG-HOME/BIZUI/install 
   /data/profile.xml

      /ATG-HOME/home/bin/startSQLRepository  -m BIZUI -s my-fakexa -repository /atg/portal
   /framework/PortalRepository -import    /ATG-HOME/BIZUI/install 
   /data/viewmapping.xml

6. Restart publishing server and try to logging to your BCC


end