DFS Notes

Documentum Foundation Services

Blog registration is opened!

It was revealed that blog registration was closed, so blog readers could not register and post their comments. From now,  this bug is fixed. Please feel free to post any questions and propose what articles you’d like to see in the future.

It’s time to show you how to create .NET remote client for HelloWorldService.

In order to create .NET proxies for DFS service, developers should have:

  • Service’s WSDL URL.
  • DFS service-model.xml file which describes service artifacts to be generated by subsequent processes.

Read the rest of this entry »

Today we’ll talk about remote client creation which invokes our HelloWorldService from part 1.

Little more info about this sample:

Read the rest of this entry »

Hey everyone,

Some persons from EMC Documentum Forums stated that AcmeCustomService which comes with DFS SDK seems to be too complex for beginners, and “HelloWorld” service would be more understandable. I will try to show you how to create your first own simple HelloWorld like DFS service.

This tutorial will contain of 3 parts:

  • Service creation
  • Java client creation
  • .NET remote client

Before we’ll start, we should setup our build environment.

Note: You should have ant installed in order to run tutorial scripts.

1. Download attached helloworldservice.zip and extract it into emc-dfs-sdk-6.0\samples folder. It contains project template similar to AcmeCustomService. Lets assume “HelloWorldService” folder as root.

2. Open etc\dfc.properties and set host, repository name, username and password for your docbase.

3. Open build.properties and set preferred context root and module names, or leave them as they’re now.

Here is service code:

package com.service.example;

import com.emc.documentum.fs.rt.annotations.DfsPojoService;

@DfsPojoService(targetNamespace = “http://example.service.com”, requiresAuthentication = true)
public class HelloWorldService
{
public String sayHello(String name)
{
return “Hello ” + name;
}
}

@DfsPojoService annotation specifies service’s namespace, and states if service requires docbase authentication (true by default)

Place this source with appropriate package into src\service folder.

Go to root folder (HelloWorldService) and run from command line the following command:

ant artifacts package

This command converts annotated classes to DFS services and package them into ear file.

At this step, you should have example.ear deployment file in HelloWorldService\build folder. This ear file contains our service which can be deployed into Weblogic application server.

Copy this file into weblogic’s autodeploy directory. You can also set weblogic deployment dir at autodeploy.properties file and run “ant deploy” command.

With default values at build.properties, your service should be available by the path: http://host:port/services/example/HelloWorldService

That’s all for now. In the next part of tutorial I will explain how to create client and call this service remotely.

DFS 6.0 SP1 is coming

Documentum Foundation Services service pack is coming. It will contain many performance improvements, as well as .NET layer support which will allow DFS developers to create .NET proxies for their custom services and invoke services through similar to DFS Java API.

Here is rough example of .NET client written in C#:

……
ContextFactory contextFactory = ContextFactory.Instance;
IServiceContext serviceContext = contextFactory.NewContext();

ContentTransferProfile transferProfile = new ContentTransferProfile();
transferProfile.TransferMode = ContentTransferMode.MTOM;

RepositoryIdentity repoId = new RepositoryIdentity(repository, username, password, domain);

serviceContext.AddIdentity(repoId);
serviceContext.SetProfile(transferProfile);

// Registering context into Context Registry Service
IServiceContext registeredContext = contextFactory.Register(serviceContext);

// Now we create and call a service
ServiceFactory factory = ServiceFactory.Instance;
ICustomService service = factory.GetRemoteService<ICustomService>(registeredContext);

// Finally we invoke service’s method.
service.SomeMethod();
……

As you can see, working with DFS through .NET is much easier now, than working with bare WSDL. I will provide complete example soon.

Introduction

Hey everyone !

This blog is dedicated to EMC Documentum Foundation Services - the key component in the D6 Services Oriented Architecture. In this blog I will try to explain DFS API as well as some tips and tricks for services usage.

It is supposed that the basic audience of this blog will be documentum developers which wish to learn using DFS.

  

Calendar

September 2008
M T W T F S S
« Jan    
1234567
891011121314
15161718192021
22232425262728
2930