File APIs for Java Developers
Manipulate DOC, XLS, PPT, PDF and many others from your application.
The moose likes Groovy and the fly likes uploading files to FileNet with Groovy Big Moose Saloon
  Search | Java FAQ | Recent Topics | Flagged Topics | Hot Topics | Zero Replies
Register / Login
JavaRanch » Java Forums » Languages » Groovy
Bookmark "uploading files to FileNet with Groovy" Watch "uploading files to FileNet with Groovy" New topic

uploading files to FileNet with Groovy

Ajit Sethi

Joined: Sep 17, 2012
Posts: 5
i have to make a POC using Groovy to upload a pdf file to FileNet and then retrieving that document using the FileNetId generated by FileNet, any one having any experience in this? any ideas will be helpful
chris webster

Joined: Mar 01, 2009
Posts: 2293

Warning: I know nothing about FileNet, and not a lot about Groovy, but just until the Real Experts show up, here's a few thoughts!

You should probably approach the problem as if it were any other "upload a file to a server and read a file" requirement, model the individual processes/components appropriately and then refine the specific implementations you need here.

So you will need to break the task down into separate elements e.g. you need to have a process for selecting a file (a PDF in your case but it doesn't really matter), uploading that to some kind of server and holding onto the file ID when it's been saved. This is the stuff you presumably want to do with Groovy, so look around for examples of how to do this generally with Groovy i.e. without worrying too much about the FileNet side of things.

Assuming you're talking about IBM FileNet, a quick Google search suggests there are various APIs available, so you also need to look at how to talk to the FileNet server specifically. This will be via a Java API, but of course that's pretty transparent for Groovy anyway. And you presumably need to know something about how/where FileNet will store the file and how it will tell you the file ID.

Finally, you want to be able to retrieve the document using its ID via the API - this should be one of the standard use cases for the APIs, so have a look in the docs for that. Here's a link to IBM docs on FileNet APIs:

And this link is supposed to be for a FileNet Java API demo application:

Right, over to the Grownups now. Good luck!

No more Blub for me, thank you, Vicar.
Gregg Bolinger
GenRocket Founder
Ranch Hand

Joined: Jul 11, 2001
Posts: 15302

Yea, this is going to be a lot more about FileNet than Groovy. Looking at this generically, if someone asked me to be able to upload / download content via an API using Groovy, the first thing I would do is go here.

GenRocket - Experts at Building Test Data
I agree. Here's the link:
subject: uploading files to FileNet with Groovy
It's not a secret anymore!