Jump to content
Ugochukwu Mmaduekwe

what is the possibility of having a rest/soap webapi in Delphi 2007

Recommended Posts

Hi all, as the question stated, what is the possibility of having a rest/soap webapi written in Delphi 2007?

What challenges are we bound to face? what components do you think will be needed? what advice can you give?

 

lastly do you think it will be  a better option to write the rest/soap webapi in C# using VS 2017 instead?

Unfortunately the version of Delphi can't be upgraded.

 

thanks.

Share this post


Link to post

I'd go for the C# approach instead of fiddling with an ancient Delphi.

  • Thanks 1

Share this post


Link to post
2 minutes ago, Lars Fosdal said:

I'd go for the C# approach instead of fiddling with an ancient Delphi.

Thanks a lot, this has been what I have always wanted to do.
will wait for other responses though.

Share this post


Link to post
8 minutes ago, Mohammed Nasman said:

If you can use the community edition, you should give Delphi MVC a try.

 

Otherwise, I will go with @Lars Fosdal suggestion.

 

Would have loved to look into Delphi MVC but unfortunately they don't have plans to upgrade the Delphi version they currently use.
However I will look into Delphi MVC for my own personal projects.
Thanks a lot.

  • Like 1

Share this post


Link to post

It's unfair to compare the ancient Delphi 2007 with the relatively new VS 2017. It is not even Unicode compliant.

Share this post


Link to post
8 minutes ago, Kryvich said:

It's unfair to compare the ancient Delphi 2007 with the relatively new VS 2017. It is not even Unicode compliant.

@Kryvich, I am not really comparing. I am just evaluating my options.

Share this post


Link to post
Posted (edited)

If you have the option to choose REST only then you might really would like to consider MARS Curiosity.

 

Edit: Just checked GitHub and it seems no packages exists for Delphi 2007.

 

Edited by ertank
  • Like 2

Share this post


Link to post
23 minutes ago, ertank said:

If you have the option to choose REST only then you might really would like to consider MARS Curiosity.

 

Edit: Just checked GitHub and it seems no packages exists for Delphi 2007.

 

Thanks but it seems like it doesn't support Delphi 2007 like you correctly figured out.

Share this post


Link to post

The Internet Communications Suite (ICS) has a REST client component using Json and an application web server that sends whatever you give it.  There is an ICS topic here.  

 

But no SOAP protocol as such, Json seems to have overtaken SOAP as much easier to use.  ICS uses SuperObject for Json and reading XML, all Delphi 2007 compatible.  Adding a SOAP wrapper to your XML objects should not be too hard. 

 

Angus

 

  • Like 2

Share this post


Link to post

Even it is not just for REST, you can write your own interface based methods and use mORMot as a REST server.

Learning curve might be slower compared to some other options. However, it does run from Delphi 6 to Delphi 10.3.3 and has Linux support using Lazarus+FPC.

There is no SOAP support as to my knowledge.

  • Like 2

Share this post


Link to post

SOAP is for WebService,it is stable since Delphi 7. WebService framework is buit-in delphi since Delphi 7.

  • Like 2

Share this post


Link to post

I think the problem you're going to run into is in how the RTTI support changed massively in D2010. Legacy apps built before that aren't going to care. But most libraries since then have come to depend heavily on it for a variety of things, especially when it comes to offering services of many kinds. There's stuff that simply cannot be done in D7 or even D2007 that can be done with the new RTTI support in D2010 and fwd.

 

A lot of these have to do with design-time support as well. So you can sometimes find libs that have run-time support back that far, but not much design-time support.

 

A straightforward REST/JSON API shouldn't be terribly difficult to write, unless you want to be able to send objects over the wire and have them reconstituted at the other end. Short of that, you might find something that works for you. 

  • Like 1

Share this post


Link to post
Posted (edited)
12 hours ago, David Schwartz said:

I think the problem you're going to run into is in how the RTTI support changed massively in D2010. Legacy apps built before that aren't going to care. But most libraries since then have come to depend heavily on it for a variety of things, especially when it comes to offering services of many kinds. There's stuff that simply cannot be done in D7 or even D2007 that can be done with the new RTTI support in D2010 and fwd.

 

A lot of these have to do with design-time support as well. So you can sometimes find libs that have run-time support back that far, but not much design-time support.

 

A straightforward REST/JSON API shouldn't be terribly difficult to write, unless you want to be able to send objects over the wire and have them reconstituted at the other end. Short of that, you might find something that works for you. 

@David Schwartz Thanks for this answer. Also, this project will involves transmitting quite a number of binary data over the wire.
I am also considering the fact that I will be working with Unicode data so that will impose issues of it's own especially considering the fact that Delphi 2007 RTL is not Unicode aware.

Edited by Ugochukwu Mmaduekwe

Share this post


Link to post

Create an account or sign in to comment

You need to be a member in order to leave a comment

Create an account

Sign up for a new account in our community. It's easy!

Register a new account

Sign in

Already have an account? Sign in here.

Sign In Now

×