Powered By Blogger

Wednesday, August 31, 2011

Finding the port listening command

Finding the port listening command

From a Windows console, type:

netstat -an|find "61616" 

OR

From a Unix command shell, type:

netstat -an|grep 61616 

Monday, August 15, 2011

Comparison between WCM and DM nodeRepresentation

In the DM represenation noderef will be a numerical as below. I am trying to access
space_templates folder present in the DataDictionary
Node Identifier
Primary Path: /{http://www.alfresco.org/model/application/1.0}company_home/{http://www.alfresco.org/model/application/1.0}dictionary/{http://www.alfresco.org/model/application/1.0}space_templates
Reference: workspace://SpacesStore/08116618-8978-4917-88a1-9547e6128002
Type: {http://www.alfresco.org/model/content/1.0}folder
Parent: workspace://SpacesStore/460a0e42-dc18-4d7e-ad4a-2a8415a69846

In WCM noderef is comma seperated value with the complete store name

Primary Path: /{http://www.alfresco.org/model/content/1.0}www/{http://www.alfresco.org/model/content/1.0}avm_webapps/{http://www.alfresco.org/model/content/1.0}ROOT/{http://www.alfresco.org/model/content/1.0}statementinput.jsp.txt
Reference: avm://testdns--admin/-1;www;avm_webapps;ROOT;statementinput.jsp.txt
Type: {http://www.alfresco.org/model/wcmmodel/1.0}avmplaincontent
Parent: avm://testdns--admin/-1;www;avm_webapps;ROOT


Sample path will be as below
testdns--admin--preview:/www/avm_webapps/ROOT/statementinput.jsp.txt

If you replace ; with / of nodeReference we will get the path.

Alfresco WebContent Deployment

Alfresco WCM projects involves Authoring environment and Staging environment.
Authoring environment is the plcae where we create the content.
From the Staging environment we pull content to external site. In this blog I am discussing about how to deploy the content to staging environment.

The staging environment can be classified as below
1. WCM to DM deployment
2. WCM to another alfresco instance deployment(ASR)
3. WCM to deployment Engine
4. WCM to file system

Tested with Alfresco3.4.1
1. WCM to DM deployment
While configuring use the below entries
Transport Name: default
Host: 127.0.0.1
Port: 50500
URL: --
Type: Live Server
Username: admin

Source Path: --
Excludes: --
Target Name: alfresco
Include In Auto Deploy: Yes

If the target name is alfresco then the content will be deployed to WebDeployed folder of Alfresco.

2. WCM to another alfresco instance deployment(ASR)

Transport Name: default
Host: 127.0.0.1
Port: 50500
URL: --
Type: Live Server
Username: admin

Source Path: --
Excludes: --
Target Name: avm
Include In Auto Deploy: No

Here the target name is avm, hence it acts as ASR. For the staging sandbox-live will be appeneded.

3. WCM to deployment Engine
Before doing this install and start the deployment engine.
In this case configure the port to 44100
Target Name: default

We can change the target name to other than default by making changes in
alfresco-global.properties



Monday, August 8, 2011

Exposing the Java variables to Velocity Templates

We can make some java variables available in the velocity templates(used in theme)

In the
ServicePreAction we set the variables and these variables will
be accessed from the templates.

servlet.service.events.pre=com.liferay.portal.events.ServicePreAction,your.custom
.EXTServicePreAction

Thursday, August 4, 2011

Getting the Tasks from WorkflowInstance

WorkflowTaskQuery tasksQuery = new WorkflowTaskQuery();
tasksQuery.setTaskState(null);
tasksQuery.setActive(null);
tasksQuery.setProcessId(workflowInstance.id);
List tasks = workflowService.queryTasks(tasksQuery);


From the WorkflowTask get the id and make the query to get all the tasks.

Tuesday, August 2, 2011

JBPM api terminologies with Alfresco

TASK : From here we can get the complete info related to the workflow

For the each new workflow we start on any content we will have the WorkflowInstance.

Each task assigned is considered to be WorkflowTask.

Workflowdefinition has the details about the complete workflow version of it.

WorkflowTaskDefinition it will have the details about the paerticular task assigned to user
at this point of time


The task Id is::::jbpm$20
Workflow Instance id is:::jbpm$7
Task: WorkflowTask[id=jbpm$20,title=Review,state=IN_PROGRESS,props=18,def=WorkflowTaskDefinition[id=wf:reviewTask,metadata=ClassDef[name={http://www.alfresco.org/model/workflow/1.0}reviewTask]],path=WorkflowPath[id=jbpm$7-@review.0,instance=WorkflowInstance[id=jbpm$7,active=true,def=WorkflowDefinition[id=jbpm$4,name=jbpm$wf:parallelreview,version=1,title=Parallel Review & Approve,startTask=WorkflowTaskDefinition[id=wf:submitParallelReviewTask,metadata=ClassDef[name={http://www.alfresco.org/model/workflow/1.0}submitParallelReviewTask]]]],active=true,node=WorkflowNode[title=review,type=TaskNode,transitions={'WorkflowTransition[id=approve,title=Approve]','WorkflowTransition[id=reject,title=Reject]'}]]]