For testing RESTful services – Mozilla RESTClient add-on
If you are building RESTful services you may find RESTClient add-on helpful during your tests. You can install the Mozilla add-on from this url.
If you are building RESTful services you may find RESTClient add-on helpful during your tests. You can install the Mozilla add-on from this url.
Ruby on Rails has build in features for writing to you application log file. You can directly use the logger object for this purpose.
Following line when it is executed will print “Hello world” to you log file.
logger.info 'Hello world'
You can use different log levels fatal, error, warn, info, debug .
logger.error 'Hello world'
For more information please check the documentation of Logger class.
Today I defined a new site on my Nginx server. This new site I defined has a long domain name.
When I tried to restart the Nginx I got the following error message.
Restarting nginx: 2010/05/03 09:25:08 [emerg] 4452#0: could not build the server_names_hash, you should increase server_names_hash_bucket_size: 32 nginx.
When you write a custom pipeline component, loading entire message into memory should be avoided. If you use Memory Stream for large files, it loads entire message into memory and you may have OutOfMemory exceptions. On the other hand, VirtualStream uses Biztalk’s buffering directory after a threshold value which is specified in object initialization.
In addition to this, default message stream can be non-seekable and you may have exception when you try to change message data postion. The solution for this to use ReadOnlySeekableStream which wraps MemoryStream by default.
As a result of these, It is a good approach to use ReadOnlySeekableStream and VirtualStream classes exposed by Microsoft.Biztalk.Streaming.dll together in your custom pipeline components.
Please check below code snippet to see how to use ReadOnlySeekableStream vith VirtualStream.
int bufferSize = 0×280;
int thresholdSize = 0×100000;
if (!inmsg.BodyPart.GetOriginalDataStream().CanSeek)
{
Stream virtualStream = new VirtualStream(bufferSize, thresholdSize);
ReadOnlySeekableStream seekableStream =
new ReadOnlySeekableStream(inmsg.BodyPart.GetOriginalDataStream());
Stream seekStream =
new ReadOnlySeekableStream(inmsg.BodyPart.GetOriginalDataStream(),
virtualStream, bufferSize);
inmsg.BodyPart.Data = seekableStream;
}
inmsg.BodyPart.Data.Position = 0;
I have started to use .local dns extension for my local network. After changing my complete network configuration I realized that some of my Ubuntu machines can resolve the FQDNs ending with .local (Ex: testhost.digitalpains.local ) correctly.
ali@advance17:/home/ali$ ping testhost.digitalpains.local ping: unknown host testhost.digitalpains.local ali@advance17:/home/ali$ ping testhost PING testhost.feasiblesolutions.local (192.168.7.2) 56(84) bytes of data. 64 bytes from 192.168.7.2: icmp_seq=1 ttl=64 time=1.02 ms 64 bytes from 192.168.7.2: icmp_seq=2 ttl=64 time=1.12 ms
After some research it turned out that avahi-daemon was interfering the DNS resolve process and FQDNs ending with .local extension wasn’t being resolved.
After I stopped the avahi-daemon service I was able to resolve
ali@advance17:/home/ali$ sudo stop avahi-daemon avahi-daemon stop/waiting ali@advance17:/home/ali$ ping testhost.feasiblesolutions.local PING testhost.feasiblesolutions.local (192.168.7.2) 56(84) bytes of data. 64 bytes from 192.168.7.2: icmp_seq=1 ttl=64 time=2.05 ms 64 bytes from 192.168.7.2: icmp_seq=2 ttl=64 time=1.16 ms 64 bytes from 192.168.7.2: icmp_seq=3 ttl=64 time=4.25 ms
After reboot avahi-daemon service will start automatically. On Ubuntu Karmic edition adding the following line to you r /etc/avahi/avahi-daemon.conf file will solve the problem permanently.
AVAHI_DAEMON_DETECT_LOCAL=0
| Functoids | Inline script? |
|---|---|
| All String Functoids | Yes |
| All Mathematical Functoids | Yes |
| All Logical Functoids except IsNil | Yes |
| Logical IsNil Functoid | No |
| All Date/Time Functoids | Yes |
| All Conversion Functoids | Yes |
| All Scientific Functoids | Yes |
| All Cumulative Functoids | Yes |
| All Database Functoids | No |
| Advanced Functoids | Inline script? |
| Looping Functoid | No |
| Value Mapping Flattening Functoid | No |
| Assert Functoid | No |
| Table Extractor Functoid | No |
| Table Looping Functoid | No |
| Scripting Functoid with Inline C# | Yes |
| Scripting Functoid with Inline JScript.NET | Yes |
| Scripting Functoid with Inline Visual Basic .NET | Yes |
| Scripting Functoid with Inline XSLT | No |
| Scripting Functoid with Inline XSLT Call Template | No |
| Scripting Functoid calling External Assembly | No |
| Nil Value Functoid | No |
| Value Mapping Functoid | No |
| Mass Copy Functoid | No |
| Iteration Functoid | No |
| Index Functoid | No |
| Record Count Functoid | No |
As the mobile phones get smarter, they became an integral part of our life and very tempting attack vector. Today I red an article Voice Encryption: 9 out of 10 Products are Worthless (Technical Description) it is a nice example of with a little bit of creativity how easily you can bypass an expensive security measure.
Author is using a product called Flexispay you can see the flash movies explaining how does the product installed and works. With an investment of 100 Euros a year, you are able too wiretap a mobile telephone less than 5 minutes.
There are different options for automatically updating your server. At this article we will use the unattended-upgrades package.
We will start with installing the unattended-upgrades package.
kok@fhome:~$ sudo apt-get install unattended-upgrades
After installing the unattended-upgrades package we need to add the text below to the /etc/apt/apt.conf.d/10periodic file.
APT::Periodic::Update-Package-Lists “1″;
APT::Periodic::Download-Upgradeable-Packages “1″;
APT::Periodic::AutocleanInterval “5″;
APT::Periodic::Unattended-Upgrade “1″;
After this modification your system will install the security updates automatically. You can see the details of unattended-upgrades from the log files /var/log/unattended-upgrades/ folder.
For more information about this subject you can check the Ubuntu wiki page.
My problem is BizTalk Ftp Adapter’s inability to run in 64-bit mode… Actually, this is one of the problems of the ftp adapter but I won’t write about it in this entry, I can live with it….
Last but the not least, lack of extension point of adapter framework.
We have to use the adapter as it is or we must find another adapter. We have two options; We can develop our own custom adapter or we can find a third party adapter.
I think, it would be nice if we would not write a whole new adapter and if there were some extension points which we could alter the way of adapter’s processing, by writing something like interceptors. We can intercept the processing flow of the adapter, make some validations and decide whether to let adapter to continue processing or make it stop by throwing an exception or make it skip this time and try to retrieve file at next polling.